Commit 206a58d1 by Jamie Madill Committed by Commit Bot

Slight reformat to ANGLE format table.

Refactoring change only. BUG=angleproject:2207 Change-Id: Id05972d2084f3254745cbf55d1b7577306020466 Reviewed-on: https://chromium-review.googlesource.com/742373 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: 's avatarCorentin Wallez <cwallez@chromium.org>
parent e88ec8ee
...@@ -70,9 +70,7 @@ Format::ID Format::InternalFormatToID(GLenum internalFormat) ...@@ -70,9 +70,7 @@ Format::ID Format::InternalFormatToID(GLenum internalFormat)
{{ {{
switch (internalFormat) switch (internalFormat)
{{ {{
// clang-format off
{angle_format_switch} {angle_format_switch}
// clang-format on
}} }}
}} }}
...@@ -231,8 +229,9 @@ def gen_map_switch_string(gl_to_angle): ...@@ -231,8 +229,9 @@ def gen_map_switch_string(gl_to_angle):
switch_data = ''; switch_data = '';
for gl_format in gl_to_angle: for gl_format in gl_to_angle:
angle_format = gl_to_angle[gl_format] angle_format = gl_to_angle[gl_format]
switch_data += " case " + gl_format + ": return Format::ID::" + angle_format + ";\n" switch_data += " case " + gl_format + ":\nreturn Format::ID::" + angle_format + ";\n"
switch_data += " default: return Format::ID::NONE;" switch_data += " default:\n"
switch_data += " return Format::ID::NONE;"
return switch_data; return switch_data;
gl_to_angle = angle_format.load_forward_table('angle_format_map.json') gl_to_angle = angle_format.load_forward_table('angle_format_map.json')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment