Skip to content
This repository has been archived by the owner on Feb 25, 2025. It is now read-only.

Commit

Permalink
[impellerc] Generate GLSL output for the runtime-stage-gles target (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
jason-simmons authored Feb 14, 2023
1 parent 3141b11 commit bf66725
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions impeller/compiler/compiler.cc
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,8 @@ static CompilerBackend CreateGLSLCompiler(const spirv_cross::ParsedIR& ir,
spirv_cross::CompilerGLSL::Options sl_options;
sl_options.force_zero_initialized_variables = true;
sl_options.vertex.fixup_clipspace = true;
if (source_options.target_platform == TargetPlatform::kOpenGLES) {
if (source_options.target_platform == TargetPlatform::kOpenGLES ||
source_options.target_platform == TargetPlatform::kRuntimeStageGLES) {
sl_options.version = source_options.gles_language_version > 0
? source_options.gles_language_version
: 100;
Expand Down Expand Up @@ -137,13 +138,13 @@ static CompilerBackend CreateCompiler(const spirv_cross::ParsedIR& ir,
case TargetPlatform::kMetalDesktop:
case TargetPlatform::kMetalIOS:
case TargetPlatform::kRuntimeStageMetal:
case TargetPlatform::kRuntimeStageGLES:
case TargetPlatform::kVulkan:
compiler = CreateMSLCompiler(ir, source_options);
break;
case TargetPlatform::kUnknown:
case TargetPlatform::kOpenGLES:
case TargetPlatform::kOpenGLDesktop:
case TargetPlatform::kRuntimeStageGLES:
compiler = CreateGLSLCompiler(ir, source_options);
break;
case TargetPlatform::kSkSL:
Expand Down

0 comments on commit bf66725

Please sign in to comment.