Browse Source
Merge pull request #8314 from liamwhite/gl-flip-2
OpenGL: interpret face flips according to GL NDC
pull/15/merge
Morph
4 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
3 additions and
4 deletions
-
src/video_core/renderer_opengl/gl_rasterizer.cpp
|
|
@ -563,12 +563,11 @@ void RasterizerOpenGL::SyncViewport() { |
|
|
flags[Dirty::FrontFace] = false; |
|
|
flags[Dirty::FrontFace] = false; |
|
|
|
|
|
|
|
|
GLenum mode = MaxwellToGL::FrontFace(regs.front_face); |
|
|
GLenum mode = MaxwellToGL::FrontFace(regs.front_face); |
|
|
bool flip_faces = false; |
|
|
|
|
|
if (regs.screen_y_control.triangle_rast_flip != 0 && |
|
|
|
|
|
regs.viewport_transform[0].scale_y < 0.0f) { |
|
|
|
|
|
|
|
|
bool flip_faces = true; |
|
|
|
|
|
if (regs.screen_y_control.triangle_rast_flip != 0) { |
|
|
flip_faces = !flip_faces; |
|
|
flip_faces = !flip_faces; |
|
|
} |
|
|
} |
|
|
if (regs.viewport_transform[0].scale_z < 0.0f) { |
|
|
|
|
|
|
|
|
if (regs.viewport_transform[0].scale_y < 0.0f) { |
|
|
flip_faces = !flip_faces; |
|
|
flip_faces = !flip_faces; |
|
|
} |
|
|
} |
|
|
if (flip_faces) { |
|
|
if (flip_faces) { |
|
|
|