Skip to content

[Impeller] Don't use inverse in shaders targeting the OpenGLES backend. #141829

@bdero

Description

@bdero

Currently we're using inverse to invert matrices in the conical blend, but this isn't supported by GLSL ES 1 without an extension. So we need to provide a shim to properly support OpenGLES 2.

AAOS happened to catch this issue on a target Android device (FYI @johnoneil):

[ERROR:flutter/impeller/base/validation.cc(49)] Break on 'ImpellerValidationBreak' to inspect point of failure: Failed to compile fragment shader for 'ConicalGradientFill Pipeline' with error:
0(55) : error C7532: global function inverse requires "#version 140" or later
0(55) : error C0000: ... or #extension GL_ARB_gpu_shader5 : enable
0(95) : error C7532: global function inverse requires "#version 140" or later
0(95) : error C0000: ... or #extension GL_ARB_gpu_shader5 : enable

Shader source was: 
#version 100
precision mediump float;
precision highp int;

struct FragInfo
...

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work liste: impellerImpeller rendering backend issues and features requestsengineflutter/engine related. See also e: labels.team-engineOwned by Engine teamtriaged-engineTriaged by Engine team

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions