summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2012-12-19 17:16:47 -0600
committerDave Parks <davep@lindenlab.com>2012-12-19 17:16:47 -0600
commitd92414e944b6557b33cc47223e684433a8f5426f (patch)
treef4fd3065794836ca12c517ff5d4adad9f473718c /indra/newview
parent615af0c556d599b0804874efbde8eba05bef5172 (diff)
MAINT-2152 Fix for bad aspect ratio on custom resolution snapshots
Diffstat (limited to 'indra/newview')
-rwxr-xr-xindra/newview/llviewerwindow.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp
index 8bb13cad25..0d884a3345 100755
--- a/indra/newview/llviewerwindow.cpp
+++ b/indra/newview/llviewerwindow.cpp
@@ -4263,6 +4263,8 @@ BOOL LLViewerWindow::rawSnapshot(LLImageRaw *raw, S32 image_width, S32 image_hei
snapshot_height = image_height;
reset_deferred = true;
mWorldViewRectRaw.set(0, image_height, image_width, 0);
+ LLViewerCamera::getInstance()->setViewHeightInPixels( mWorldViewRectRaw.getHeight() );
+ LLViewerCamera::getInstance()->setAspect( getWorldViewAspectRatio() );
scratch_space.bindTarget();
}
else
@@ -4472,6 +4474,8 @@ BOOL LLViewerWindow::rawSnapshot(LLImageRaw *raw, S32 image_width, S32 image_hei
if (reset_deferred)
{
mWorldViewRectRaw = window_rect;
+ LLViewerCamera::getInstance()->setViewHeightInPixels( mWorldViewRectRaw.getHeight() );
+ LLViewerCamera::getInstance()->setAspect( getWorldViewAspectRatio() );
scratch_space.flush();
scratch_space.release();
gPipeline.allocateScreenBuffer(original_width, original_height);