mirror of
https://github.com/overte-org/overte.git
synced 2025-04-22 05:24:12 +02:00
Fix drawing of Cube3D on the ApplicationOverlay
This seems to break because the ApplicationOverlay is drawn to a texture buffer first, which is incompatible with the DeferredLightingEffect implementation.
This commit is contained in:
parent
a0623c930b
commit
27e13385ed
1 changed files with 10 additions and 2 deletions
|
@ -74,7 +74,11 @@ void Cube3DOverlay::render(RenderArgs* args) {
|
|||
glPushMatrix();
|
||||
glColor4f(1.0f, 1.0f, 1.0f, alpha);
|
||||
glScalef(dimensions.x * _borderSize, dimensions.y * _borderSize, dimensions.z * _borderSize);
|
||||
Application::getInstance()->getDeferredLightingEffect()->renderSolidCube(1.0f);
|
||||
if (_drawOnApplicationOverlay) {
|
||||
glutSolidCube(1.0f);
|
||||
} else {
|
||||
Application::getInstance()->getDeferredLightingEffect()->renderSolidCube(1.0f);
|
||||
}
|
||||
glPopMatrix();
|
||||
glDepthMask(GL_TRUE);
|
||||
}
|
||||
|
@ -82,7 +86,11 @@ void Cube3DOverlay::render(RenderArgs* args) {
|
|||
glPushMatrix();
|
||||
glColor4f(color.red / MAX_COLOR, color.green / MAX_COLOR, color.blue / MAX_COLOR, alpha);
|
||||
glScalef(dimensions.x, dimensions.y, dimensions.z);
|
||||
Application::getInstance()->getDeferredLightingEffect()->renderSolidCube(1.0f);
|
||||
if (_drawOnApplicationOverlay) {
|
||||
glutSolidCube(1.0f);
|
||||
} else {
|
||||
Application::getInstance()->getDeferredLightingEffect()->renderSolidCube(1.0f);
|
||||
}
|
||||
glPopMatrix();
|
||||
} else {
|
||||
glLineWidth(_lineWidth);
|
||||
|
|
Loading…
Reference in a new issue