Version: 2022.2
언어: 한국어

SystemInfo.hasDynamicUniformArrayIndexingInFragmentShaders

매뉴얼로 전환
public static bool hasDynamicUniformArrayIndexingInFragmentShaders ;

설명

Returns true when the GPU has native support for indexing uniform arrays in fragment shaders without restrictions.

Some OpenGL ES 2 GPUs do not support indexing uniform arrays in fragment shaders using arbitrary variables. The OpenGL ES 2 GLSL specification requires only indexing by constants, for-loop counters and combinations of those in fragment shaders. Support for indexing using other variables is not guaranteed. The generated shader code handles these differences by providing wrappers for each of the indexed arrays used in the shader. The wrappers provide two code paths, one indexing the array directly, and another emulating indexing using branching. When running on a device, the shader compiler selects the correct code path depending on the device capabilities. This flag provides a possibility to select a simpler shader when running on devices that lack native support for indexing uniform arrays in fragment shaders using arbitrary variables.