Graphics-TIFF

 view release on metacpan or  search on metacpan

lib/Graphics/TIFF.pm  view on Meta::CPAN


Returns the data for the tile containing the specified coordinates. The data is
returned decompressed and, typically, in the native byte- and bit-ordering, but
are otherwise packed (see further below). The buffer must be large enough to
hold an entire tile of data. Applications should call the routine TIFFTileSize
to find out the size (in bytes) of a tile buffer. The x and y parameters are
always used by ReadTile. The z parameter is used if the image is deeper than 1
slice (ImageDepth>1). The sample parameter is used only if data are organised in
separate planes (PlanarConfiguration=2).

The library attempts to hide bit- and byte-ordering differences between the
image and the native machine by converting data to the native machine order. Bit
reversal is done if the FillOrder tag is opposite to the native machine bit
order. 16- and 32-bit samples are automatically byte-swapped if the file was
written with a byte order opposite to the native machine byte order.

=head2 $tif->CurrentDirectory()

Return an index number of the current directory in the specified TIFF file.

=head2 $tif->PrintDirectory(file, flags)

Prints a description of the current directory in the specified TIFF file to the
standard I/O output stream fd. The flags parameter is used to control the level
of detail of the printed information, and is a bitwise or of the following
values:

TIFFPRINT_NONE
TIFFPRINT_STRIPS
TIFFPRINT_CURVES
TIFFPRINT_COLORMAP
TIFFPRINT_JPEGQTABLES
TIFFPRINT_JPEGACTABLES
TIFFPRINT_JPEGDCTABLES

=head2 Graphics::TIFF::ReverseBits(data, size)

Replaces each byte in data with the equivalent bit-reversed value. This
operation is done with a lookup table.

=for readme continue

=head1 DIAGNOSTICS

=head1 CONFIGURATION AND ENVIRONMENT

=head1 DEPENDENCIES

=head2 Runtime

The runtime dependencies are just libtiff itself. In Windows this is satisfied
by Alien::libtiff.

=head2 Build

The build dependencies are additionally the development headers for libtiff
and Perl.

=head2 Test

In addition to the above, the Perl module Image::Magick is required to run some
of the tests.

=head1 INCOMPATIBILITIES

=head1 BUGS AND LIMITATIONS

=head1 SEE ALSO

The LIBTIFF Standard Reference L<http://www.libtiff.org/libtiff.html> is a handy
companion. The Perl bindings follow the C API very closely, and the C reference
documentation should be considered the canonical source.

=head1 AUTHOR

Jeffrey Ratcliffe, E<lt>jffry@posteo.netE<gt>

=head1 LICENSE AND COPYRIGHT

Copyright (C) 2017--2024 by Jeffrey Ratcliffe

This library is free software; you can redistribute it and/or modify
it under the same terms as Perl itself, either Perl version 5.8.5 or,
at your option, any later version of Perl 5 you may have available.

=cut



( run in 1.060 second using v1.01-cache-2.11-cpan-39bf76dae61 )