- Unity 6000 以降では OpenGL ES2 のサポートが打ち切られている
- OpenGL ES3 は
SV_VertexID
を使用可能 - よって、Unity 6000 以降のモバイル、コンソール、PC 環境では常に
SV_VertexID
を使用可能
参照 : https://docs.unity.cn/6000.0/Documentation/Manual/android-requirements-and-compatibility.html
Graphics API support
Graphics API | Support |
---|---|
Vulkan | Yes |
OpenGL ES 1.0 | No |
OpenGL ES 1.1 | No |
OpenGL ES 2.0 | No |
OpenGL ES 3.0 | Yes |
OpenGL ES 3.1 | Yes |
OpenGL ES 3.2 | Yes |
参照 : https://docs.unity3d.com/2020.1/Documentation/Manual/SL-ShaderSemantics.html
Vertex ID: SV_VertexID This feature only exists from DX10 (shader model 4.0) and GLCore / OpenGL ES 3, so the shader needs to have the #pragma target 3.5 compilation directive.
#pragma target 3.5
以降= OpenGL ES 3.0 以降であれば、常に SV_VertexID
を使用可能