opengl:glsl_hlsl
差分
このページの2つのバージョン間の差分を表示します。
| 両方とも前のリビジョン前のリビジョン次のリビジョン | 前のリビジョン | ||
| opengl:glsl_hlsl [2014/07/02 19:07] – [GLSL/HLSL 命令対応表] oga | opengl:glsl_hlsl [2016/09/12 14:53] (現在) – [GLSL/HLSL/Metal 命令対応表] oga | ||
|---|---|---|---|
| 行 1: | 行 1: | ||
| - | ====== GLSL/HLSL 命令対応表 ====== | + | ====== GLSL/HLSL/ |
| + | * HLSL = DirectX (D3D8/ | ||
| + | * GLSL = OpenGL 2/3/4, OpenGL ES 2/3, Vulkan, SpliteKit (watchOS) | ||
| + | * Metal = Metal (iOS/ | ||
| - | ^ GLSL ^ HLSL | + | |
| + | |||
| + | ^ GLSL ^ HLSL | ||
| | float | float | float | | | | float | float | float | | | ||
| | -- | float1 | | -- | float1 | ||
| 行 42: | 行 47: | ||
| - | ^ GLSL ^ HLSL | + | ^ GLSL ^ HLSL |
| | inversesqrt( x ) | rsqrt( x ) | rsqrt( x ) | 1/sqrt( x ) | | | inversesqrt( x ) | rsqrt( x ) | rsqrt( x ) | 1/sqrt( x ) | | ||
| | mix( x, y, s ) | lerp( x, y, s ) | mix( x, y, s ) | | mix( x, y, s ) | lerp( x, y, s ) | mix( x, y, s ) | ||
| 行 52: | 行 57: | ||
| + | ^ GLSL ^ HLSL ^ Metal ^ ^ | ||
| + | | sampler2D samplerobj | ||
| + | | sampler2DShadow depthobj | ||
| + | | v= texture( samplerobj, texcoord.. ); | v= texobj.Sample( texcoord.. ); | v= texobj.sample( sampler, texcoord .. ) | sampling | ||
| + | | v= texture2D( sampleobj, texcoord.. ); | v= tex2D( sampler, texcoord.. ); | -- | legacy syntax | ||
| + | | v= textureGather( depthobj, texcoord.. ); | v= depthobj.SampleCmp( texcoord.. ); | v= depthobj.sample_compare( ... ) | pcf shadow map | | ||
| - | ^ GLSL ^ HLSL ^ ^ | ||
| - | | sampler2D samplerobj | ||
| - | | sampler2DShadow shadowobj | ||
| - | | v= texture( samplerobj, texcoord.. ); | v= textureobj.Sample( texcoord.. ); | sampling | ||
| - | | v= texture2D( sampleobj, texcoord.. ); | v= tex2D( sampler, texcoord.. ); | legacy syntax | ||
| - | | v= textureGather( sadowobj, texcoord.. ); | v= shadowobj.SampleCmp( texcoord.. ); | pcf shadow map | | ||
| - | ^ shader | ||
| - | | vsh | in int gl_VertexID; | ||
| - | | ::: | in int gl_InstanceID; | ||
| - | | fsh/psh | out vec4 color; (GL2: gl_FragColor) | ||
| - | | ::: | out float gl_FragDepth; | ||
| + | ^ shader | ||
| + | | vsh | in int gl_VertexID; | ||
| + | | ::: | in int gl_InstanceID; | ||
| + | | ::: | out vec4 gl_Position; | ||
| + | | fsh/psh | out vec4 color; (GL2: gl_FragColor) | ||
| + | | ::: | out float gl_FragDepth; | ||
opengl/glsl_hlsl.1404295628.txt.gz · 最終更新: by oga
