AWARE SYSTEMS
TIFF and LibTiff Mail List Archive

Thread

1994.08.11 08:41 "Help", by Eric Nelson
1994.08.12 19:06 "Re: Help", by Dan McCoy

1994.08.12 19:06 "Re: Help", by Dan McCoy

If I say

    TIFFSetField(tif, TIFFTAG_RESOLUTIONUNIT, RESUNIT_INCH);
    TIFFSetField(tif, TIFFTAG_XRESOLUTION, 100);
    TIFFSetField(tif, TIFFTAG_YRESOLUTION, 100);

What's wrong?

Try saying:

    TIFFSetField(tif, TIFFTAG_RESOLUTIONUNIT, RESUNIT_INCH);
    TIFFSetField(tif, TIFFTAG_XRESOLUTION, 100.0);
    TIFFSetField(tif, TIFFTAG_YRESOLUTION, 100.0);

Since TIFFTAG_XRESOLUTION and TIFFTAG_YRESOLUTION are rational tags, they both take float arguments in TIFFSetField.

Dan McCoy        Pixar      mccoy@pixar.com