aboutsummaryrefslogtreecommitdiff
path: root/src/GPU3D_OpenGL.cpp
diff options
context:
space:
mode:
authorRSDuck <RSDuck@users.noreply.github.com>2021-01-22 12:19:46 +0100
committerRSDuck <RSDuck@users.noreply.github.com>2021-01-22 12:19:51 +0100
commit8a3a8b7c684996d2ea72a95e5abd62b1e763f344 (patch)
tree8bfc737ad248302a87d6a9b48d082903d822d7ed /src/GPU3D_OpenGL.cpp
parent7e3d1058a68506f2951d9f5343e1c9e938f5e035 (diff)
include polygon attr opaqueness for translucent polygons in render key
Diffstat (limited to 'src/GPU3D_OpenGL.cpp')
-rw-r--r--src/GPU3D_OpenGL.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/GPU3D_OpenGL.cpp b/src/GPU3D_OpenGL.cpp
index f24567c..381af9d 100644
--- a/src/GPU3D_OpenGL.cpp
+++ b/src/GPU3D_OpenGL.cpp
@@ -474,6 +474,7 @@ void SetupPolygon(RendererPolygon* rp, Polygon* polygon)
// - depthfunc
// -- depthwrite
// --- polyID
+ // ---- need opaque
// shadow mask polygons:
// - depthfunc?????
// shadow polygons:
@@ -491,6 +492,8 @@ void SetupPolygon(RendererPolygon* rp, Polygon* polygon)
rp->RenderKey |= (polygon->Attr >> 10) & 0x2; // bit11 - depth write
rp->RenderKey |= (polygon->Attr >> 13) & 0x4; // bit15 - fog
rp->RenderKey |= (polygon->Attr & 0x3F000000) >> 16; // polygon ID
+ if ((polygon->Attr & 0x001F0000) == 0x001F0000) // need opaque
+ rp->RenderKey |= 0x4000;
}
else
{