Fixed the semantic for SM4+ vertex output position.

TRAC #22153 Signed-off-by: Daniel Koch Signed-off-by: Geoff Lang Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/branches/dx11proto@1542 736b8ea6-26fd-11df-bfd4-992fa37f6226
parent d4b2db25
......@@ -1250,6 +1250,7 @@ bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::
mUsesPointSize = vertexShader->mUsesPointSize;
std::string varyingSemantic = (mUsesPointSize && sm3) ? "COLOR" : "TEXCOORD";
std::string targetSemantic = sm4 ? "SV_Target" : "COLOR";
std::string positionSemantic = sm4 ? "SV_POSITION" : "POSITION";
vertexHLSL += "struct VS_INPUT\n"
"{\n";
......@@ -1278,7 +1279,7 @@ bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::
"\n"
"struct VS_OUTPUT\n"
"{\n"
" float4 gl_Position : POSITION;\n";
" float4 gl_Position : " + positionSemantic + ";\n";
for (int r = 0; r < registers; r++)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment