diff options
author | Piotr Dziwinski <piotrdz@gmail.com> | 2012-07-25 20:27:13 +0200 |
---|---|---|
committer | Piotr Dziwinski <piotrdz@gmail.com> | 2012-07-25 20:27:13 +0200 |
commit | bc1c9b5284c10d8aafc04bcd6c3597b3626a782f (patch) | |
tree | 88f432699953fba513dc78155252ce20f83d5b05 /src/graphics/opengl/test/texture_test.cpp | |
parent | 9cd28e26e90ecbce239991e054293f748895fb98 (diff) | |
download | colobot-bc1c9b5284c10d8aafc04bcd6c3597b3626a782f.tar.gz colobot-bc1c9b5284c10d8aafc04bcd6c3597b3626a782f.tar.bz2 colobot-bc1c9b5284c10d8aafc04bcd6c3597b3626a782f.zip |
Fixed bug in texturing
Diffstat (limited to 'src/graphics/opengl/test/texture_test.cpp')
-rw-r--r-- | src/graphics/opengl/test/texture_test.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/graphics/opengl/test/texture_test.cpp b/src/graphics/opengl/test/texture_test.cpp index aa9817e..c3c568b 100644 --- a/src/graphics/opengl/test/texture_test.cpp +++ b/src/graphics/opengl/test/texture_test.cpp @@ -108,6 +108,16 @@ void Render(Gfx::CGLDevice *device) device->SetTextureEnabled(0, true); device->SetTextureEnabled(1, true); + tex1StageParams.colorOperation = Gfx::TEX_MIX_OPER_DEFAULT; + tex1StageParams.alphaOperation = Gfx::TEX_MIX_OPER_DEFAULT; + device->SetTextureStageParams(0, tex1StageParams); + + tex2StageParams.colorOperation = Gfx::TEX_MIX_OPER_ADD; + tex2StageParams.colorArg1 = Gfx::TEX_MIX_ARG_COMPUTED_COLOR; + tex2StageParams.colorArg2 = Gfx::TEX_MIX_ARG_TEXTURE; + tex2StageParams.alphaOperation = Gfx::TEX_MIX_OPER_DEFAULT; + device->SetTextureStageParams(1, tex2StageParams); + device->DrawPrimitive(Gfx::PRIMITIVE_TRIANGLES, quad, 6); device->EndScene(); |