|
|
|
@ -74,9 +74,8 @@ VkViewport GetViewportState(const Device& device, const Maxwell& regs, size_t in |
|
|
|
float width = conv(src.scale_x * 2.0f); |
|
|
|
float y = conv(src.translate_y - src.scale_y); |
|
|
|
float height = conv(src.scale_y * 2.0f); |
|
|
|
if (regs.window_origin.mode != Maxwell::WindowOrigin::Mode::UpperLeft) { |
|
|
|
y += conv(static_cast<float>(regs.surface_clip.height)); |
|
|
|
height = -height; |
|
|
|
if (regs.window_origin.mode == Maxwell::WindowOrigin::Mode::UpperLeft) { |
|
|
|
y = conv(static_cast<float>(regs.surface_clip.height)) - y - height; |
|
|
|
} else if (!device.IsNvViewportSwizzleSupported() && src.swizzle.y == Maxwell::ViewportSwizzle::NegativeY) { |
|
|
|
y += height; |
|
|
|
height = -height; |
|
|
|
|