Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Add check for 16-bit highp value #8533

Closed
anandthakker opened this issue Mar 27, 2017 · 2 comments
Closed

Add check for 16-bit highp value #8533

anandthakker opened this issue Mar 27, 2017 · 2 comments
Assignees
Labels
Core The cross-platform C++ core, aka mbgl

Comments

@anandthakker
Copy link
Contributor

Since #8183 (and the followup in #8496), we are packing pairs of colors into a single highp vec4. This strategy means that we have a hard requirement for highp providing at least 16 bits of precision.

It's possible that this color bug could be caused by a device that doesn't provide 16-bit highps.

We can add a check at startup, using glGetShaderPrecisionFormat, so that if a device doesn't have enough precision, we fail with an error message instead of trying to proceed.

@anandthakker anandthakker added the Core The cross-platform C++ core, aka mbgl label Mar 27, 2017
@tobrun
Copy link
Member

tobrun commented Apr 4, 2017

LMK if you want to do some CI testing on this, very interested in running this against +220 devices.

@anandthakker
Copy link
Contributor Author

Do we have any good way to expose a flag controlling whether or not this information gets logged?

Relatedly: there are a couple of unit tests that make assertions based on logging output, and adding this diagnostic logging will mess them up, e.g. here.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Core The cross-platform C++ core, aka mbgl
Projects
None yet
Development

No branches or pull requests

3 participants