Fix recreation of DefaultShaderProgram in FinalWrapper
`outputSurfaceInfoChanged` is not reset when `defaultShaderProgram` is null. That is, on the first time `ensureConfigured()` is called with output size changed, `outputSurfaceInfoChanged` is not set to false after creating the `defaultShaderProgram`, and `defaultShaderProgram` will be created again on the second time `ensureConfigured()` is called. PiperOrigin-RevId: 537870404
This commit is contained in:
parent
4306e0bb82
commit
133943a635
@ -461,14 +461,15 @@ import org.checkerframework.checker.nullness.qual.MonotonicNonNull;
|
||||
defaultShaderProgram = null;
|
||||
outputSurfaceInfoChanged = false;
|
||||
}
|
||||
|
||||
if (defaultShaderProgram == null) {
|
||||
defaultShaderProgram =
|
||||
createDefaultShaderProgram(
|
||||
outputSurfaceInfo == null ? 0 : outputSurfaceInfo.orientationDegrees,
|
||||
outputWidth,
|
||||
outputHeight);
|
||||
outputSurfaceInfoChanged = false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user