Commit 03703439 authored by Tobias Koenig's avatar Tobias Koenig

Scale TIFF without RESUNIT entry correctly by using default values

svn path=/trunk/KDE/kdegraphics/okular/; revision=982340
parent 14ed111d
......@@ -110,7 +110,7 @@ static void adaptSizeToResolution( TIFF *tiff, ttag_t whichres, double dpi, uint
float resvalue = 1.0;
uint16 resunit = 0;
if ( !TIFFGetField( tiff, whichres, &resvalue )
|| !TIFFGetField( tiff, TIFFTAG_RESOLUTIONUNIT, &resunit ) )
|| !TIFFGetFieldDefaulted( tiff, TIFFTAG_RESOLUTIONUNIT, &resunit ) )
return;
float newsize = *size / resvalue;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment