Workaround for drivers that apparently don't disable instancing when we ask.

TRAC #12479 This affects text rendering in Nexuiz. The text will be drawn as if the colour attribute is static rather than array, and all text will be drawn using the shadow colour. Signed-off-by: Shannon Woods Signed-off-by: Daniel Koch Author: Andrew Lewycky git-svn-id: https://angleproject.googlecode.com/svn/trunk@333 736b8ea6-26fd-11df-bfd4-992fa37f6226
parent 1c233ff4
...@@ -459,6 +459,11 @@ GLenum Dx9BackEnd::setupAttributesPreDraw(const TranslatedAttribute *attributes) ...@@ -459,6 +459,11 @@ GLenum Dx9BackEnd::setupAttributesPreDraw(const TranslatedAttribute *attributes)
if (mStreamFrequency[i] != STREAM_FREQUENCY_UNINSTANCED) if (mStreamFrequency[i] != STREAM_FREQUENCY_UNINSTANCED)
{ {
mStreamFrequency[i] = STREAM_FREQUENCY_UNINSTANCED; mStreamFrequency[i] = STREAM_FREQUENCY_UNINSTANCED;
// This should not be needed, but otherwise there is a buggy driver that will leave instancing
// enabled for the first draw after it has been turned off.
mDevice->SetStreamSourceFreq(i, D3DSTREAMSOURCE_INDEXEDDATA | 1);
mDevice->SetStreamSourceFreq(i, 1); mDevice->SetStreamSourceFreq(i, 1);
} }
} }
......
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