summaryrefslogtreecommitdiff
path: root/vcl/source/filter/jpeg/jpegc.cxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-02-06 17:40:21 +0100
committerStephan Bergmann <sbergman@redhat.com>2014-02-06 17:40:21 +0100
commit2afb6528c1bc70231b00555cdaa4dd3d25faed11 (patch)
tree3162922af0442cec7926588f7afa67495cf716e3 /vcl/source/filter/jpeg/jpegc.cxx
parentf5316a3d8cc2f94838fb5019cc4b8d093fe2fb3f (diff)
Blind fix^3
Change-Id: I4124084a6ce47e96936b5cc8695af1981f9f33d4
Diffstat (limited to 'vcl/source/filter/jpeg/jpegc.cxx')
-rw-r--r--vcl/source/filter/jpeg/jpegc.cxx7
1 files changed, 3 insertions, 4 deletions
diff --git a/vcl/source/filter/jpeg/jpegc.cxx b/vcl/source/filter/jpeg/jpegc.cxx
index 23fa73f676f5..3f52a2f024b9 100644
--- a/vcl/source/filter/jpeg/jpegc.cxx
+++ b/vcl/source/filter/jpeg/jpegc.cxx
@@ -56,7 +56,7 @@ extern "C" void outputMessage (j_common_ptr cinfo)
}
void ReadJPEG( JPEGReader* pJPEGReader, void* pInputStream, long* pLines,
- int thePreviewWidth, int thePreviewHeight )
+ Size const & previewSize )
{
jpeg_decompress_struct cinfo;
ErrorManagerStruct jerr;
@@ -70,9 +70,6 @@ void ReadJPEG( JPEGReader* pJPEGReader, void* pInputStream, long* pLines,
unsigned char * pScanLineBuffer = NULL;
long nScanLineBufferComponents = 0;
- int nPreviewWidth = thePreviewWidth;
- int nPreviewHeight = thePreviewHeight;
-
if ( setjmp( jerr.setjmp_buffer ) )
{
jpeg_destroy_decompress( &cinfo );
@@ -100,6 +97,8 @@ void ReadJPEG( JPEGReader* pJPEGReader, void* pInputStream, long* pLines,
OSL_ASSERT(cinfo.out_color_space == JCS_CMYK || cinfo.out_color_space == JCS_GRAYSCALE || cinfo.out_color_space == JCS_RGB);
/* change scale for preview import */
+ long nPreviewWidth = previewSize.Width();
+ long nPreviewHeight = previewSize.Height();
if( nPreviewWidth || nPreviewHeight )
{
if( nPreviewWidth == 0 )