├── .gitignore ├── CHANGELOG.txt ├── README.md ├── build.gradle ├── license.txt ├── proguard-rules.pro ├── src ├── androidTest │ └── java │ │ └── org │ │ └── beyka │ │ └── tiffbitmapfactory │ │ └── ApplicationTest.java └── main │ ├── .gitignore │ ├── AndroidManifest.xml │ ├── java │ └── org │ │ └── beyka │ │ └── tiffbitmapfactory │ │ ├── CompressionScheme.java │ │ ├── DecodeArea.java │ │ ├── FillOrder.java │ │ ├── IProgressListener.java │ │ ├── ImageFormat.java │ │ ├── Orientation.java │ │ ├── Photometric.java │ │ ├── PlanarConfig.java │ │ ├── ResolutionUnit.java │ │ ├── TiffBitmapFactory.java │ │ ├── TiffConverter.java │ │ ├── TiffSaver.java │ │ └── exceptions │ │ ├── CantOpenFileException.java │ │ ├── DecodeTiffException.java │ │ └── NotEnoughtMemoryException.java │ ├── jni │ ├── Android.mk │ ├── Application.mk │ ├── BMP.h │ ├── BaseTiffConverter.cpp │ ├── BaseTiffConverter.h │ ├── BitmapReader.cpp │ ├── BitmapReader.h │ ├── BmpToTiffConverter.cpp │ ├── BmpToTiffConverter.h │ ├── JpgToTiffConverter.cpp │ ├── JpgToTiffConverter.h │ ├── NativeDecoder.cpp │ ├── NativeDecoder.h │ ├── NativeExceptions.cpp │ ├── NativeExceptions.h │ ├── NativeTiffBitmapFactory.cpp │ ├── NativeTiffBitmapFactory.h │ ├── NativeTiffConverter.cpp │ ├── NativeTiffConverter.h │ ├── NativeTiffSaver.cpp │ ├── NativeTiffSaver.h │ ├── PngToTiffConverter.cpp │ ├── PngToTiffConverter.h │ ├── TiffToBmpConverter.cpp │ ├── TiffToBmpConverter.h │ ├── TiffToJpgConverter.cpp │ ├── TiffToJpgConverter.h │ ├── TiffToPngConverter.cpp │ ├── TiffToPngConverter.h │ ├── jpeg │ │ ├── jconfig.h │ │ ├── jerror.h │ │ ├── jmorecfg.h │ │ └── jpeglib.h │ ├── libs │ │ ├── arm64-v8a │ │ │ ├── libjpeg.a │ │ │ └── libpng.a │ │ ├── armeabi-v7a │ │ │ ├── libjpeg.a │ │ │ └── libpng.a │ │ ├── armeabi │ │ │ ├── libjpeg.a │ │ │ └── libpng.a │ │ ├── mips │ │ │ ├── libjpeg.a │ │ │ └── libpng.a │ │ ├── mips64 │ │ │ ├── libjpeg.a │ │ │ └── libpng.a │ │ ├── x86 │ │ │ ├── libjpeg.a │ │ │ └── libpng.a │ │ └── x86_64 │ │ │ ├── libjpeg.a │ │ │ └── libpng.a │ ├── png │ │ ├── config.h │ │ ├── png.h │ │ ├── pngconf.h │ │ └── pngpriv.h │ ├── tiff.h │ ├── tiff │ │ ├── Android.mk │ │ ├── COPYRIGHT │ │ ├── ChangeLog │ │ ├── HOWTO-RELEASE │ │ ├── Makefile.am │ │ ├── Makefile.in │ │ ├── Makefile.vc │ │ ├── README │ │ ├── README.android │ │ ├── README.vms │ │ ├── RELEASE-DATE │ │ ├── SConstruct │ │ ├── TODO │ │ ├── VERSION │ │ ├── aclocal.m4 │ │ ├── autogen.sh │ │ ├── build │ │ │ ├── Makefile.am │ │ │ ├── Makefile.in │ │ │ └── README │ │ ├── config │ │ │ ├── compile │ │ │ ├── config.guess │ │ │ ├── config.sub │ │ │ ├── depcomp │ │ │ ├── install-sh │ │ │ ├── ltmain.sh │ │ │ ├── missing │ │ │ └── mkinstalldirs │ │ ├── configure │ │ ├── configure.ac │ │ ├── configure.com │ │ ├── contrib │ │ │ ├── Makefile.am │ │ │ ├── Makefile.in │ │ │ ├── README │ │ │ ├── acorn │ │ │ │ ├── Makefile.acorn │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── ReadMe │ │ │ │ ├── SetVars │ │ │ │ ├── cleanlib │ │ │ │ ├── convert │ │ │ │ └── install │ │ │ ├── addtiffo │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── Makefile.vc │ │ │ │ ├── README │ │ │ │ ├── addtiffo.c │ │ │ │ ├── tif_overview.c │ │ │ │ ├── tif_ovrcache.c │ │ │ │ └── tif_ovrcache.h │ │ │ ├── dbs │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── README │ │ │ │ ├── tiff-bi.c │ │ │ │ ├── tiff-grayscale.c │ │ │ │ ├── tiff-palette.c │ │ │ │ ├── tiff-rgb.c │ │ │ │ └── xtiff │ │ │ │ │ ├── Makefile.am │ │ │ │ │ ├── Makefile.in │ │ │ │ │ ├── README │ │ │ │ │ ├── patchlevel.h │ │ │ │ │ ├── xtiff.c │ │ │ │ │ └── xtifficon.h │ │ │ ├── iptcutil │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── README │ │ │ │ ├── iptcutil.c │ │ │ │ ├── test.iptc │ │ │ │ └── test.txt │ │ │ ├── mac-cw │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── Makefile.script │ │ │ │ ├── README │ │ │ │ ├── mac_main.c │ │ │ │ ├── mac_main.h │ │ │ │ ├── metrowerks.note │ │ │ │ ├── mkg3_main.c │ │ │ │ └── version.h │ │ │ ├── mac-mpw │ │ │ │ ├── BUILD.mpw │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── README │ │ │ │ ├── libtiff.make │ │ │ │ ├── mactrans.c │ │ │ │ ├── port.make │ │ │ │ ├── tools.make │ │ │ │ └── top.make │ │ │ ├── mfs │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── README │ │ │ │ └── mfs_file.c │ │ │ ├── pds │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── README │ │ │ │ ├── tif_imageiter.c │ │ │ │ ├── tif_imageiter.h │ │ │ │ ├── tif_pdsdirread.c │ │ │ │ └── tif_pdsdirwrite.c │ │ │ ├── ras │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── README │ │ │ │ ├── ras2tif.c │ │ │ │ └── tif2ras.c │ │ │ ├── stream │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── README │ │ │ │ ├── tiffstream.cpp │ │ │ │ └── tiffstream.h │ │ │ ├── tags │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── README │ │ │ │ ├── listtif.c │ │ │ │ ├── maketif.c │ │ │ │ ├── xtif_dir.c │ │ │ │ ├── xtiffio.h │ │ │ │ └── xtiffiop.h │ │ │ └── win_dib │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── Makefile.w95 │ │ │ │ ├── README.Tiffile │ │ │ │ ├── README.tiff2dib │ │ │ │ ├── Tiffile.cpp │ │ │ │ └── tiff2dib.c │ │ ├── html │ │ │ ├── Makefile.am │ │ │ ├── Makefile.in │ │ │ ├── TIFFTechNote2.html │ │ │ ├── addingtags.html │ │ │ ├── bugs.html │ │ │ ├── build.html │ │ │ ├── contrib.html │ │ │ ├── document.html │ │ │ ├── images.html │ │ │ ├── images │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── back.gif │ │ │ │ ├── bali.jpg │ │ │ │ ├── cat.gif │ │ │ │ ├── cover.jpg │ │ │ │ ├── cramps.gif │ │ │ │ ├── dave.gif │ │ │ │ ├── info.gif │ │ │ │ ├── jello.jpg │ │ │ │ ├── jim.gif │ │ │ │ ├── note.gif │ │ │ │ ├── oxford.gif │ │ │ │ ├── quad.jpg │ │ │ │ ├── ring.gif │ │ │ │ ├── smallliz.jpg │ │ │ │ ├── strike.gif │ │ │ │ └── warning.gif │ │ │ ├── index.html │ │ │ ├── internals.html │ │ │ ├── intro.html │ │ │ ├── libtiff.html │ │ │ ├── man │ │ │ │ ├── Makefile.am │ │ │ │ ├── Makefile.in │ │ │ │ ├── TIFFClose.3tiff.html │ │ │ │ ├── TIFFDataWidth.3tiff.html │ │ │ │ ├── TIFFError.3tiff.html │ │ │ │ ├── TIFFFlush.3tiff.html │ │ │ │ ├── TIFFGetField.3tiff.html │ │ │ │ ├── TIFFOpen.3tiff.html │ │ │ │ ├── TIFFPrintDirectory.3tiff.html │ │ │ │ ├── TIFFRGBAImage.3tiff.html │ │ │ │ ├── TIFFReadDirectory.3tiff.html │ │ │ │ ├── TIFFReadEncodedStrip.3tiff.html │ │ │ │ ├── TIFFReadEncodedTile.3tiff.html │ │ │ │ ├── TIFFReadRGBAImage.3tiff.html │ │ │ │ ├── TIFFReadRGBAStrip.3tiff.html │ │ │ │ ├── TIFFReadRGBATile.3tiff.html │ │ │ │ ├── TIFFReadRawStrip.3tiff.html │ │ │ │ ├── TIFFReadRawTile.3tiff.html │ │ │ │ ├── TIFFReadScanline.3tiff.html │ │ │ │ ├── TIFFReadTile.3tiff.html │ │ │ │ ├── TIFFSetDirectory.3tiff.html │ │ │ │ ├── TIFFSetField.3tiff.html │ │ │ │ ├── TIFFWarning.3tiff.html │ │ │ │ ├── TIFFWriteDirectory.3tiff.html │ │ │ │ ├── TIFFWriteEncodedStrip.3tiff.html │ │ │ │ ├── TIFFWriteEncodedTile.3tiff.html │ │ │ │ ├── TIFFWriteRawStrip.3tiff.html │ │ │ │ ├── TIFFWriteRawTile.3tiff.html │ │ │ │ ├── TIFFWriteScanline.3tiff.html │ │ │ │ ├── TIFFWriteTile.3tiff.html │ │ │ │ ├── TIFFbuffer.3tiff.html │ │ │ │ ├── TIFFcodec.3tiff.html │ │ │ │ ├── TIFFcolor.3tiff.html │ │ │ │ ├── TIFFmemory.3tiff.html │ │ │ │ ├── TIFFquery.3tiff.html │ │ │ │ ├── TIFFsize.3tiff.html │ │ │ │ ├── TIFFstrip.3tiff.html │ │ │ │ ├── TIFFswab.3tiff.html │ │ │ │ ├── TIFFtile.3tiff.html │ │ │ │ ├── fax2ps.1.html │ │ │ │ ├── fax2tiff.1.html │ │ │ │ ├── gif2tiff.1.html │ │ │ │ ├── index.html │ │ │ │ ├── libtiff.3tiff.html │ │ │ │ ├── pal2rgb.1.html │ │ │ │ ├── ppm2tiff.1.html │ │ │ │ ├── ras2tiff.1.html │ │ │ │ ├── raw2tiff.1.html │ │ │ │ ├── rgb2ycbcr.1.html │ │ │ │ ├── sgi2tiff.1.html │ │ │ │ ├── thumbnail.1.html │ │ │ │ ├── tiff2bw.1.html │ │ │ │ ├── tiff2pdf.1.html │ │ │ │ ├── tiff2ps.1.html │ │ │ │ ├── tiff2rgba.1.html │ │ │ │ ├── tiffcmp.1.html │ │ │ │ ├── tiffcp.1.html │ │ │ │ ├── tiffcrop.1.html │ │ │ │ ├── tiffdither.1.html │ │ │ │ ├── tiffdump.1.html │ │ │ │ ├── tiffgt.1.html │ │ │ │ ├── tiffinfo.1.html │ │ │ │ ├── tiffmedian.1.html │ │ │ │ ├── tiffset.1.html │ │ │ │ ├── tiffsplit.1.html │ │ │ │ └── tiffsv.1.html │ │ │ ├── misc.html │ │ │ ├── support.html │ │ │ ├── tools.html │ │ │ ├── v3.4beta007.html │ │ │ ├── v3.4beta016.html │ │ │ ├── v3.4beta018.html │ │ │ ├── v3.4beta024.html │ │ │ ├── v3.4beta028.html │ │ │ ├── v3.4beta029.html │ │ │ ├── v3.4beta031.html │ │ │ ├── v3.4beta032.html │ │ │ ├── v3.4beta033.html │ │ │ ├── v3.4beta034.html │ │ │ ├── v3.4beta035.html │ │ │ ├── v3.4beta036.html │ │ │ ├── v3.5.1.html │ │ │ ├── v3.5.2.html │ │ │ ├── v3.5.3.html │ │ │ ├── v3.5.4.html │ │ │ ├── v3.5.5.html │ │ │ ├── v3.5.6-beta.html │ │ │ ├── v3.5.7.html │ │ │ ├── v3.6.0.html │ │ │ ├── v3.6.1.html │ │ │ ├── v3.7.0.html │ │ │ ├── v3.7.0alpha.html │ │ │ ├── v3.7.0beta.html │ │ │ ├── v3.7.0beta2.html │ │ │ ├── v3.7.1.html │ │ │ ├── v3.7.2.html │ │ │ ├── v3.7.3.html │ │ │ ├── v3.7.4.html │ │ │ ├── v3.8.0.html │ │ │ ├── v3.8.1.html │ │ │ ├── v3.8.2.html │ │ │ ├── v3.9.0beta.html │ │ │ ├── v3.9.1.html │ │ │ └── v3.9.2.html │ │ ├── libtiff │ │ │ ├── Makefile.am │ │ │ ├── Makefile.in │ │ │ ├── Makefile.vc │ │ │ ├── SConstruct │ │ │ ├── libtiff.def │ │ │ ├── mkg3states.c │ │ │ ├── t4.h │ │ │ ├── tif_acorn.c │ │ │ ├── tif_apple.c │ │ │ ├── tif_atari.c │ │ │ ├── tif_aux.c │ │ │ ├── tif_close.c │ │ │ ├── tif_codec.c │ │ │ ├── tif_color.c │ │ │ ├── tif_compress.c │ │ │ ├── tif_config.h │ │ │ ├── tif_config.h-vms │ │ │ ├── tif_config.h.in │ │ │ ├── tif_config.vc.h │ │ │ ├── tif_config.wince.h │ │ │ ├── tif_dir.c │ │ │ ├── tif_dir.h │ │ │ ├── tif_dirinfo.c │ │ │ ├── tif_dirread.c │ │ │ ├── tif_dirwrite.c │ │ │ ├── tif_dumpmode.c │ │ │ ├── tif_error.c │ │ │ ├── tif_extension.c │ │ │ ├── tif_fax3.c │ │ │ ├── tif_fax3.h │ │ │ ├── tif_fax3sm.c │ │ │ ├── tif_flush.c │ │ │ ├── tif_getimage.c │ │ │ ├── tif_jbig.c │ │ │ ├── tif_jpeg.c │ │ │ ├── tif_luv.c │ │ │ ├── tif_lzw.c │ │ │ ├── tif_msdos.c │ │ │ ├── tif_next.c │ │ │ ├── tif_ojpeg.c │ │ │ ├── tif_open.c │ │ │ ├── tif_packbits.c │ │ │ ├── tif_pixarlog.c │ │ │ ├── tif_predict.c │ │ │ ├── tif_predict.h │ │ │ ├── tif_print.c │ │ │ ├── tif_read.c │ │ │ ├── tif_stream.cxx │ │ │ ├── tif_strip.c │ │ │ ├── tif_swab.c │ │ │ ├── tif_thunder.c │ │ │ ├── tif_tile.c │ │ │ ├── tif_unix.c │ │ │ ├── tif_version.c │ │ │ ├── tif_warning.c │ │ │ ├── tif_win3.c │ │ │ ├── tif_win32.c │ │ │ ├── tif_write.c │ │ │ ├── tif_zip.c │ │ │ ├── tiff.h │ │ │ ├── tiffconf.h │ │ │ ├── tiffconf.h.in │ │ │ ├── tiffconf.vc.h │ │ │ ├── tiffconf.wince.h │ │ │ ├── tiffio.h │ │ │ ├── tiffio.hxx │ │ │ ├── tiffiop.h │ │ │ ├── tiffvers.h │ │ │ └── uvcode.h │ │ ├── m4 │ │ │ ├── acinclude.m4 │ │ │ ├── libtool.m4 │ │ │ ├── ltoptions.m4 │ │ │ ├── ltsugar.m4 │ │ │ ├── ltversion.m4 │ │ │ └── lt~obsolete.m4 │ │ ├── man │ │ │ ├── Makefile.am │ │ │ ├── Makefile.in │ │ │ ├── TIFFClose.3tiff │ │ │ ├── TIFFDataWidth.3tiff │ │ │ ├── TIFFError.3tiff │ │ │ ├── TIFFFlush.3tiff │ │ │ ├── TIFFGetField.3tiff │ │ │ ├── TIFFOpen.3tiff │ │ │ ├── TIFFPrintDirectory.3tiff │ │ │ ├── TIFFRGBAImage.3tiff │ │ │ ├── TIFFReadDirectory.3tiff │ │ │ ├── TIFFReadEncodedStrip.3tiff │ │ │ ├── TIFFReadEncodedTile.3tiff │ │ │ ├── TIFFReadRGBAImage.3tiff │ │ │ ├── TIFFReadRGBAStrip.3tiff │ │ │ ├── TIFFReadRGBATile.3tiff │ │ │ ├── TIFFReadRawStrip.3tiff │ │ │ ├── TIFFReadRawTile.3tiff │ │ │ ├── TIFFReadScanline.3tiff │ │ │ ├── TIFFReadTile.3tiff │ │ │ ├── TIFFSetDirectory.3tiff │ │ │ ├── TIFFSetField.3tiff │ │ │ ├── TIFFWarning.3tiff │ │ │ ├── TIFFWriteDirectory.3tiff │ │ │ ├── TIFFWriteEncodedStrip.3tiff │ │ │ ├── TIFFWriteEncodedTile.3tiff │ │ │ ├── TIFFWriteRawStrip.3tiff │ │ │ ├── TIFFWriteRawTile.3tiff │ │ │ ├── TIFFWriteScanline.3tiff │ │ │ ├── TIFFWriteTile.3tiff │ │ │ ├── TIFFbuffer.3tiff │ │ │ ├── TIFFcodec.3tiff │ │ │ ├── TIFFcolor.3tiff │ │ │ ├── TIFFmemory.3tiff │ │ │ ├── TIFFquery.3tiff │ │ │ ├── TIFFsize.3tiff │ │ │ ├── TIFFstrip.3tiff │ │ │ ├── TIFFswab.3tiff │ │ │ ├── TIFFtile.3tiff │ │ │ ├── bmp2tiff.1 │ │ │ ├── fax2ps.1 │ │ │ ├── fax2tiff.1 │ │ │ ├── gif2tiff.1 │ │ │ ├── libtiff.3tiff │ │ │ ├── pal2rgb.1 │ │ │ ├── ppm2tiff.1 │ │ │ ├── ras2tiff.1 │ │ │ ├── raw2tiff.1 │ │ │ ├── rgb2ycbcr.1 │ │ │ ├── sgi2tiff.1 │ │ │ ├── thumbnail.1 │ │ │ ├── tiff2bw.1 │ │ │ ├── tiff2pdf.1 │ │ │ ├── tiff2ps.1 │ │ │ ├── tiff2rgba.1 │ │ │ ├── tiffcmp.1 │ │ │ ├── tiffcp.1 │ │ │ ├── tiffcrop.1 │ │ │ ├── tiffdither.1 │ │ │ ├── tiffdump.1 │ │ │ ├── tiffgt.1 │ │ │ ├── tiffinfo.1 │ │ │ ├── tiffmedian.1 │ │ │ ├── tiffset.1 │ │ │ ├── tiffsplit.1 │ │ │ └── tiffsv.1 │ │ ├── nmake.opt │ │ ├── port │ │ │ ├── Makefile.am │ │ │ ├── Makefile.in │ │ │ ├── Makefile.vc │ │ │ ├── dummy.c │ │ │ ├── getopt.c │ │ │ ├── lfind.c │ │ │ ├── libport.h │ │ │ ├── strcasecmp.c │ │ │ └── strtoul.c │ │ ├── test │ │ │ ├── Makefile.am │ │ │ ├── Makefile.in │ │ │ ├── ascii_tag.c │ │ │ ├── check_tag.c │ │ │ ├── long_tag.c │ │ │ ├── short_tag.c │ │ │ ├── strip.c │ │ │ ├── strip_rw.c │ │ │ ├── test_arrays.c │ │ │ └── test_arrays.h │ │ └── tools │ │ │ ├── Makefile.am │ │ │ ├── Makefile.in │ │ │ ├── Makefile.vc │ │ │ ├── bmp2tiff.c │ │ │ ├── fax2ps.c │ │ │ ├── fax2tiff.c │ │ │ ├── gif2tiff.c │ │ │ ├── pal2rgb.c │ │ │ ├── ppm2tiff.c │ │ │ ├── ras2tiff.c │ │ │ ├── rasterfile.h │ │ │ ├── raw2tiff.c │ │ │ ├── rgb2ycbcr.c │ │ │ ├── sgi2tiff.c │ │ │ ├── sgisv.c │ │ │ ├── thumbnail.c │ │ │ ├── tiff2bw.c │ │ │ ├── tiff2pdf.c │ │ │ ├── tiff2ps.c │ │ │ ├── tiff2rgba.c │ │ │ ├── tiffcmp.c │ │ │ ├── tiffcp.c │ │ │ ├── tiffcrop.c │ │ │ ├── tiffdither.c │ │ │ ├── tiffdump.c │ │ │ ├── tiffgt.c │ │ │ ├── tiffinfo.c │ │ │ ├── tiffmedian.c │ │ │ ├── tiffset.c │ │ │ ├── tiffsplit.c │ │ │ └── ycbcr.c │ ├── tiffconf.h │ ├── tiffio.h │ └── tiffvers.h │ └── res │ └── values │ └── strings.xml └── tiffbitmapfactory.iml /.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | *.o 3 | *.o.d 4 | *.so 5 | *.iml 6 | -------------------------------------------------------------------------------- /CHANGELOG.txt: -------------------------------------------------------------------------------- 1 | 0.9.9.0 2 | - Added support for decoding and converting files from file descriptors 3 | 4 | 0.9.8.7 5 | - Fixed converting from JPG to TIFF with CCITTRLE, CCITTFAX3, CCITTFAX4 compression schemes 6 | 7 | 0.9.8.6 8 | - Changed binary files (rebuild) 9 | 10 | 0.9.8.5 11 | - Added signal handling of SIGSEGV signal before open tiff images to prevent many silent crashes from libtiff 12 | 13 | 0.9.8.4 14 | - Added possibility to cancel background processing by interrupting of worker thread as usual in Java 15 | 16 | 0.9.8.3 17 | -Fixed impossibility to convert full image without bounds 18 | 19 | 0.9.8.2 20 | -Added handling of SIGSEGV crashes from libtiff 21 | 22 | 0.9.8 23 | -Added support for dirrect converting files to TIFF and from TIFF 24 | -Fixed bug causing crashing while saving tiff 25 | 26 | 0.9.7.6 27 | -Added support for CCITT modified Huffman RLE (CCITTRLE) compression scheme 28 | 29 | 0.9.7.5 30 | - Returned previous version of write bitmap to tiff algorithm with some improvements. This changes is due to an error of writing tiff data with bottom orientations 31 | 32 | 0.9.7.4 33 | - Add converter utils 34 | - Improved write and read algorithms 35 | 36 | 0.9.7.3 37 | - Add possibility to decode part of image by specify decode area 38 | 39 | 0.9.7.2 40 | - Changed saving algorithm to use android native bitmap 41 | - Add progress listener for decoding process 42 | 43 | 0.9.7.1 44 | - Added reading of various tiff tags 45 | - Changed enums 46 | 47 | 0.9.7 48 | - Added possibility to stop decoding that runs in separate thread 49 | - Fixed crashing when decoding images with bad metadata 50 | 51 | 0.9.6.2 52 | - Added support for TIFFTAG_XRESOLUTION, TIFFTAG_YRESOLUTION, TIFFTAG_RESOLUTIONUNIT 53 | 54 | 0.9.6 55 | - Added support for CCITT Group 3 and CCITT Group 4 compression schemes 56 | 57 | 0.9.5.1 58 | - Fixed decoding algorithm for stripped images 59 | 60 | 0.9.5 61 | - Added algorithms for efficient memory usage 62 | - Added switchers for throwing exceptions and using of tiff tag orientation 63 | 64 | -------------------------------------------------------------------------------- /build.gradle: -------------------------------------------------------------------------------- 1 | plugins { 2 | id "com.android.library" 3 | } 4 | 5 | android { 6 | compileSdkVersion 30 7 | buildToolsVersion '30.0.3' 8 | 9 | def softwareName 10 | 11 | defaultConfig { 12 | minSdkVersion 16 13 | targetSdkVersion 30 14 | versionCode 987 15 | versionName "0.9.9.0" 16 | 17 | softwareName = "\"" + project.name + "-" + versionName + "\"" 18 | } 19 | 20 | buildTypes { 21 | release { 22 | minifyEnabled false 23 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 24 | buildConfigField("String", "softwarename", softwareName) 25 | } 26 | debug { 27 | minifyEnabled false 28 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 29 | buildConfigField("String", "softwarename", softwareName) 30 | } 31 | } 32 | 33 | ndkVersion "21.3.6528147" 34 | 35 | sourceSets.main { 36 | jni.srcDirs = [] 37 | jniLibs.srcDir 'src/main/libs' 38 | } 39 | } 40 | 41 | android { 42 | lintOptions { 43 | abortOnError false 44 | } 45 | } 46 | 47 | dependencies { 48 | } 49 | 50 | ext { 51 | PUBLISH_GROUP_ID = 'io.github.beyka' 52 | PUBLISH_VERSION = '0.9.9.0' 53 | PUBLISH_ARTIFACT_ID = 'Android-TiffBitmapFactory' 54 | } 55 | apply from: "${rootProject.projectDir}/publish-module.gradle" 56 | -------------------------------------------------------------------------------- /license.txt: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright © «2018» «Oleksii Bei aka Beyka» 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 6 | 7 | The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 8 | 9 | THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 10 | -------------------------------------------------------------------------------- /proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /home/alexeyba/android-sdk-linux/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 10 | # Add any project specific keep options here: 11 | 12 | # If your project uses WebView with JS, uncomment the following 13 | # and specify the fully qualified class name to the JavaScript interface 14 | # class: 15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 16 | # public *; 17 | #} 18 | -------------------------------------------------------------------------------- /src/androidTest/java/org/beyka/tiffbitmapfactory/ApplicationTest.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory; 2 | 3 | import android.app.Application; 4 | import android.test.ApplicationTestCase; 5 | 6 | /** 7 | * Testing Fundamentals 8 | */ 9 | public class ApplicationTest extends ApplicationTestCase { 10 | public ApplicationTest() { 11 | super(Application.class); 12 | } 13 | } -------------------------------------------------------------------------------- /src/main/.gitignore: -------------------------------------------------------------------------------- 1 | /obj/ 2 | -------------------------------------------------------------------------------- /src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /src/main/java/org/beyka/tiffbitmapfactory/CompressionScheme.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory; 2 | 3 | /** 4 | * Created by beyka on 5.1.17. 5 | */ 6 | 7 | public enum CompressionScheme { 8 | /** 9 | * No compression 10 | */ 11 | NONE(1), 12 | /** 13 | * CCITT modified Huffman RLE 14 | */ 15 | CCITTRLE(2), 16 | /** 17 | * CCITT Group 3 fax encoding 18 | */ 19 | CCITTFAX3(3), 20 | /** 21 | * CCITT Group 4 fax encoding 22 | */ 23 | CCITTFAX4(4), 24 | /** 25 | * LZW 26 | */ 27 | LZW(5), 28 | /** 29 | * JPEG ('new-style' JPEG) 30 | */ 31 | JPEG(7), 32 | PACKBITS(32773), 33 | DEFLATE(32946), 34 | ADOBE_DEFLATE(8), 35 | /** 36 | * All other compression schemes 37 | */ 38 | OTHER(0); 39 | 40 | final int ordinal; 41 | 42 | CompressionScheme(int ordinal) { 43 | this.ordinal = ordinal; 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /src/main/java/org/beyka/tiffbitmapfactory/DecodeArea.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory; 2 | 3 | /** 4 | * Created by beyka on 10/24/17. 5 | */ 6 | 7 | /** 8 | * Holder for points of decode area 9 | */ 10 | public class DecodeArea { 11 | public int x; 12 | public int y; 13 | public int width; 14 | public int height; 15 | 16 | public DecodeArea(){} 17 | 18 | public DecodeArea(int x, int y, int width, int height) { 19 | this.x = x; 20 | this.y = y; 21 | this.width = width; 22 | this.height = height; 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /src/main/java/org/beyka/tiffbitmapfactory/FillOrder.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory; 2 | 3 | /** 4 | * Created by beyka on 4/16/17. 5 | */ 6 | 7 | public enum FillOrder { 8 | 9 | /** 10 | * Pixels with lower column values are stored in the higher-order bits of the byte. 11 | */ 12 | MSB2LSB(1), 13 | 14 | /** 15 | * Pixels with lower column values are stored in the lower-order bits of the byte. 16 | */ 17 | LSB2MSB(2); 18 | 19 | final int ordinal; 20 | 21 | FillOrder(int ordinal) { 22 | this.ordinal = ordinal; 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /src/main/java/org/beyka/tiffbitmapfactory/IProgressListener.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory; 2 | 3 | /** 4 | * Created by beyka on 4/26/17. 5 | */ 6 | 7 | public interface IProgressListener { 8 | public void reportProgress(long processedPixels, long totalPixels); 9 | } 10 | -------------------------------------------------------------------------------- /src/main/java/org/beyka/tiffbitmapfactory/ImageFormat.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory; 2 | 3 | /** 4 | * Supported image formats 5 | */ 6 | 7 | public enum ImageFormat { 8 | UNKNOWN(0), 9 | JPEG(1), 10 | PNG(2), 11 | TIFF(4), 12 | BMP(5); 13 | 14 | final int ordinal; 15 | 16 | ImageFormat(int ordinal) { 17 | this.ordinal = ordinal; 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/main/java/org/beyka/tiffbitmapfactory/Orientation.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory; 2 | 3 | /** 4 | * Created by beyka on 5.1.17. 5 | */ 6 | 7 | public enum Orientation { 8 | TOP_LEFT(1), 9 | TOP_RIGHT(2), 10 | BOT_RIGHT(3), 11 | BOT_LEFT(4), 12 | LEFT_TOP(5), 13 | RIGHT_TOP(6), 14 | RIGHT_BOT(7), 15 | LEFT_BOT(8), 16 | UNAVAILABLE(0); 17 | 18 | final int ordinal; 19 | 20 | Orientation(int ordinal) { 21 | this.ordinal = ordinal; 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /src/main/java/org/beyka/tiffbitmapfactory/Photometric.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory; 2 | 3 | /** 4 | * Created by beyka on 4/16/17. 5 | */ 6 | 7 | public enum Photometric { 8 | 9 | /** 10 | * WhiteIsZero. For bilevel and grayscale images: 0 is imaged as white. 11 | */ 12 | MINISWHITE(0), 13 | 14 | /** 15 | * BlackIsZero. For bilevel and grayscale images: 0 is imaged as black. 16 | */ 17 | MINISBLACK(1), 18 | 19 | /** 20 | * RGB value of (0,0,0) represents black, and (255,255,255) represents white, assuming 8-bit components. The components are stored in the indicated order: first Red, then Green, then Blue. 21 | */ 22 | RGB(2), 23 | 24 | /** 25 | * Palette color. In this model, a color is described with a single component. The value of the component is used as an index into the red, green and blue curves in the ColorMap field to retrieve an RGB triplet that defines the color. When PhotometricInterpretation=3 is used, ColorMap must be present and SamplesPerPixel must be 1. 26 | */ 27 | PALETTE(3), 28 | 29 | /** 30 | * Transparency Mask. This means that the image is used to define an irregularly shaped region of another image in the same TIFF file. SamplesPerPixel and BitsPerSample must be 1. PackBits compression is recommended. The 1-bits define the interior of the region; the 0-bits define the exterior of the region. 31 | */ 32 | MASK(4), 33 | 34 | /** 35 | * Seperated, usually CMYK. 36 | */ 37 | SEPARATED(5), 38 | 39 | /** 40 | * YCbCr 41 | */ 42 | YCBCR(6), 43 | 44 | /** 45 | * CIE L*a*b* 46 | */ 47 | CIELAB(8), 48 | 49 | /** 50 | * CIE L*a*b*, alternate encoding also known as ICC L*a*b* 51 | */ 52 | ICCLAB(9), 53 | 54 | /** 55 | * CIE L*a*b*, alternate encoding also known as ITU L*a*b*, defined in ITU-T Rec. T.42, used in the TIFF-F and TIFF-FX standard (RFC 2301). The Decode tag, if present, holds information about this particular CIE L*a*b* encoding. 56 | */ 57 | ITULAB(10), 58 | 59 | /** 60 | * LOGL 61 | */ 62 | LOGL(32844), 63 | 64 | /** 65 | * LOGLUV 66 | */ 67 | LOGLUV(32845), 68 | 69 | /** 70 | * Some unknown photometric 71 | */ 72 | OTHER(-1); 73 | 74 | final int ordinal; 75 | 76 | Photometric(int ordinal) { 77 | this.ordinal = ordinal; 78 | } 79 | } 80 | -------------------------------------------------------------------------------- /src/main/java/org/beyka/tiffbitmapfactory/PlanarConfig.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory; 2 | 3 | /** 4 | * Created by beyka on 4/16/17. 5 | */ 6 | 7 | public enum PlanarConfig { 8 | CONTIG(1), 9 | SEPARATE(2); 10 | 11 | final int ordinal; 12 | 13 | PlanarConfig(int ordinal) { 14 | this.ordinal = ordinal; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/main/java/org/beyka/tiffbitmapfactory/ResolutionUnit.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory; 2 | 3 | /** 4 | * Created by beyka on 13.3.17. 5 | */ 6 | 7 | public enum ResolutionUnit { 8 | NONE(1), 9 | INCH(2), 10 | CENTIMETER(3); 11 | 12 | final int ordinal; 13 | 14 | ResolutionUnit(int ordinal) { 15 | this.ordinal = ordinal; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /src/main/java/org/beyka/tiffbitmapfactory/exceptions/CantOpenFileException.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory.exceptions; 2 | 3 | /** 4 | * Created by alexeyba on 09.11.15. 5 | */ 6 | public class CantOpenFileException extends RuntimeException { 7 | private String fileName; 8 | private int fileDescriptor = -1; 9 | 10 | public CantOpenFileException(String fileName){ 11 | super("Can\'t open file " + fileName); 12 | this.fileName = fileName; 13 | } 14 | 15 | public CantOpenFileException(int fileDescriptor){ 16 | super("Can\'t open file with file descriptor " + fileDescriptor); 17 | this.fileDescriptor = fileDescriptor; 18 | } 19 | 20 | public String getFileName(){ 21 | return fileName; 22 | } 23 | 24 | public int getFileDescriptor() { 25 | return fileDescriptor; 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /src/main/java/org/beyka/tiffbitmapfactory/exceptions/DecodeTiffException.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory.exceptions; 2 | 3 | /** 4 | * Created by alexeyba on 09.11.15. 5 | */ 6 | public class DecodeTiffException extends RuntimeException { 7 | 8 | private String fileName; 9 | private String aditionalInfo; 10 | private int fileDescriptor = -1; 11 | 12 | public DecodeTiffException(String fileName){ 13 | super("Could not decode tiff file " + fileName); 14 | this.fileName = fileName; 15 | } 16 | 17 | public DecodeTiffException(int fileDescriptor) { 18 | super("Could not decode tiff file with file descriptor " + fileDescriptor); 19 | this.fileDescriptor = fileDescriptor; 20 | } 21 | 22 | public DecodeTiffException(String fileName, String aditionaInfo){ 23 | super("Could not decode tiff file " + fileName + "\n" + aditionaInfo); 24 | this.fileName = fileName; 25 | this.aditionalInfo = aditionaInfo; 26 | } 27 | 28 | public DecodeTiffException(int fileDescriptor, String aditionaInfo){ 29 | super("Could not decode tiff file with file descriptor" + fileDescriptor + "\n" + aditionaInfo); 30 | this.fileDescriptor = fileDescriptor; 31 | this.aditionalInfo = aditionaInfo; 32 | } 33 | 34 | public String getFileName(){ 35 | return fileName; 36 | } 37 | 38 | public String getAditionalInfo() { 39 | return aditionalInfo; 40 | } 41 | 42 | public int getFileDescriptor() { 43 | return fileDescriptor; 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /src/main/java/org/beyka/tiffbitmapfactory/exceptions/NotEnoughtMemoryException.java: -------------------------------------------------------------------------------- 1 | package org.beyka.tiffbitmapfactory.exceptions; 2 | 3 | /** 4 | * Created by alexeyba on 09.11.15. 5 | */ 6 | public class NotEnoughtMemoryException extends RuntimeException { 7 | 8 | private int availableMemory; 9 | private int needMemory; 10 | 11 | public NotEnoughtMemoryException(int availableMemory, int needMemory){ 12 | super("Available memory is not enought to decode image. Available " + availableMemory + " bytes. Need " + needMemory + " bytes."); 13 | this.availableMemory = availableMemory; 14 | this.needMemory = needMemory; 15 | } 16 | 17 | public int getAvailableMemory() { 18 | return availableMemory; 19 | } 20 | 21 | public int getNeedMemory() { 22 | return needMemory; 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /src/main/jni/Application.mk: -------------------------------------------------------------------------------- 1 | APP_STL := c++_static 2 | 3 | APP_MODULES := tiff png jpeg tifffactory tiffsaver tiffconverter 4 | 5 | APP_PLATFORM=android-16 6 | 7 | APP_ABI := arm64-v8a, armeabi-v7a 8 | 9 | #APP_OPTIM := debug -------------------------------------------------------------------------------- /src/main/jni/BMP.h: -------------------------------------------------------------------------------- 1 | // 2 | // Created by beyka on 9/21/17. 3 | // 4 | 5 | #ifndef __BMP_H_INCLUDED__ // if x.h hasn't been included yet... 6 | #define __BMP_H_INCLUDED__ 7 | 8 | #pragma pack(2) 9 | typedef struct BITMAPFILEHEADER 10 | { 11 | BITMAPFILEHEADER() : bfReserved1(0), bfReserved2(0) {} 12 | unsigned char bfType[2]; 13 | unsigned int bfSize; 14 | unsigned short bfReserved1; 15 | unsigned short bfReserved2; 16 | unsigned int bfOffBits; 17 | } BITMAPFILEHEADER; 18 | 19 | typedef struct /**** BMP file info structure ****/ 20 | { 21 | unsigned int biSize; /* Size of info header */ 22 | int biWidth; /* Width of image */ 23 | int biHeight; /* Height of image */ 24 | unsigned short biPlanes; /* Number of color planes */ 25 | unsigned short biBitCount; /* Number of bits per pixel */ 26 | unsigned int biCompression; /* Type of compression to use 0 - none, 1 - rle 8 bit, 2 - rle 4 but, 3 - bi_bitfields*/ 27 | unsigned int biSizeImage; /* Size of image data */ 28 | int biXPelsPerMeter; /* X pixels per meter */ 29 | int biYPelsPerMeter; /* Y pixels per meter */ 30 | unsigned int biClrUsed; /* Number of colors used */ 31 | unsigned int biClrImportant; /* Number of important colors */ 32 | unsigned int biPalete[3] ; 33 | unsigned char reserved[56]; 34 | /* Palete (masks for 16 bit bmps)*/ 35 | /*a 5-5-5 16-bit image, where the blue mask is 0x001f, the green mask is 0x03e0, and the red mask is 0x7c00; and a 5-6-5 16-bit image, where the blue mask is 0x001f, the green mask is 0x07e0, and the red mask is 0xf800*/ 36 | } BITMAPINFOHEADER; 37 | 38 | 39 | #pragma pack() 40 | 41 | #endif -------------------------------------------------------------------------------- /src/main/jni/BitmapReader.h: -------------------------------------------------------------------------------- 1 | // 2 | // Created by beyka on 9/21/17. 3 | // 4 | 5 | #ifndef TIFFSAMPLE_BITMAPREADER_H 6 | #define TIFFSAMPLE_BITMAPREADER_H 7 | 8 | #include 9 | #include 10 | #include 11 | #include "string.h" 12 | #include "NativeExceptions.h" 13 | #include 14 | #include 15 | #include "unistd.h" 16 | #include 17 | 18 | #ifdef NDEBUG 19 | #define LOGI(x) 20 | #define LOGII(x, y) 21 | #define LOGIF(x, y) 22 | #define LOGIS(x, y) 23 | #define LOGE(x) 24 | #define LOGES(x, y) 25 | #else 26 | #define LOGI(x) __android_log_print(ANDROID_LOG_DEBUG, "BMPReader", "%s", x) 27 | #define LOGII(x, y) __android_log_print(ANDROID_LOG_DEBUG, "BMPReader", "%s %d", x, y) 28 | #define LOGIF(x, y) __android_log_print(ANDROID_LOG_DEBUG, "BMPReader", "%s %f", x, y) 29 | #define LOGIS(x, y) __android_log_print(ANDROID_LOG_DEBUG, "BMPReader", "%s %s", x, y) 30 | #define LOGE(x) __android_log_print(ANDROID_LOG_ERROR, "BMPReader", "%s", x) 31 | #define LOGES(x, y) __android_log_print(ANDROID_LOG_ERROR, "BMPReader", "%s %s", x, y) 32 | #endif 33 | 34 | #ifdef __cplusplus 35 | extern "C" { 36 | #endif 37 | 38 | jobject readBmp 39 | (JNIEnv *env, jclass clazz, jstring tiffPath, jstring pngPath, jobject options, jobject listener); 40 | 41 | #ifdef __cplusplus 42 | } 43 | #endif 44 | #endif //TIFFSAMPLE_BITMAPREADER_H 45 | -------------------------------------------------------------------------------- /src/main/jni/BmpToTiffConverter.h: -------------------------------------------------------------------------------- 1 | // 2 | // Created by beyka on 9/20/17. 3 | // 4 | 5 | #ifndef TIFFSAMPLE_BMPTOTIFFCONVERTER_H 6 | #define TIFFSAMPLE_BMPTOTIFFCONVERTER_H 7 | 8 | #include 9 | #include 10 | #include 11 | #include "fcntl.h" 12 | #include "unistd.h" 13 | #include 14 | #include 15 | #include "BaseTiffConverter.h" 16 | #include "BMP.h" 17 | 18 | #ifdef NDEBUG 19 | #define LOGI(x) 20 | #define LOGII(x, y) 21 | #define LOGIF(x, y) 22 | #define LOGIS(x, y) 23 | #define LOGE(x) 24 | #define LOGES(x, y) 25 | #define LOGEI(x, y) 26 | #else 27 | #define LOGI(x) __android_log_print(ANDROID_LOG_DEBUG, "BmpToTiffConverter", "%s", x) 28 | #define LOGII(x, y) __android_log_print(ANDROID_LOG_DEBUG, "BmpToTiffConverter", "%s %d", x, y) 29 | #define LOGIF(x, y) __android_log_print(ANDROID_LOG_DEBUG, "BmpToTiffConverter", "%s %f", x, y) 30 | #define LOGIS(x, y) __android_log_print(ANDROID_LOG_DEBUG, "BmpToTiffConverter", "%s %s", x, y) 31 | #define LOGE(x) __android_log_print(ANDROID_LOG_ERROR, "BmpToTiffConverter", "%s", x) 32 | #define LOGES(x, y) __android_log_print(ANDROID_LOG_ERROR, "BmpToTiffConverter", "%s %s", x, y) 33 | #define LOGEI(x, y) __android_log_print(ANDROID_LOG_ERROR, "BmpToTiffConverter", "%s %d", x, y) 34 | #endif 35 | 36 | class BmpToTiffConverter : public BaseTiffConverter 37 | { 38 | public: 39 | explicit BmpToTiffConverter(JNIEnv *, jclass, jstring, jstring, jobject, jobject); 40 | explicit BmpToTiffConverter(JNIEnv *, jclass, jint, jint, jobject, jobject); 41 | ~BmpToTiffConverter(); 42 | virtual jboolean convert(); 43 | 44 | private: 45 | TIFF *tiffImage; 46 | BITMAPFILEHEADER *bmp; 47 | BITMAPINFOHEADER *inf; 48 | 49 | void readHeaders(); 50 | 51 | uint32 * getPixelsFromBmp(int offset, int limit); 52 | uint32 * getPixelsFrom16Bmp(int offset, int limit); 53 | uint32 * getPixelsFrom24Bmp(int offset, int limit); 54 | uint32 * getPixelsFrom32Bmp(int offset, int limit); 55 | 56 | unsigned char * convertArgbToBilevel(uint32 *, uint32, uint32); 57 | 58 | }; 59 | 60 | #endif //TIFFSAMPLE_BMPTOTIFFCONVERTER_H 61 | -------------------------------------------------------------------------------- /src/main/jni/JpgToTiffConverter.h: -------------------------------------------------------------------------------- 1 | // 2 | // Created by beyka on 5/15/17. 3 | // 4 | 5 | #ifndef TIFFSAMPLE_JPGTOTIFFCONVERTER_H 6 | #define TIFFSAMPLE_JPGTOTIFFCONVERTER_H 7 | 8 | #include 9 | #include 10 | #include 11 | #include "fcntl.h" 12 | #include "unistd.h" 13 | #include 14 | #include 15 | #include "BaseTiffConverter.h" 16 | 17 | #ifdef NDEBUG 18 | #define LOGI(x) 19 | #define LOGII(x, y) 20 | #define LOGIF(x, y) 21 | #define LOGIS(x, y) 22 | #define LOGE(x) 23 | #define LOGES(x, y) 24 | #define LOGEI(x, y); 25 | #else 26 | #define LOGI(x) __android_log_print(ANDROID_LOG_DEBUG, "JpgToTiffConverter", "%s", x) 27 | #define LOGII(x, y) __android_log_print(ANDROID_LOG_DEBUG, "JpgToTiffConverter", "%s %d", x, y) 28 | #define LOGIF(x, y) __android_log_print(ANDROID_LOG_DEBUG, "JpgToTiffConverter", "%s %f", x, y) 29 | #define LOGIS(x, y) __android_log_print(ANDROID_LOG_DEBUG, "JpgToTiffConverter", "%s %s", x, y) 30 | #define LOGE(x) __android_log_print(ANDROID_LOG_ERROR, "JpgToTiffConverter", "%s", x) 31 | #define LOGES(x, y) __android_log_print(ANDROID_LOG_ERROR, "JpgToTiffConverter", "%s %s", x, y) 32 | #define LOGEI(x, y) __android_log_print(ANDROID_LOG_ERROR, "JpgToTiffConverter", "%s %d", x, y) 33 | #endif 34 | 35 | class JpgToTiffConverter : public BaseTiffConverter 36 | { 37 | public: 38 | explicit JpgToTiffConverter(JNIEnv *, jclass, jstring, jstring, jobject, jobject); 39 | explicit JpgToTiffConverter(JNIEnv *, jclass, jint, jint, jobject, jobject); 40 | ~JpgToTiffConverter(); 41 | virtual jboolean convert(); 42 | 43 | private: 44 | TIFF *tiffImage; 45 | FILE *inFile; 46 | 47 | int componentsPerPixel; 48 | 49 | char jpeg_struct_init; 50 | struct jpeg_decompress_struct cinfo; 51 | struct jpeg_error_mgr jerr; 52 | 53 | //METHODDEF(void) JpgToTiffConverter::my_error_exit (j_common_ptr) 54 | unsigned char * convertArgbToBilevel(unsigned char *, int, uint32, uint32); 55 | 56 | }; 57 | 58 | 59 | #endif //TIFFSAMPLE_JPGTOTIFFCONVERTER_H 60 | -------------------------------------------------------------------------------- /src/main/jni/NativeExceptions.h: -------------------------------------------------------------------------------- 1 | // 2 | // Created by alexeyba on 09.11.15. 3 | // 4 | 5 | #ifdef __cplusplus 6 | extern "C" { 7 | #endif 8 | 9 | #ifndef TIFFEXAMPLE_NATIVEEXCEPTIONS_H 10 | #define TIFFEXAMPLE_NATIVEEXCEPTIONS_H 11 | 12 | 13 | 14 | #include 15 | #include 16 | 17 | #ifdef NDEBUG 18 | #define LOGI(x) 19 | #define LOGII(x, y) 20 | #define LOGIS(x, y) 21 | #else 22 | #define LOGI(x) __android_log_print(ANDROID_LOG_DEBUG, "NativeDecoder", "%s", x) 23 | #define LOGII(x, y) __android_log_print(ANDROID_LOG_DEBUG, "NativeDecoder", "%s %d", x, y) 24 | #define LOGIS(x, y) __android_log_print(ANDROID_LOG_DEBUG, "NativeDecoder", "%s %s", x, y) 25 | #endif 26 | 27 | void throw_not_enought_memory_exception(JNIEnv *, int, int); 28 | void throw_decode_file_exception(JNIEnv *, jstring, jstring); 29 | void throw_decode_file_exception_fd(JNIEnv *, jint, jstring); 30 | void throw_cant_open_file_exception(JNIEnv *, jstring); 31 | void throw_cant_open_file_exception_fd(JNIEnv *, jint); 32 | 33 | #endif //TIFFEXAMPLE_NATIVEEXCEPTIONS_H 34 | 35 | #ifdef __cplusplus 36 | } 37 | #endif 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /src/main/jni/NativeTiffBitmapFactory.cpp: -------------------------------------------------------------------------------- 1 | using namespace std; 2 | 3 | #ifdef __cplusplus 4 | extern "C" { 5 | #endif 6 | 7 | #include "NativeTiffBitmapFactory.h" 8 | 9 | JNIEXPORT jobject 10 | JNICALL Java_org_beyka_tiffbitmapfactory_TiffBitmapFactory_nativeDecodePath 11 | (JNIEnv *env, jclass clazz, jstring path, jobject options, jobject listener) { 12 | 13 | NativeDecoder *decoder = new NativeDecoder(env, clazz, path, options, listener); 14 | jobject java_bitmap = decoder->getBitmap(); 15 | delete(decoder); 16 | 17 | return java_bitmap; 18 | } 19 | 20 | JNIEXPORT jobject 21 | JNICALL Java_org_beyka_tiffbitmapfactory_TiffBitmapFactory_nativeDecodeFD 22 | (JNIEnv *env, jclass clazz, jint fd, jobject options, jobject listener) { 23 | 24 | NativeDecoder *decoder = new NativeDecoder(env, clazz, fd, options, listener); 25 | jobject java_bitmap = decoder->getBitmap(); 26 | delete(decoder); 27 | 28 | return java_bitmap; 29 | } 30 | 31 | JNIEXPORT jobject 32 | JNICALL Java_org_beyka_tiffbitmapfactory_TiffBitmapFactory_nativeCloseFd 33 | (JNIEnv *env, jclass clazz, jint fd) { 34 | close(fd); 35 | } 36 | 37 | #ifdef __cplusplus 38 | } 39 | #endif 40 | -------------------------------------------------------------------------------- /src/main/jni/NativeTiffBitmapFactory.h: -------------------------------------------------------------------------------- 1 | /* DO NOT EDIT THIS FILE - it is machine generated */ 2 | #include 3 | #include 4 | #include 5 | #include 6 | #include 7 | #include 8 | #include 9 | #include "NativeExceptions.h" 10 | #include "NativeDecoder.h" 11 | /* Header for class NativeTiffBitmapFactory */ 12 | 13 | #ifdef NDEBUG 14 | #define LOGI(x) 15 | #define LOGII(x, y) 16 | #define LOGIS(x, y) 17 | #define LOGE(x) 18 | #define LOGES(x, y) 19 | #else 20 | #define LOGI(x) __android_log_print(ANDROID_LOG_DEBUG, "NativeTiffBitmapFactory", "%s", x) 21 | #define LOGII(x, y) __android_log_print(ANDROID_LOG_DEBUG, "NativeTiffBitmapFactory", "%s %d", x, y) 22 | #define LOGIS(x, y) __android_log_print(ANDROID_LOG_DEBUG, "NativeTiffBitmapFactory", "%s %s", x, y) 23 | #define LOGE(x) __android_log_print(ANDROID_LOG_ERROR, "NativeTiffBitmapFactory", "%s", x) 24 | #define LOGES(x, y) __android_log_print(ANDROID_LOG_ERROR, "NativeTiffBitmapFactory", "%s %s", x, y) 25 | #endif 26 | 27 | #ifndef _Included_org_beyka_tiffbitmapfactory_TiffBitmapFactory 28 | #define _Included_org_beyka_tiffbitmapfactory_TiffBitmapFactory 29 | #ifdef __cplusplus 30 | extern "C" { 31 | #endif 32 | /* 33 | * Class: com_example_beyka_tiffexample_TiffBitmapFactory 34 | * Method: nativeDecodePath 35 | * Signature: (Ljava/lang/String;I)Landroid/graphics/Bitmap; 36 | */ 37 | JNIEXPORT jobject JNICALL Java_org_beyka_tiffbitmapfactory_TiffBitmapFactory_nativeDecodePath 38 | (JNIEnv *, jclass, jstring, jobject, jobject); 39 | 40 | /* 41 | * Class: com_example_beyka_tiffexample_TiffBitmapFactory 42 | * Method: nativeDecodePath 43 | * Signature: (Ljava/lang/String;I)Landroid/graphics/Bitmap; 44 | */ 45 | JNIEXPORT jobject JNICALL Java_org_beyka_tiffbitmapfactory_TiffBitmapFactory_nativeDecodeFD 46 | (JNIEnv *, jclass, jint, jobject, jobject); 47 | 48 | /* 49 | * Class: com_example_beyka_tiffexample_TiffBitmapFactory 50 | * Method: nativeCloseFd 51 | * Signature: (Ljava/lang/String;I)Landroid/graphics/Bitmap; 52 | */ 53 | JNIEXPORT jobject JNICALL Java_org_beyka_tiffbitmapfactory_TiffBitmapFactory_nativeCloseFd 54 | (JNIEnv *, jclass, jint); 55 | 56 | 57 | #ifdef __cplusplus 58 | } 59 | #endif 60 | #endif 61 | -------------------------------------------------------------------------------- /src/main/jni/NativeTiffSaver.h: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | #include 6 | #include 7 | #include "fcntl.h" 8 | #include "unistd.h" 9 | #include 10 | #include "string.h" 11 | #include "NativeExceptions.h" 12 | 13 | #ifdef NDEBUG 14 | #define LOGI(x) 15 | #define LOGII(x, y) 16 | #define LOGIF(x, y) 17 | #define LOGIS(x, y) 18 | #define LOGE(x) 19 | #define LOGES(x, y) 20 | #else 21 | #define LOGI(x) __android_log_print(ANDROID_LOG_DEBUG, "NativeTiffSaver", "%s", x) 22 | #define LOGII(x, y) __android_log_print(ANDROID_LOG_DEBUG, "NativeTiffSaver", "%s %d", x, y) 23 | #define LOGIF(x, y) __android_log_print(ANDROID_LOG_DEBUG, "NativeTiffSaver", "%s %f", x, y) 24 | #define LOGIS(x, y) __android_log_print(ANDROID_LOG_DEBUG, "NativeTiffSaver", "%s %s", x, y) 25 | #define LOGE(x) __android_log_print(ANDROID_LOG_ERROR, "NativeTiffSaver", "%s", x) 26 | #define LOGES(x, y) __android_log_print(ANDROID_LOG_ERROR, "NativeTiffSaver", "%s %s", x, y) 27 | #endif 28 | 29 | #ifndef _Included_org_beyka_tiffbitmapfactory_TiffSaver 30 | #define _Included_org_beyka_tiffbitmapfactory_TiffSaver 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif 34 | /* 35 | * Class: org_beyka_tiffbitmapfactory_TiffSaver 36 | * Method: save 37 | * Signature: (Ljava/lang/String;)V 38 | */ 39 | JNIEXPORT jboolean JNICALL Java_org_beyka_tiffbitmapfactory_TiffSaver_save 40 | (JNIEnv *, jclass, jstring, jint, jobject, jobject, jboolean); 41 | 42 | JNIEXPORT jobject JNICALL Java_org_beyka_tiffbitmapfactory_TiffSaver_nativeCloseFd 43 | (JNIEnv *, jclass, jint); 44 | 45 | unsigned char *convertArgbToBilevel(uint32 *, jint, jint); 46 | 47 | char *getCreationDate(); 48 | 49 | char *concat(const char *, const char *); 50 | 51 | #ifdef __cplusplus 52 | } 53 | #endif 54 | #endif 55 | -------------------------------------------------------------------------------- /src/main/jni/PngToTiffConverter.h: -------------------------------------------------------------------------------- 1 | // 2 | // Created by beyka on 5/12/17. 3 | // 4 | 5 | #ifndef TIFFSAMPLE_PNGTOTIFFCONVERTER_H 6 | #define TIFFSAMPLE_PNGTOTIFFCONVERTER_H 7 | 8 | #include 9 | #include 10 | #include 11 | #include "fcntl.h" 12 | #include "unistd.h" 13 | #include 14 | #include 15 | #include "BaseTiffConverter.h" 16 | 17 | #ifdef NDEBUG 18 | #define LOGI(x) 19 | #define LOGII(x, y) 20 | #define LOGIF(x, y) 21 | #define LOGIS(x, y) 22 | #define LOGE(x) 23 | #define LOGES(x, y) 24 | #define LOGEI(x, y) 25 | #else 26 | #define LOGI(x) __android_log_print(ANDROID_LOG_DEBUG, "PngToTiffConverter", "%s", x) 27 | #define LOGII(x, y) __android_log_print(ANDROID_LOG_DEBUG, "PngToTiffConverter", "%s %d", x, y) 28 | #define LOGIF(x, y) __android_log_print(ANDROID_LOG_DEBUG, "PngToTiffConverter", "%s %f", x, y) 29 | #define LOGIS(x, y) __android_log_print(ANDROID_LOG_DEBUG, "PngToTiffConverter", "%s %s", x, y) 30 | #define LOGE(x) __android_log_print(ANDROID_LOG_ERROR, "PngToTiffConverter", "%s", x) 31 | #define LOGES(x, y) __android_log_print(ANDROID_LOG_ERROR, "PngToTiffConverter", "%s %s", x, y) 32 | #define LOGEI(x, y) __android_log_print(ANDROID_LOG_ERROR, "PngToTiffConverter", "%s %d", x, y) 33 | #endif 34 | 35 | class PngToTiffConverter : public BaseTiffConverter 36 | { 37 | public: 38 | explicit PngToTiffConverter(JNIEnv *, jclass, jstring, jstring, jobject, jobject); 39 | explicit PngToTiffConverter(JNIEnv *, jclass, jint, jint, jobject, jobject); 40 | ~PngToTiffConverter(); 41 | virtual jboolean convert(); 42 | 43 | private: 44 | TIFF *tiffImage; 45 | FILE *inFile; 46 | char png_ptr_init; 47 | png_structp png_ptr; 48 | char png_info_init; 49 | png_infop info_ptr; 50 | 51 | int bit_depth; 52 | int color_type; 53 | 54 | //unsigned char * convertArgbToBilevel(png_byte *, int, uint32, uint32); 55 | unsigned char * convertArgbToBilevel(png_bytep *, int, uint32, uint32); 56 | }; 57 | 58 | #endif //TIFFSAMPLE_PNGTOTIFFCONVERTER_H 59 | -------------------------------------------------------------------------------- /src/main/jni/TiffToBmpConverter.h: -------------------------------------------------------------------------------- 1 | // 2 | // Created by beyka on 9/22/17. 3 | // 4 | 5 | #ifndef TIFFSAMPLE_TIFFTOBMPCONVERTER_H 6 | #define TIFFSAMPLE_TIFFTOBMPCONVERTER_H 7 | 8 | #include 9 | #include 10 | #include 11 | #include "fcntl.h" 12 | #include "unistd.h" 13 | #include "jpeglib.h" 14 | #include 15 | #include "BaseTiffConverter.h" 16 | #include "BMP.h" 17 | 18 | #ifdef NDEBUG 19 | #define LOGI(x) 20 | #define LOGII(x, y) 21 | #define LOGIF(x, y) 22 | #define LOGIS(x, y) 23 | #define LOGE(x) 24 | #define LOGES(x, y) 25 | #define LOGEI(x, y) 26 | #else 27 | #define LOGI(x) __android_log_print(ANDROID_LOG_DEBUG, "TiffToBmpConverter", "%s", x) 28 | #define LOGII(x, y) __android_log_print(ANDROID_LOG_DEBUG, "TiffToBmpConverter", "%s %d", x, y) 29 | #define LOGIF(x, y) __android_log_print(ANDROID_LOG_DEBUG, "TiffToBmpConverter", "%s %f", x, y) 30 | #define LOGIS(x, y) __android_log_print(ANDROID_LOG_DEBUG, "TiffToBmpConverter", "%s %s", x, y) 31 | #define LOGE(x) __android_log_print(ANDROID_LOG_ERROR, "TiffToBmpConverter", "%s", x) 32 | #define LOGES(x, y) __android_log_print(ANDROID_LOG_ERROR, "TiffToBmpConverter", "%s %s", x, y) 33 | #define LOGEI(x, y) __android_log_print(ANDROID_LOG_ERROR, "TiffToBmpConverter", "%s %d", x, y) 34 | #endif 35 | 36 | class TiffToBmpConverter : public BaseTiffConverter 37 | { 38 | public: 39 | explicit TiffToBmpConverter(JNIEnv *, jclass, jstring, jstring, jobject, jobject); 40 | explicit TiffToBmpConverter(JNIEnv *, jclass, jint, jint, jobject, jobject); 41 | ~TiffToBmpConverter(); 42 | virtual jboolean convert(); 43 | 44 | private: 45 | static int const DECODE_METHOD_IMAGE = 1; 46 | static int const DECODE_METHOD_TILE = 2; 47 | static int const DECODE_METHOD_STRIP = 3; 48 | 49 | int getDecodeMethod(); 50 | jboolean convertFromImage(); 51 | jboolean convertFromTile(); 52 | jboolean convertFromStrip(); 53 | //jboolean convertFromImageWithBounds(); 54 | //jboolean convertFromTileWithBounds(); 55 | //jboolean convertFromStripWithBounds(); 56 | 57 | TIFF *tiffImage; 58 | short origorientation; 59 | FILE *outFIle = NULL; 60 | 61 | BITMAPFILEHEADER *bmpHeader; 62 | BITMAPINFOHEADER *bmpInfo; 63 | 64 | 65 | 66 | }; 67 | 68 | #endif //TIFFSAMPLE_TIFFTOBMPCONVERTER_H 69 | -------------------------------------------------------------------------------- /src/main/jni/TiffToJpgConverter.h: -------------------------------------------------------------------------------- 1 | // 2 | // Created by beyka on 5/10/17. 3 | // 4 | 5 | #ifndef TIFFSAMPLE_TIFFTOJPGCONVERTER_H 6 | #define TIFFSAMPLE_TIFFTOJPGCONVERTER_H 7 | 8 | #include 9 | #include 10 | #include 11 | #include "fcntl.h" 12 | #include "unistd.h" 13 | #include "jpeglib.h" 14 | #include 15 | #include "BaseTiffConverter.h" 16 | 17 | //extern "C" { 18 | //#include "jpeglib.h" 19 | //} 20 | 21 | #ifdef NDEBUG 22 | #define LOGI(x) 23 | #define LOGII(x, y) 24 | #define LOGIF(x, y) 25 | #define LOGIS(x, y) 26 | #define LOGE(x) 27 | #define LOGES(x, y) 28 | #define LOGEI(x, y) 29 | #else 30 | #define LOGI(x) __android_log_print(ANDROID_LOG_DEBUG, "TiffToJpgConverter", "%s", x) 31 | #define LOGII(x, y) __android_log_print(ANDROID_LOG_DEBUG, "TiffToJpgConverter", "%s %d", x, y) 32 | #define LOGIF(x, y) __android_log_print(ANDROID_LOG_DEBUG, "TiffToJpgConverter", "%s %f", x, y) 33 | #define LOGIS(x, y) __android_log_print(ANDROID_LOG_DEBUG, "TiffToJpgConverter", "%s %s", x, y) 34 | #define LOGE(x) __android_log_print(ANDROID_LOG_ERROR, "TiffToJpgConverter", "%s", x) 35 | #define LOGES(x, y) __android_log_print(ANDROID_LOG_ERROR, "TiffToJpgConverter", "%s %s", x, y) 36 | #define LOGEI(x, y) __android_log_print(ANDROID_LOG_ERROR, "TiffToJpgConverter", "%s %d", x, y) 37 | #endif 38 | 39 | class TiffToJpgConverter : public BaseTiffConverter 40 | { 41 | public: 42 | explicit TiffToJpgConverter(JNIEnv *, jclass, jstring, jstring, jobject, jobject); 43 | explicit TiffToJpgConverter(JNIEnv *, jclass, jint, jint, jobject, jobject); 44 | ~TiffToJpgConverter(); 45 | virtual jboolean convert(); 46 | 47 | private: 48 | static int const DECODE_METHOD_IMAGE = 1; 49 | static int const DECODE_METHOD_TILE = 2; 50 | static int const DECODE_METHOD_STRIP = 3; 51 | 52 | static int const JPEG_QUALITY = 90; 53 | 54 | int getDecodeMethod(); 55 | jboolean convertFromImage(); 56 | jboolean convertFromTile(); 57 | jboolean convertFromStrip(); 58 | 59 | TIFF *tiffImage; 60 | short origorientation; 61 | FILE *jpegFile = NULL; 62 | char jpeg_struct_init; 63 | struct jpeg_compress_struct cinfo; 64 | struct jpeg_error_mgr jerr; 65 | 66 | 67 | 68 | }; 69 | 70 | #endif //TIFFSAMPLE_TIFFTOJPGCONVERTER_H -------------------------------------------------------------------------------- /src/main/jni/TiffToPngConverter.h: -------------------------------------------------------------------------------- 1 | // 2 | // Created by beyka on 5/10/17. 3 | // 4 | 5 | #ifndef TIFFSAMPLE_TIFFTOPNGCONVERTER_H 6 | #define TIFFSAMPLE_TIFFTOPNGCONVERTER_H 7 | 8 | #include 9 | #include 10 | #include 11 | #include "fcntl.h" 12 | #include "unistd.h" 13 | #include 14 | #include 15 | #include "BaseTiffConverter.h" 16 | 17 | #ifdef NDEBUG 18 | #define LOGI(x) 19 | #define LOGII(x, y) 20 | #define LOGIF(x, y) 21 | #define LOGIS(x, y) 22 | #define LOGE(x) 23 | #define LOGES(x, y) 24 | #define LOGEI(x, y) 25 | #else 26 | #define LOGI(x) __android_log_print(ANDROID_LOG_DEBUG, "TiffToPngConverter", "%s", x) 27 | #define LOGII(x, y) __android_log_print(ANDROID_LOG_DEBUG, "TiffToPngConverter", "%s %d", x, y) 28 | #define LOGIF(x, y) __android_log_print(ANDROID_LOG_DEBUG, "TiffToPngConverter", "%s %f", x, y) 29 | #define LOGIS(x, y) __android_log_print(ANDROID_LOG_DEBUG, "TiffToPngConverter", "%s %s", x, y) 30 | #define LOGE(x) __android_log_print(ANDROID_LOG_ERROR, "TiffToPngConverter", "%s", x) 31 | #define LOGES(x, y) __android_log_print(ANDROID_LOG_ERROR, "TiffToPngConverter", "%s %s", x, y) 32 | #define LOGEI(x, y) __android_log_print(ANDROID_LOG_ERROR, "TiffToPngConverter", "%s %d", x, y) 33 | #endif 34 | 35 | class TiffToPngConverter : public BaseTiffConverter 36 | { 37 | public: 38 | explicit TiffToPngConverter(JNIEnv *, jclass, jstring, jstring, jobject, jobject); 39 | explicit TiffToPngConverter(JNIEnv *, jclass, jint, jint, jobject, jobject); 40 | ~TiffToPngConverter(); 41 | virtual jboolean convert(); 42 | 43 | private: 44 | static int const DECODE_METHOD_IMAGE = 1; 45 | static int const DECODE_METHOD_TILE = 2; 46 | static int const DECODE_METHOD_STRIP = 3; 47 | 48 | int getDecodeMethod(); 49 | jboolean convertFromImage(); 50 | jboolean convertFromTile(); 51 | jboolean convertFromStrip(); 52 | 53 | 54 | TIFF *tiffImage; 55 | short origorientation; 56 | FILE *pngFile = NULL;; 57 | char png_ptr_init; 58 | png_structp png_ptr; 59 | char png_info_init; 60 | png_infop info_ptr; 61 | 62 | }; 63 | 64 | #endif //TIFFSAMPLE_TIFFTOPNGCONVERTER_H -------------------------------------------------------------------------------- /src/main/jni/libs/arm64-v8a/libjpeg.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/arm64-v8a/libjpeg.a -------------------------------------------------------------------------------- /src/main/jni/libs/arm64-v8a/libpng.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/arm64-v8a/libpng.a -------------------------------------------------------------------------------- /src/main/jni/libs/armeabi-v7a/libjpeg.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/armeabi-v7a/libjpeg.a -------------------------------------------------------------------------------- /src/main/jni/libs/armeabi-v7a/libpng.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/armeabi-v7a/libpng.a -------------------------------------------------------------------------------- /src/main/jni/libs/armeabi/libjpeg.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/armeabi/libjpeg.a -------------------------------------------------------------------------------- /src/main/jni/libs/armeabi/libpng.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/armeabi/libpng.a -------------------------------------------------------------------------------- /src/main/jni/libs/mips/libjpeg.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/mips/libjpeg.a -------------------------------------------------------------------------------- /src/main/jni/libs/mips/libpng.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/mips/libpng.a -------------------------------------------------------------------------------- /src/main/jni/libs/mips64/libjpeg.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/mips64/libjpeg.a -------------------------------------------------------------------------------- /src/main/jni/libs/mips64/libpng.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/mips64/libpng.a -------------------------------------------------------------------------------- /src/main/jni/libs/x86/libjpeg.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/x86/libjpeg.a -------------------------------------------------------------------------------- /src/main/jni/libs/x86/libpng.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/x86/libpng.a -------------------------------------------------------------------------------- /src/main/jni/libs/x86_64/libjpeg.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/x86_64/libjpeg.a -------------------------------------------------------------------------------- /src/main/jni/libs/x86_64/libpng.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/libs/x86_64/libpng.a -------------------------------------------------------------------------------- /src/main/jni/png/config.h: -------------------------------------------------------------------------------- 1 | /* config.h. Generated from config.h.in by configure. */ 2 | /* config.h.in. Generated from configure.ac by autoheader. */ 3 | 4 | /* Define to 1 if you have the header file. */ 5 | #define HAVE_DLFCN_H 0 6 | 7 | /* Define to 1 if you have the header file. */ 8 | #define HAVE_INTTYPES_H 0 9 | 10 | /* Define to 1 if you have the `m' library (-lm). */ 11 | #define HAVE_LIBM 1 12 | 13 | /* Define to 1 if you have the `z' library (-lz). */ 14 | #define HAVE_LIBZ 1 15 | 16 | /* Define to 1 if you have the header file. */ 17 | #define HAVE_MALLOC_H 1 18 | 19 | /* Define to 1 if you have the header file. */ 20 | #define HAVE_MEMORY_H 0 21 | 22 | /* Define to 1 if you have the `memset' function. */ 23 | #define HAVE_MEMSET 1 24 | 25 | /* Define to 1 if you have the `pow' function. */ 26 | /* #undef HAVE_POW */ 27 | 28 | /* Define to 1 if you have the header file. */ 29 | #define HAVE_STDINT_H 1 30 | 31 | /* Define to 1 if you have the header file. */ 32 | #define HAVE_STDLIB_H 1 33 | 34 | /* Define to 1 if you have the header file. */ 35 | #define HAVE_STRINGS_H 1 36 | 37 | /* Define to 1 if you have the header file. */ 38 | #define HAVE_STRING_H 1 39 | 40 | /* Define to 1 if you have the header file. */ 41 | #define HAVE_SYS_STAT_H 1 42 | 43 | /* Define to 1 if you have the header file. */ 44 | #define HAVE_SYS_TYPES_H 1 45 | 46 | /* Define to 1 if you have the header file. */ 47 | #define HAVE_UNISTD_H 1 48 | 49 | /* Define to the sub-directory in which libtool stores uninstalled libraries. 50 | */ 51 | #define LT_OBJDIR ".libs/" 52 | 53 | /* Name of package */ 54 | #define PACKAGE "libpng" 55 | 56 | /* Define to the address where bug reports for this package should be sent. */ 57 | #define PACKAGE_BUGREPORT "png-mng-implement@lists.sourceforge.net" 58 | 59 | /* Define to the full name of this package. */ 60 | #define PACKAGE_NAME "libpng" 61 | 62 | /* Define to the full name and version of this package. */ 63 | #define PACKAGE_STRING "libpng 1.4.19" 64 | 65 | /* Define to the one symbol short name of this package. */ 66 | #define PACKAGE_TARNAME "libpng" 67 | 68 | /* Define to the home page for this package. */ 69 | #define PACKAGE_URL "" 70 | 71 | /* Define to the version of this package. */ 72 | #define PACKAGE_VERSION "1.4.19" 73 | 74 | /* Define to 1 if you have the ANSI C header files. */ 75 | #define STDC_HEADERS 1 76 | 77 | /* Define to 1 if your declares `struct tm'. */ 78 | /* #undef TM_IN_SYS_TIME */ 79 | 80 | /* Version number of package */ 81 | #define VERSION "1.4.19" 82 | 83 | /* Define to empty if `const' does not conform to ANSI C. */ 84 | /* #undef const */ 85 | 86 | /* Define to `unsigned int' if does not define. */ 87 | /* #undef size_t */ 88 | -------------------------------------------------------------------------------- /src/main/jni/tiff/Android.mk: -------------------------------------------------------------------------------- 1 | LOCAL_PATH:= $(call my-dir) 2 | include $(CLEAR_VARS) 3 | 4 | LOCAL_ARM_MODE := arm 5 | 6 | LOCAL_TIFF_SRC_FILES := \ 7 | libtiff/tif_dirread.c \ 8 | libtiff/tif_zip.c \ 9 | libtiff/tif_flush.c \ 10 | libtiff/tif_next.c \ 11 | libtiff/tif_ojpeg.c \ 12 | libtiff/tif_dirwrite.c \ 13 | libtiff/tif_dirinfo.c \ 14 | libtiff/tif_dir.c \ 15 | libtiff/tif_compress.c \ 16 | libtiff/tif_close.c \ 17 | libtiff/tif_tile.c \ 18 | libtiff/tif_open.c \ 19 | libtiff/tif_getimage.c \ 20 | libtiff/tif_pixarlog.c \ 21 | libtiff/tif_warning.c \ 22 | libtiff/tif_dumpmode.c \ 23 | libtiff/tif_jpeg.c \ 24 | libtiff/tif_jbig.c \ 25 | libtiff/tif_predict.c \ 26 | libtiff/mkg3states.c \ 27 | libtiff/tif_write.c \ 28 | libtiff/tif_error.c \ 29 | libtiff/tif_version.c \ 30 | libtiff/tif_print.c \ 31 | libtiff/tif_color.c \ 32 | libtiff/tif_read.c \ 33 | libtiff/tif_extension.c \ 34 | libtiff/tif_thunder.c \ 35 | libtiff/tif_lzw.c \ 36 | libtiff/tif_fax3.c \ 37 | libtiff/tif_luv.c \ 38 | libtiff/tif_codec.c \ 39 | libtiff/tif_unix.c \ 40 | libtiff/tif_packbits.c \ 41 | libtiff/tif_aux.c \ 42 | libtiff/tif_fax3sm.c \ 43 | libtiff/tif_swab.c \ 44 | libtiff/tif_strip.c 45 | 46 | LOCAL_TIFF_SRC_FILES += port/lfind.c 47 | ########################################################### 48 | 49 | LOCAL_SRC_FILES:= $(LOCAL_TIFF_SRC_FILES) 50 | LOCAL_C_INCLUDES += \ 51 | $(LOCAL_PATH)/libtiff \ 52 | external/zlib \ 53 | external/jpeg 54 | LOCAL_CFLAGS += -DAVOID_TABLES 55 | LOCAL_CFLAGS += -O3 -fstrict-aliasing -fprefetch-loop-arrays 56 | LOCAL_STATIC_LIBRARIES := \ 57 | libjpeg 58 | LOCAL_SHARED_LIBRARIES := \ 59 | libz 60 | LOCAL_MODULE:= libtiff 61 | LOCAL_PRELINK_MODULE:=false 62 | include $(BUILD_SHARED_LIBRARY) 63 | 64 | ########################################################### 65 | 66 | include $(CLEAR_VARS) 67 | LOCAL_ARM_MODE := arm 68 | LOCAL_SRC_FILES:= $(LOCAL_TIFF_SRC_FILES) 69 | LOCAL_C_INCLUDES += \ 70 | $(LOCAL_PATH)/libtiff \ 71 | external/zlib \ 72 | external/jpeg 73 | LOCAL_CFLAGS += -DAVOID_TABLES 74 | LOCAL_CFLAGS += -O3 -fstrict-aliasing -fprefetch-loop-arrays 75 | LOCAL_STATIC_LIBRARIES := \ 76 | libjpeg 77 | LOCAL_SHARED_LIBRARIES := \ 78 | libz 79 | LOCAL_MODULE:= libtiff 80 | include $(BUILD_STATIC_LIBRARY) 81 | 82 | ########################################################### 83 | 84 | include $(CLEAR_VARS) 85 | 86 | LOCAL_SRC_FILES = tools/tiffinfo.c 87 | 88 | LOCAL_C_INCLUDES += \ 89 | $(LOCAL_PATH)/libtiff 90 | 91 | LOCAL_SHARED_LIBRARIES = \ 92 | libtiff 93 | LOCAL_MODULE:= tiffinfo 94 | 95 | include $(BUILD_EXECUTABLE) 96 | -------------------------------------------------------------------------------- /src/main/jni/tiff/COPYRIGHT: -------------------------------------------------------------------------------- 1 | Copyright (c) 1988-1997 Sam Leffler 2 | Copyright (c) 1991-1997 Silicon Graphics, Inc. 3 | 4 | Permission to use, copy, modify, distribute, and sell this software and 5 | its documentation for any purpose is hereby granted without fee, provided 6 | that (i) the above copyright notices and this permission notice appear in 7 | all copies of the software and related documentation, and (ii) the names of 8 | Sam Leffler and Silicon Graphics may not be used in any advertising or 9 | publicity relating to the software without the specific, prior written 10 | permission of Sam Leffler and Silicon Graphics. 11 | 12 | THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 13 | EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 14 | WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 15 | 16 | IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 17 | ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 18 | OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 19 | WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 20 | LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 21 | OF THIS SOFTWARE. 22 | -------------------------------------------------------------------------------- /src/main/jni/tiff/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | docdir = $(LIBTIFF_DOCDIR) 27 | 28 | AUTOMAKE_OPTIONS = 1.11 dist-zip foreign 29 | ACLOCAL_AMFLAGS = -I m4 30 | 31 | docfiles = \ 32 | COPYRIGHT \ 33 | ChangeLog \ 34 | README \ 35 | README.vms \ 36 | RELEASE-DATE \ 37 | TODO \ 38 | VERSION 39 | 40 | EXTRA_DIST = \ 41 | HOWTO-RELEASE \ 42 | Makefile.vc \ 43 | SConstruct \ 44 | autogen.sh \ 45 | configure.com \ 46 | nmake.opt 47 | 48 | dist_doc_DATA = $(docfiles) 49 | 50 | SUBDIRS = port libtiff tools build contrib test man html 51 | 52 | release: 53 | (rm -f $(top_srcdir)/RELEASE-DATE && echo $(LIBTIFF_RELEASE_DATE) > $(top_srcdir)/RELEASE-DATE) 54 | (rm -f $(top_srcdir)/VERSION && echo $(LIBTIFF_VERSION) > $(top_srcdir)/VERSION) 55 | (rm -f $(top_srcdir)/libtiff/tiffvers.h && sed 's,LIBTIFF_VERSION,$(LIBTIFF_VERSION),;s,LIBTIFF_RELEASE_DATE,$(LIBTIFF_RELEASE_DATE),' $(top_srcdir)/libtiff/tiffvers.h.in > $(top_srcdir)/libtiff/tiffvers.h) 56 | 57 | -------------------------------------------------------------------------------- /src/main/jni/tiff/Makefile.vc: -------------------------------------------------------------------------------- 1 | # $Id: Makefile.vc,v 1.6 2006/10/13 10:30:21 dron Exp $ 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | # 24 | # Makefile for MS Visual C and Watcom C compilers. 25 | # Edit nmake.opt file if you want to ajust building options. 26 | # 27 | # To build: 28 | # C:\libtiff> nmake /f makefile.vc 29 | 30 | !INCLUDE nmake.opt 31 | 32 | all: port lib tools 33 | 34 | port:: 35 | cd port 36 | $(MAKE) /f Makefile.vc 37 | cd.. 38 | 39 | lib: port 40 | cd libtiff 41 | $(MAKE) /f Makefile.vc 42 | cd.. 43 | 44 | tools: lib 45 | cd tools 46 | $(MAKE) /f Makefile.vc 47 | cd .. 48 | 49 | clean: 50 | -del *.exe.manifest 51 | cd port 52 | $(MAKE) /f Makefile.vc clean 53 | cd.. 54 | cd libtiff 55 | $(MAKE) /f Makefile.vc clean 56 | cd.. 57 | cd tools 58 | $(MAKE) /f Makefile.vc clean 59 | cd .. 60 | 61 | -del *.ilk 62 | -del *.dll.manifest 63 | -del *.exe.manifest 64 | -del *.exp 65 | -del *.pdb 66 | -------------------------------------------------------------------------------- /src/main/jni/tiff/README: -------------------------------------------------------------------------------- 1 | $Header: /cvs/maptools/cvsroot/libtiff/README,v 1.5 2004/10/30 13:44:45 dron Exp $ 2 | 3 | 4 | TIFF Software Distribution 5 | -------------------------- 6 | This file is just a placeholder; all the documentation is now in 7 | HTML in the html directory. To view the documentation point your 8 | favorite WWW viewer at html/index.html; e.g. 9 | 10 | netscape html/index.html 11 | 12 | If you don't have an HTML viewer then you can read the HTML source 13 | or fetch a PostScript version of this documentation from the directory 14 | 15 | ftp://ftp.remotesensing.org/pub/libtiff/ 16 | 17 | If you can't hack either of these options then basically what you 18 | want to do is: 19 | 20 | % ./configure 21 | % make 22 | % su 23 | # make install 24 | 25 | More information, email contacts, and mailing list information can be 26 | found online at http://www.remotesensing.org/libtiff/. 27 | 28 | 29 | Use and Copyright 30 | ----------------- 31 | Silicon Graphics has seen fit to allow us to give this work away. It 32 | is free. There is no support or guarantee of any sort as to its 33 | operations, correctness, or whatever. If you do anything useful with 34 | all or parts of it you need to honor the copyright notices. I would 35 | also be interested in knowing about it and, hopefully, be acknowledged. 36 | 37 | The legal way of saying that is: 38 | 39 | Copyright (c) 1988-1997 Sam Leffler 40 | Copyright (c) 1991-1997 Silicon Graphics, Inc. 41 | 42 | Permission to use, copy, modify, distribute, and sell this software and 43 | its documentation for any purpose is hereby granted without fee, provided 44 | that (i) the above copyright notices and this permission notice appear in 45 | all copies of the software and related documentation, and (ii) the names of 46 | Sam Leffler and Silicon Graphics may not be used in any advertising or 47 | publicity relating to the software without the specific, prior written 48 | permission of Sam Leffler and Silicon Graphics. 49 | 50 | THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 51 | EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 52 | WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 53 | 54 | IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 55 | ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 56 | OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 57 | WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 58 | LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 59 | OF THIS SOFTWARE. 60 | -------------------------------------------------------------------------------- /src/main/jni/tiff/README.android: -------------------------------------------------------------------------------- 1 | 2 | Added or modified file list: 3 | Android.mk 4 | README.android 5 | libtiff/tif_config.h 6 | libtiff/tiffconf.h 7 | 8 | Deleted file list: 9 | (None) 10 | 11 | Author: 12 | figofuture@gmail.com 13 | 14 | -------------------------------------------------------------------------------- /src/main/jni/tiff/README.vms: -------------------------------------------------------------------------------- 1 | Dear OpenVMS user 2 | to make this library, execute 3 | $@CONFIGURE 4 | $@BUILD 5 | 6 | Build process should be error and warning free. When process will be finished, 7 | LIBTIFF$STRATUP.COM file containing all required definitions, will be created. 8 | Please call it from system startup procedure or individual user procedure LOGIN.COM 9 | To link software with libtiff, use TIFF:LIBTIFF.OPT 10 | 11 | best regards, 12 | Alexey Chupahin, elvis_75@mail.ru 13 | -------------------------------------------------------------------------------- /src/main/jni/tiff/RELEASE-DATE: -------------------------------------------------------------------------------- 1 | 20091104 2 | -------------------------------------------------------------------------------- /src/main/jni/tiff/TODO: -------------------------------------------------------------------------------- 1 | # $Header: /cvs/maptools/cvsroot/libtiff/TODO,v 1.6 2002/10/10 05:28:43 warmerda Exp $ 2 | 3 | o gif2tiff segaulting on selected images 4 | o tiffcmp read data by strip/tile instead of scanline 5 | o YCbCr sampling support 6 | o extracate colorspace conversion support 7 | o look at isolating all codecs from TIFF library 8 | o JPEG colormode order dependency problem 9 | o Write documentation on how do extend tags, and how the custom field 10 | stuff all works. 11 | 12 | 13 | -------------------------------------------------------------------------------- /src/main/jni/tiff/VERSION: -------------------------------------------------------------------------------- 1 | 3.9.2 2 | -------------------------------------------------------------------------------- /src/main/jni/tiff/autogen.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -x 3 | #libtoolize --force --copy 4 | aclocal -I ./m4 5 | autoheader 6 | automake --foreign --add-missing --copy 7 | autoconf 8 | 9 | -------------------------------------------------------------------------------- /src/main/jni/tiff/build/Makefile.am: -------------------------------------------------------------------------------- 1 | # $Id: Makefile.am,v 1.1 2007/02/24 15:03:49 dron Exp $ 2 | # 3 | # Tag Image File Format (TIFF) Software 4 | # 5 | # Copyright (C) 2007, Andrey Kiselev 6 | # 7 | # Permission to use, copy, modify, distribute, and sell this software and 8 | # its documentation for any purpose is hereby granted without fee, provided 9 | # that (i) the above copyright notices and this permission notice appear in 10 | # all copies of the software and related documentation, and (ii) the names of 11 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | # publicity relating to the software without the specific, prior written 13 | # permission of Sam Leffler and Silicon Graphics. 14 | # 15 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | # 19 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | # OF THIS SOFTWARE. 25 | 26 | # Process this file with automake to produce Makefile.in. 27 | 28 | EXTRA_DIST = README 29 | 30 | SUBDIRS = 31 | 32 | -------------------------------------------------------------------------------- /src/main/jni/tiff/build/README: -------------------------------------------------------------------------------- 1 | This directory contains scripts and tools needed to build libtiff library 2 | and its utilities in various environments. 3 | 4 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README 27 | 28 | SUBDIRS = acorn addtiffo dbs iptcutil mac-cw mac-mpw mfs pds ras stream tags win_dib 29 | 30 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/README: -------------------------------------------------------------------------------- 1 | This directory contains various contributions from libtiff users. 2 | 3 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/acorn/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = Makefile.acorn ReadMe SetVars cleanlib convert install 27 | 28 | INCLUDES = -I../../libtiff -I$(top_srcdir)/libtiff 29 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/acorn/SetVars: -------------------------------------------------------------------------------- 1 | Set LibTIFF$Dir 2 | Set LibTIFF$Path . 3 | Set C$Path ,LibTIFF: 4 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/acorn/cleanlib: -------------------------------------------------------------------------------- 1 | IfThere LibTIFF:o.* THEN Wipe LibTIFF:o.* ~CFR~V 2 | IfThere LibTIFF:c.tif_fax3sm THEN Delete LibTIFF:c.tif_fax3sm 3 | IfThere LibTIFF:mkg3states THEN Delete LibTIFF:mkg3states 4 | IfThere LibTIFF:h.version THEN Delete LibTIFF:h.version 5 | IfThere LibTIFF:mkversion THEN Delete LibTIFF:mkversion 6 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/addtiffo/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | LIBTIFF = $(top_builddir)/libtiff/libtiff.la 27 | 28 | EXTRA_DIST = README Makefile.vc 29 | 30 | noinst_PROGRAMS = addtiffo 31 | 32 | addtiffo_SOURCES = addtiffo.c tif_overview.c tif_ovrcache.c tif_ovrcache.h 33 | addtiffo_LDADD = $(LIBTIFF) 34 | 35 | INCLUDES = -I../../libtiff -I$(top_srcdir)/libtiff 36 | 37 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/addtiffo/Makefile.vc: -------------------------------------------------------------------------------- 1 | # 2 | # If libtiff.a is installed in /usr/lib or /usr/local/lib just point 3 | # LIBTIFF_DIR there. It doesn't need a full libtiff tree. 4 | # 5 | !INCLUDE ..\..\nmake.opt 6 | 7 | LIBTIFF_DIR = ..\..\libtiff 8 | # 9 | INCL = -I..\..\libtiff 10 | LIBS = $(LIBTIFF_DIR)\libtiff.lib 11 | 12 | addtiffo: addtiffo.obj tif_overview.obj tif_ovrcache.obj 13 | $(CC) $(CFLAGS) addtiffo.obj tif_overview.obj tif_ovrcache.obj \ 14 | $(LIBS) /Feaddtiffo.exe 15 | 16 | 17 | addtiffo.obj: addtiffo.c 18 | $(CC) -c $(CFLAGS) addtiffo.c 19 | 20 | tif_overview.obj: tif_overview.c 21 | $(CC) -c $(CFLAGS) tif_overview.c 22 | 23 | tif_ovrcache.obj: tif_ovrcache.c 24 | $(CC) -c $(CFLAGS) tif_ovrcache.c 25 | 26 | clean: 27 | -del *.obj 28 | -del addtiffo.exe 29 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/dbs/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | SUBDIRS = xtiff 27 | 28 | LIBTIFF = $(top_builddir)/libtiff/libtiff.la 29 | 30 | EXTRA_DIST = README 31 | 32 | noinst_PROGRAMS = tiff-bi tiff-grayscale tiff-palette tiff-rgb 33 | 34 | tiff_bi_SOURCES = tiff-bi.c 35 | tiff_bi_LDADD = $(LIBTIFF) 36 | tiff_grayscale_SOURCES = tiff-grayscale.c 37 | tiff_grayscale_LDADD = $(LIBTIFF) 38 | tiff_palette_SOURCES = tiff-palette.c 39 | tiff_palette_LDADD = $(LIBTIFF) 40 | tiff_rgb_SOURCES = tiff-rgb.c 41 | tiff_rgb_LDADD = $(LIBTIFF) 42 | 43 | INCLUDES = -I../../libtiff -I$(top_srcdir)/libtiff 44 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/dbs/README: -------------------------------------------------------------------------------- 1 | Wed May 9 09:11:35 PDT 1990 2 | 3 | This directory contains programs from Dan Sears 4 | (dbs@decwrl.dec.com). Contact him directly if 5 | you have questions/problems. 6 | 7 | Sam 8 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/dbs/xtiff/Makefile.am: -------------------------------------------------------------------------------- 1 | # $Id: Makefile.am,v 1.4 2007/02/24 15:03:49 dron Exp $ 2 | # 3 | # Tag Image File Format (TIFF) Software 4 | # 5 | # Copyright (C) 2004, Andrey Kiselev 6 | # 7 | # Permission to use, copy, modify, distribute, and sell this software and 8 | # its documentation for any purpose is hereby granted without fee, provided 9 | # that (i) the above copyright notices and this permission notice appear in 10 | # all copies of the software and related documentation, and (ii) the names of 11 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | # publicity relating to the software without the specific, prior written 13 | # permission of Sam Leffler and Silicon Graphics. 14 | # 15 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | # 19 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | # OF THIS SOFTWARE. 25 | 26 | # Process this file with automake to produce Makefile.in. 27 | 28 | #LIBTIFF = $(top_builddir)/libtiff/libtiff.la 29 | 30 | EXTRA_DIST = README patchlevel.h xtiff.c xtifficon.h 31 | 32 | #noinst_PROGRAMS = 33 | 34 | #if HAVE_XAW 35 | #noinst_PROGRAMS += xtiff 36 | #endif 37 | 38 | #xtiff_SOURCES = patchlevel.h xtiff.c xtifficon.h 39 | #xtiff_CFLAGS = $(CFLAGS) $(XAW_CFLAGS) $(AM_CFLAGS) 40 | #xtiff_LDADD = $(LIBTIFF) $(X_LIBS) $(XAW_LIBS) 41 | 42 | #INCLUDES = -I$(top_srcdir)/libtiff 43 | 44 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/dbs/xtiff/README: -------------------------------------------------------------------------------- 1 | xtiff 2.0 2 | 3 | xtiff is a tool for viewing a TIFF file in an X window. It was written to 4 | handle as many different kinds of TIFF files as possible while remaining 5 | simple, portable and efficient. xtiff requires X11 R4, the Athena Widgets 6 | and Sam Leffler's libtiff package (which can be found on ucbvax.berkeley.edu). 7 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/dbs/xtiff/patchlevel.h: -------------------------------------------------------------------------------- 1 | #define PATCHLEVEL 0 2 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/dbs/xtiff/xtifficon.h: -------------------------------------------------------------------------------- 1 | #define xtifficon_width 32 2 | #define xtifficon_height 32 3 | static char xtifficon_bits[] = { 4 | 0xff, 0x00, 0x00, 0xc0, 0xfe, 0x01, 0x7e, 0xc0, 0xfc, 0x03, 0x7e, 0x60, 5 | 0xf8, 0x07, 0x06, 0x30, 0xf8, 0x07, 0x1e, 0x18, 0xf0, 0x0f, 0x1e, 0x0c, 6 | 0xe0, 0x1f, 0x06, 0x06, 0xc0, 0x3f, 0x06, 0x06, 0xc0, 0x3f, 0x06, 0x03, 7 | 0x80, 0x7f, 0x80, 0x01, 0x00, 0xff, 0xc0, 0x00, 0x00, 0xfe, 0x61, 0x00, 8 | 0x00, 0xfe, 0x31, 0x7e, 0x7e, 0xfc, 0x33, 0x7e, 0x7e, 0xf8, 0x1b, 0x06, 9 | 0x18, 0xf0, 0x0d, 0x1e, 0x18, 0xf0, 0x0e, 0x1e, 0x18, 0x60, 0x1f, 0x06, 10 | 0x18, 0xb0, 0x3f, 0x06, 0x18, 0x98, 0x7f, 0x06, 0x18, 0x98, 0x7f, 0x00, 11 | 0x00, 0x0c, 0xff, 0x00, 0x00, 0x06, 0xfe, 0x01, 0x00, 0x63, 0xfc, 0x03, 12 | 0x80, 0x61, 0xfc, 0x03, 0xc0, 0x60, 0xf8, 0x07, 0xc0, 0x60, 0xf0, 0x0f, 13 | 0x60, 0x60, 0xe0, 0x1f, 0x30, 0x60, 0xe0, 0x1f, 0x18, 0x60, 0xc0, 0x3f, 14 | 0x0c, 0x60, 0x80, 0x7f, 0x06, 0x00, 0x00, 0xff}; 15 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/iptcutil/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | LIBTIFF = $(top_builddir)/libtiff/libtiff.la 27 | 28 | EXTRA_DIST = README test.iptc test.txt 29 | 30 | noinst_PROGRAMS = iptcutil 31 | 32 | iptcutil_SOURCES = iptcutil.c 33 | iptcutil_LDADD = $(LIBTIFF) 34 | 35 | INCLUDES = -I$(top_srcdir)/libtiff 36 | 37 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/iptcutil/README: -------------------------------------------------------------------------------- 1 | 2 | Program: IPTCUTIL.C 3 | 4 | Purpose: Convert between IPTC binary and a "special" IPTC text file format. 5 | 6 | Usage: iptcutil -t | -b [-i file] [-o file] output 7 | 8 | Notes: You tell the program the "type" of input file via the -t and -b 9 | switches. The -t says that the input is text, while the -b says 10 | that the input is binary IPTC. You can use either the -i or the 11 | -o switches to tell the program what the input and output files 12 | will be, or use simple piping. 13 | 14 | Author: William T. Radcliffe (billr@corbis.com) 15 | Parts of this program were derived from other places. The original 16 | binary to text conversion was taken from the PHP distribution and 17 | the tokenizer was written many years ago, by someone else as well. 18 | 19 | This software is provided freely "as is", without warranty of any kind, 20 | express or implied, including but not limited to the warranties of 21 | merchantability, fitness for a particular purpose and noninfringement. 22 | In no event shall William T. Radcliffe be liable for any claim, damages or 23 | other liability, whether in an action of contract, tort or otherwise, 24 | arising from, out of or in connection with IPTCUTIL 25 | 26 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/iptcutil/test.iptc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/contrib/iptcutil/test.iptc -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/iptcutil/test.txt: -------------------------------------------------------------------------------- 1 | 2#0="�" 2 | 2#120#Caption="Chairman of the US House Judiciary Committee, Henry Hyde,R-IL, makes his opening statement during impeachment hearings 11 December on Capitol Hill in Washington, DC. The committee is debating the articles of impechment and my take a vote on the impeachment of US President BIll Clinton on charges that he obstucted justice, lied and abused the power of his office as early as today. AFP PHOTO Paul J. RICHARDS " 3 | 2#122#Caption Writer="kb/lt" 4 | 2#100#Country Code="USA" 5 | 2#105#Headline="Old fart squeezing two fingers." 6 | 2#30#Release Date="19981211" 7 | 2#35#Release Time="000000+0000" 8 | 2#40#Special Instructions="This is a test. This is only a test. ABCDEFGHIJKLMNOPQRSTUVWXYZ 1234567890" 9 | 2#80#Byline="PAUL J. RICHARDS" 10 | 2#85#Byline Title="STF" 11 | 2#110#Credit="AFP" 12 | 2#65#Originating Program="MacDesk Reporter" 13 | 2#115#Source="AFP" 14 | 2#5#Image Name="US-HYDE" 15 | 2#55#Created Date="19981211" 16 | 2#90#City="WASHINGTON" 17 | 2#95#Province State="DC" 18 | 2#101#Country="UNITED STATES" 19 | 2#103#Original Transmission Reference="DCA03" 20 | 2#15#Category="POL" 21 | 2#20#Supplemental Category="GOVERNMENT" 22 | 2#10#Priority="5" 23 | 2#25#Keyword="fart" 24 | 2#25#Keyword="squeezing" 25 | 2#25#Keyword="old" 26 | 2#25#Keyword="fingers" 27 | 2#75#Object Cycle="a" 28 | 2#60#Created Time="000000+0000" 29 | 2#70#Program Version="2.0.3" 30 | 2#130="3S" 31 | 2#135="GB" 32 | 2#231="Kaya A. Hoffmann 12/14/98 12:00:44 PM Copy To : Selects - \\KINYANI\Selects������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������" 33 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mac-cw/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = Makefile.script README mac_main.c mac_main.h metrowerks.note mkg3_main.c version.h 27 | 28 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mac-cw/README: -------------------------------------------------------------------------------- 1 | ---------------------------------------------------- 2 | Build instructions for LIBTIFF - CodeWarrior (6.1): 3 | ---------------------------------------------------- 4 | 5 | In this directory you will find a Makefile.script Applescript 6 | file, which should be run in order to build the libtiff code 7 | using MetroWerks CodeWarrior. 8 | 9 | Refer to the "metrowerks.note" instructions on building the 10 | library for 68k and PowerPC native code, as well as building 11 | some of the libtiff tools, which are rather unix-like, but 12 | at least give an example of how to link everything together. 13 | 14 | Questions, comments, bug reports to Niles Ritter 15 | (ndr@tazboy.jpl.nasa.gov). Sam Leffler takes no responsibility 16 | for the viability of this stuff. 17 | 18 | -Niles. 19 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mac-cw/mac_main.c: -------------------------------------------------------------------------------- 1 | /* 2 | * mac_main.c -- The REAL entry point which 3 | * calls the tools main code. For the tools 4 | * the symbol "main" has been #defined to "tool_main" 5 | * so that this entry point may be used to access 6 | * the user-input first. 7 | */ 8 | 9 | #undef main 10 | 11 | int 12 | main() 13 | { 14 | int argc; 15 | char **argv; 16 | 17 | argc=ccommand(&argv); 18 | 19 | return tool_main(argc,argv); // Call the tool "main()" routine 20 | } 21 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mac-cw/mac_main.h: -------------------------------------------------------------------------------- 1 | /* 2 | * mac_main.h -- redefines main entry point 3 | */ 4 | 5 | #ifndef _mac_main_h 6 | #define _mac_main_h 7 | 8 | #undef main 9 | #define main tool_main 10 | 11 | #endif /* _mac_main_h */ 12 | 13 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mac-cw/mkg3_main.c: -------------------------------------------------------------------------------- 1 | /* 2 | * mkg3_main.c -- passes fake arguments into main 3 | */ 4 | 5 | #undef main 6 | 7 | int 8 | main() 9 | { 10 | static char *argv[4] = { 11 | "mkg3states", "-c", "const", "tif_fax3sm.c" }; 12 | 13 | return tool_main(4,argv); // Call the tool "main()" routine 14 | } 15 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mac-cw/version.h: -------------------------------------------------------------------------------- 1 | #define VERSION \ 2 | "LIBTIFF, Version 3.4beta028 \n"\ 3 | "Copyright (c) 1988-1995 Sam Leffler\n"\ 4 | "Copyright (c) 1991-1996 Silicon Graphics, Inc." 5 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mac-mpw/BUILD.mpw: -------------------------------------------------------------------------------- 1 | # BUILD.mpw: 2 | # 3 | # Full build for Apple Macintosh Programmer's Workshop (MPW). 4 | # 5 | # This is an executable MPW script which creates various 6 | # utilities, sets up the MPW makefiles and runs the builds. 7 | # This script should be run at the top level TIFF directory with: 8 | # 9 | # directory ::: 10 | # :contrib:mac-mpw:BUILD.mpw 11 | # 12 | # NOTE: The full build requires that MPW have at least 6 MB 13 | # allocated to it to compile the CCITT Fax codec tables. To 14 | # deactivate CCITT compression edit the file :contrib:mac:libtiff.make 15 | # first and follow the directions for disabling Fax decoding. 16 | # 17 | # All TIFF tools are built as MPW tools, executable from the 18 | # MPW shell or other compatible tool server. 19 | # 20 | # Written by: Niles Ritter (ndr@tazboy.jpl.nasa.gov). 21 | # 22 | 23 | echo "############# Full Scratch Build for MPW #############" 24 | 25 | # Create the ascii->mpw translation tool; this is used to 26 | # convert standard ASCII files into ones using the special 27 | # MPW characters, which don't live comfortably in unix tar files. 28 | # 29 | echo "######## Creating ASCII->MPW translator ########" 30 | set contrib ':contrib:mac-mpw:' 31 | directory {contrib} 32 | createmake -tool mactrans mactrans.c > dev:null 33 | make -f mactrans.make | streamedit -e "/CSANELib/||/Math/||/ToolLibs/ del" > mactrans.bld 34 | execute mactrans.bld > dev:null 35 | delete -y mactrans.make mactrans.bld mactrans.c.o || set status 0 36 | directory ::: #An mpw trick for going up two levels 37 | 38 | # Create the top-level Makefile and run it 39 | echo "######## Creating Makefile ########" 40 | catenate {contrib}top.make | {contrib}mactrans > Makefile 41 | 42 | echo "######## Running Makefile ########" 43 | make > build.mpw 44 | execute build.mpw 45 | echo "############# MPW Build Complete #############" 46 | exit 0 47 | 48 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mac-mpw/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = BUILD.mpw README libtiff.make mactrans.c port.make tools.make top.make 27 | 28 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mac-mpw/README: -------------------------------------------------------------------------------- 1 | ###################### 2 | About contrib:mac-mpw: 3 | ###################### 4 | 5 | This directory contains all of the utilities and makefile source 6 | to build the LIBTIFF library and tools from the MPW Shell. The 7 | file BUILD.mpw in this directory is an executable script 8 | which uses all of these files to create the MPW makefiles and 9 | run them. 10 | 11 | The .make files are not MPW makefiles as such, 12 | but are when run through the "mactrans" program, which turns 13 | the ascii "%nn" metacharacters into the standard weird MPW 14 | make characters. 15 | 16 | This translation trick is necessary to protect the files when 17 | they are put into unix tarfiles, which tend to mangle the 18 | special characters. 19 | 20 | --Niles Ritter (ndr@tazboy.jpl.nasa.gov) 21 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mac-mpw/mactrans.c: -------------------------------------------------------------------------------- 1 | /* 2 | * mactrans.c -- Hack filter used to generate MPW files 3 | * with special characters from pure ASCII, denoted "%nn" 4 | * where nn is hex. (except for "%%", which is literal '%'). 5 | * 6 | * calling sequence: 7 | * 8 | * catenate file | mactrans [-toascii | -fromascii] > output 9 | * 10 | * Written by: Niles Ritter. 11 | */ 12 | #include 13 | #include 14 | #include 15 | 16 | void to_ascii(void); 17 | void from_ascii(void); 18 | 19 | main(int argc, char *argv[]) 20 | { 21 | if (argc<2 || argv[1][1]=='f') from_ascii(); 22 | else to_ascii(); 23 | exit (0); 24 | } 25 | 26 | void from_ascii(void) 27 | { 28 | char c; 29 | int d; 30 | while ((c=getchar())!=EOF) 31 | { 32 | if (c!='%' || (c=getchar())=='%') putchar(c); 33 | else 34 | { 35 | ungetc(c,stdin); 36 | scanf("%2x",&d); 37 | *((unsigned char *)&c) = d; 38 | putchar(c); 39 | } 40 | } 41 | } 42 | 43 | void to_ascii(void) 44 | { 45 | char c; 46 | int d; 47 | while ((c=getchar())!=EOF) 48 | { 49 | if (isascii(c)) putchar (c); 50 | else 51 | { 52 | d = *((unsigned char *)&c); 53 | printf("%%%2x",d); 54 | } 55 | } 56 | } 57 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mac-mpw/port.make: -------------------------------------------------------------------------------- 1 | # 2 | # Tag Image File Format Library 3 | # 4 | # Copyright (c) 1995 Sam Leffler 5 | # Copyright (c) 1995 Silicon Graphics, Inc. 6 | # 7 | # Permission to use, copy, modify, distribute, and sell this software and 8 | # its documentation for any purpose is hereby granted without fee, provided 9 | # that (i) the above copyright notices and this permission notice appear in 10 | # all copies of the software and related documentation, and (ii) the names of 11 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | # publicity relating to the software without the specific, prior written 13 | # permission of Sam Leffler and Silicon Graphics. 14 | # 15 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | # 19 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | # OF THIS SOFTWARE. 25 | # 26 | DEPTH= :: 27 | SRCDIR= : 28 | 29 | NULL = 30 | CC = C 31 | AR = Lib 32 | AROPTS = 33 | RM= delete -y 34 | 35 | IPATH = -I {DEPTH} -I {SRCDIR} 36 | COPTS = 37 | OPTIMIZER= 38 | CFLAGS = {COPTS} {OPTIMIZER} {IPATH} 39 | 40 | CFILES = 41 | OBJECTS = getopt.c.o 42 | TARGETS = libport.o 43 | 44 | .c.o %c4 .c 45 | {CC} -model far {COptions} {CFLAGS} -s {Default} {DepDir}{Default}.c -o {TargDir}{Default}.c.o 46 | 47 | all %c4 {TARGETS} 48 | 49 | libport.o %c4 {OBJECTS} 50 | {AR} {OBJECTS} -o libport.o 51 | 52 | clean %c4 53 | {RM} {TARGETS} {OBJECTS} || set status 0 54 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mfs/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README mfs_file.c 27 | 28 | INCLUDES = -I../../libtiff -I$(top_srcdir)/libtiff -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/mfs/README: -------------------------------------------------------------------------------- 1 | Date: Mon, 23 Jun 1997 13:30:48 +0200 2 | To: 3 | 4 | From: "Mike Johnson" 5 | Subject: libtiff - Thanks 6 | 7 | Return-Path: mikehunt@swipnet.se 8 | Delivery-Date: Mon, 23 Jun 1997 06:53:39 -0700 9 | 10 | Hi Sam, 11 | 12 | I noticed in the README from libtiff that you would like to know about 13 | what people have done with libtiff, so I thought I would drop you a 14 | line. 15 | 16 | We have used libtiff to create and convert TIFF images of financial 17 | documents which are sent from and to major document processing systems 18 | in Sweden and Denmark. 19 | 20 | I would like to express my deep gratitude to yourself and Sillicon 21 | Graphics for making this excellent library available for public use. 22 | There is obviously a lot of work that has gone in to libtiff and the 23 | quality of the code and documentation is an example to others. 24 | 25 | One thing that libtiff did not do was work on a memory area rather than 26 | files. In my applications I had already read a TIFF or other format 27 | file in to memory and did not want to waste I/O writing it out again 28 | for libtiff's benefit. I therefore constructed a set of functions to 29 | pass up to TIFFClientOpen to simulate a file in memory. I have attached 30 | my mfs (memory file system) source code for you to use or junk, as you 31 | see fit. :-) 32 | 33 | Once again, thanks very much for making my life simpler. 34 | 35 | Best Regards, 36 | 37 | Mike Johnson. 38 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/pds/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README tif_imageiter.c tif_imageiter.h tif_pdsdirread.c tif_pdsdirwrite.c 27 | 28 | INCLUDES = -I../../libtiff -I$(top_srcdir)/libtiff 29 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/pds/tif_imageiter.h: -------------------------------------------------------------------------------- 1 | typedef struct _TIFFImageIter TIFFImageIter; 2 | 3 | /* The callback function is called for each "block" of image pixel data after 4 | it has been read from the file and decoded. This image pixel data is in the 5 | buffer pp, and this data represents the image pixels from (x,y) to 6 | (x+w,y+h). It is stored in pixel format, so each pixel contains 7 | img->samplesperpixel consecutive samples each containing img->bitspersample 8 | bits of data. The array pp is ordered in h consecutive rows of w+fromskew 9 | pixels each. */ 10 | typedef void (*ImageIterTileContigRoutine) 11 | (TIFFImageIter*, void *, uint32, uint32, uint32, uint32, int32, 12 | unsigned char*); 13 | #define DECLAREContigCallbackFunc(name) \ 14 | static void name(\ 15 | TIFFImageIter* img, \ 16 | void* user_data, \ 17 | uint32 x, uint32 y, \ 18 | uint32 w, uint32 h, \ 19 | int32 fromskew, \ 20 | u_char* pp \ 21 | ) 22 | 23 | typedef void (*ImageIterTileSeparateRoutine) 24 | (TIFFImageIter*, void *, uint32, uint32, uint32, uint32, int32, 25 | unsigned char*, unsigned char*, unsigned char*, unsigned char*); 26 | #define DECLARESepCallbackFunc(name) \ 27 | static void name(\ 28 | TIFFImageIter* img, \ 29 | void* user_data, \ 30 | uint32 x, uint32 y, \ 31 | uint32 w, uint32 h,\ 32 | int32 fromskew, \ 33 | u_char* r, u_char* g, u_char* b, u_char* a\ 34 | ) 35 | 36 | struct _TIFFImageIter { 37 | TIFF* tif; /* image handle */ 38 | int stoponerr; /* stop on read error */ 39 | int isContig; /* data is packed/separate */ 40 | int alpha; /* type of alpha data present */ 41 | uint32 width; /* image width */ 42 | uint32 height; /* image height */ 43 | uint16 bitspersample; /* image bits/sample */ 44 | uint16 samplesperpixel; /* image samples/pixel */ 45 | uint16 orientation; /* image orientation */ 46 | uint16 photometric; /* image photometric interp */ 47 | uint16* redcmap; /* colormap pallete */ 48 | uint16* greencmap; 49 | uint16* bluecmap; 50 | /* get image data routine */ 51 | int (*get)(TIFFImageIter*, void *udata, uint32, uint32); 52 | union { 53 | void (*any)(TIFFImageIter*); 54 | ImageIterTileContigRoutine contig; 55 | ImageIterTileSeparateRoutine separate; 56 | } callback; /* fn to exec for each block */ 57 | }; 58 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/ras/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README ras2tif.c tif2ras.c 27 | 28 | INCLUDES = -I../../libtiff -I$(top_srcdir)/libtiff 29 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/ras/README: -------------------------------------------------------------------------------- 1 | Sun May 19 22:28:16 PDT 1991 2 | 3 | These programs are from Patrick Naughton (naughton@wind.sun.com). 4 | I've tried to update them to reflect changes to the library, but 5 | I am unable to verify that they operate properly, because they 6 | require the Sun pixrect library. 7 | 8 | Please contact Patrick directly if you have questions/problems. 9 | 10 | Sam 11 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/stream/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README tiffstream.cpp tiffstream.h 27 | 28 | INCLUDES = -I../../libtiff -I$(top_srcdir)/libtiff 29 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/stream/README: -------------------------------------------------------------------------------- 1 | Subject: tiff stream interface (contrib) 2 | Date: Thu, 30 Mar 2000 10:48:51 -0800 3 | From: "Avi Bleiweiss" 4 | To: , 5 | 6 | Here at Shutterfly we have augmented the file based tiff library to support 7 | C++ streams. The implementation is an adaptor class, which takes any C++ 8 | stream from the user and in return it deposits i/o operation method pointers 9 | (e.g. read, write, seek and close) into the tiff's library client state. 10 | 11 | The class TiffStream has an overloaded factory method - makeFileStream - 12 | which takes the C++ stream as an argument, calls TIFFClientOpen and returns 13 | a tiff handle. The class retains the tiff handle in its local state and 14 | provides a helper function (getTiffHandle) to query the handle at any time. 15 | Additional helper method - getStreamSize - provides the stream size to the 16 | user. The implementation assumes client responsibility to delete the stream 17 | object. The class calls TIFFClose at destruction time. 18 | 19 | Attached are a definition (tiffstream.h) and an implementation 20 | (tiffstream.cpp) files of the TiffStream class. No changes are required to 21 | the tiff core piece and the class sits on top of the library. The code is 22 | fairly tested at this point and is used internally in Shutterfly imaging 23 | software. The code is portable across WindowsNT/Linux/Solaris. 24 | 25 | We at Shutterfly believe this software has benefits to the larger community 26 | of tiff library users and would like to contribute this software to be part 27 | of the tiff distributed package. Let me know of any issue. 28 | 29 | Thanks 30 | Avi 31 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/stream/tiffstream.h: -------------------------------------------------------------------------------- 1 | // tiff stream interface class definition 2 | 3 | #ifndef _TIFF_STREAM_H_ 4 | #define _TIFF_STREAM_H_ 5 | 6 | #include 7 | 8 | #include "tiffio.h" 9 | 10 | class TiffStream { 11 | 12 | public: 13 | // ctor/dtor 14 | TiffStream(); 15 | ~TiffStream(); 16 | 17 | public: 18 | enum SeekDir { 19 | beg, 20 | cur, 21 | end, 22 | }; 23 | 24 | public: 25 | // factory methods 26 | TIFF* makeFileStream(iostream* str); 27 | TIFF* makeFileStream(istream* str); 28 | TIFF* makeFileStream(ostream* str); 29 | 30 | public: 31 | // tiff client methods 32 | static tsize_t read(thandle_t fd, tdata_t buf, tsize_t size); 33 | static tsize_t write(thandle_t fd, tdata_t buf, tsize_t size); 34 | static toff_t seek(thandle_t fd, toff_t offset, int origin); 35 | static toff_t size(thandle_t fd); 36 | static int close(thandle_t fd); 37 | static int map(thandle_t fd, tdata_t* phase, toff_t* psize); 38 | static void unmap(thandle_t fd, tdata_t base, tsize_t size); 39 | 40 | public: 41 | // query method 42 | TIFF* getTiffHandle() const { return m_tif; } 43 | unsigned int getStreamLength() { return m_streamLength; } 44 | 45 | private: 46 | // internal methods 47 | unsigned int getSize(thandle_t fd); 48 | unsigned int tell(thandle_t fd); 49 | bool seekInt(thandle_t fd, unsigned int offset, int origin); 50 | bool isOpen(thandle_t fd); 51 | 52 | private: 53 | thandle_t m_this; 54 | TIFF* m_tif; 55 | static const char* m_name; 56 | istream* m_inStream; 57 | ostream* m_outStream; 58 | iostream* m_ioStream; 59 | int m_streamLength; 60 | 61 | }; 62 | 63 | #endif // _TIFF_STREAM_H_ -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/tags/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README listtif.c maketif.c xtif_dir.c xtiffio.h xtiffiop.h 27 | 28 | INCLUDES = -I../../libtiff -I$(top_srcdir)/libtiff 29 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/tags/listtif.c: -------------------------------------------------------------------------------- 1 | /* 2 | * listtif.c -- lists a tiff file. 3 | */ 4 | 5 | #include "xtiffio.h" 6 | #include 7 | 8 | void main(int argc,char *argv[]) 9 | { 10 | char *fname="newtif.tif"; 11 | int flags; 12 | 13 | TIFF *tif=(TIFF*)0; /* TIFF-level descriptor */ 14 | 15 | if (argc>1) fname=argv[1]; 16 | 17 | tif=XTIFFOpen(fname,"r"); 18 | if (!tif) goto failure; 19 | 20 | /* We want the double array listed */ 21 | flags = TIFFPRINT_MYMULTIDOUBLES; 22 | 23 | TIFFPrintDirectory(tif,stdout,flags); 24 | XTIFFClose(tif); 25 | exit (0); 26 | 27 | failure: 28 | printf("failure in listtif\n"); 29 | if (tif) XTIFFClose(tif); 30 | exit (-1); 31 | } 32 | 33 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/tags/maketif.c: -------------------------------------------------------------------------------- 1 | /* 2 | * maketif.c -- creates a little TIFF file, with 3 | * the XTIFF extended tiff example tags. 4 | */ 5 | 6 | #include 7 | #include "xtiffio.h" 8 | 9 | 10 | void SetUpTIFFDirectory(TIFF *tif); 11 | void WriteImage(TIFF *tif); 12 | 13 | #define WIDTH 20 14 | #define HEIGHT 20 15 | 16 | void main() 17 | { 18 | TIFF *tif=(TIFF*)0; /* TIFF-level descriptor */ 19 | 20 | tif=XTIFFOpen("newtif.tif","w"); 21 | if (!tif) goto failure; 22 | 23 | SetUpTIFFDirectory(tif); 24 | WriteImage(tif); 25 | 26 | XTIFFClose(tif); 27 | exit (0); 28 | 29 | failure: 30 | printf("failure in maketif\n"); 31 | if (tif) XTIFFClose(tif); 32 | exit (-1); 33 | } 34 | 35 | 36 | void SetUpTIFFDirectory(TIFF *tif) 37 | { 38 | double mymulti[6]={0.0,1.0,2.0, 3.1415926, 5.0,1.0}; 39 | uint32 mysingle=3456; 40 | char *ascii="This file was produced by Steven Spielberg. NOT"; 41 | 42 | TIFFSetField(tif,TIFFTAG_IMAGEWIDTH,WIDTH); 43 | TIFFSetField(tif,TIFFTAG_IMAGELENGTH,HEIGHT); 44 | TIFFSetField(tif,TIFFTAG_COMPRESSION,COMPRESSION_NONE); 45 | TIFFSetField(tif,TIFFTAG_PHOTOMETRIC,PHOTOMETRIC_MINISBLACK); 46 | TIFFSetField(tif,TIFFTAG_PLANARCONFIG,PLANARCONFIG_CONTIG); 47 | TIFFSetField(tif,TIFFTAG_BITSPERSAMPLE,8); 48 | TIFFSetField(tif,TIFFTAG_ROWSPERSTRIP,20); 49 | 50 | /* Install the extended TIFF tag examples */ 51 | TIFFSetField(tif,TIFFTAG_EXAMPLE_MULTI,6,mymulti); 52 | TIFFSetField(tif,TIFFTAG_EXAMPLE_SINGLE,mysingle); 53 | TIFFSetField(tif,TIFFTAG_EXAMPLE_ASCII,ascii); 54 | } 55 | 56 | 57 | void WriteImage(TIFF *tif) 58 | { 59 | int i; 60 | char buffer[WIDTH]; 61 | 62 | memset(buffer,0,sizeof(buffer)); 63 | for (i=0;itif_clientdata, "WriteImage","failure in WriteScanline\n"); 66 | } 67 | 68 | 69 | 70 | 71 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/tags/xtiffio.h: -------------------------------------------------------------------------------- 1 | /* 2 | * xtiffio.h -- Public interface to Extended TIFF tags 3 | * 4 | * This is a template for defining a client module 5 | * which supports tag extensions to the standard libtiff 6 | * set. Only portions of the code marked "XXX" need to 7 | * be changed to support your tag set. 8 | * 9 | * written by: Niles D. Ritter 10 | */ 11 | 12 | #ifndef __xtiffio_h 13 | #define __xtiffio_h 14 | 15 | #include "tiffio.h" 16 | 17 | /* 18 | * XXX Define your private Tag names and values here 19 | */ 20 | 21 | /* These tags are not valid, but are provided for example */ 22 | #define TIFFTAG_EXAMPLE_MULTI 61234 23 | #define TIFFTAG_EXAMPLE_SINGLE 61235 24 | #define TIFFTAG_EXAMPLE_ASCII 61236 25 | 26 | /* 27 | * XXX Define Printing method flags. These 28 | * flags may be passed in to TIFFPrintDirectory() to 29 | * indicate that those particular field values should 30 | * be printed out in full, rather than just an indicator 31 | * of whether they are present or not. 32 | */ 33 | #define TIFFPRINT_MYMULTIDOUBLES 0x80000000 34 | 35 | /********************************************************************** 36 | * Nothing below this line should need to be changed by the user. 37 | **********************************************************************/ 38 | 39 | #if defined(__cplusplus) 40 | extern "C" { 41 | #endif 42 | 43 | extern TIFF* XTIFFOpen(const char* name, const char* mode); 44 | extern TIFF* XTIFFFdOpen(int fd, const char* name, const char* mode); 45 | extern void XTIFFClose(TIFF *tif); 46 | 47 | #if defined(__cplusplus) 48 | } 49 | #endif 50 | 51 | #endif /* __xtiffio_h */ 52 | 53 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/tags/xtiffiop.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Private Extended TIFF library interface. 3 | * 4 | * uses private LIBTIFF interface. 5 | * 6 | * The portions of this module marked "XXX" should be 7 | * modified to support your tags instead. 8 | * 9 | * written by: Niles D. Ritter 10 | * 11 | */ 12 | 13 | #ifndef __xtiffiop_h 14 | #define __xtiffiop_h 15 | 16 | #include "tiffiop.h" 17 | #include "xtiffio.h" 18 | 19 | /********************************************************************** 20 | * User Configuration 21 | **********************************************************************/ 22 | 23 | /* XXX - Define number of your extended tags here */ 24 | #define NUM_XFIELD 3 25 | #define XFIELD_BASE (FIELD_LAST-NUM_XFIELD) 26 | 27 | /* XXX - Define your Tag Fields here */ 28 | #define FIELD_EXAMPLE_MULTI (XFIELD_BASE+0) 29 | #define FIELD_EXAMPLE_SINGLE (XFIELD_BASE+1) 30 | #define FIELD_EXAMPLE_ASCII (XFIELD_BASE+2) 31 | 32 | 33 | /* XXX - Define Private directory tag structure here */ 34 | struct XTIFFDirectory { 35 | uint16 xd_num_multi; /* dir-count for the multi tag */ 36 | double* xd_example_multi; 37 | uint32 xd_example_single; 38 | char* xd_example_ascii; 39 | }; 40 | typedef struct XTIFFDirectory XTIFFDirectory; 41 | 42 | /********************************************************************** 43 | * Nothing below this line should need to be changed by the user. 44 | **********************************************************************/ 45 | 46 | struct xtiff { 47 | TIFF *xtif_tif; /* parent TIFF pointer */ 48 | uint32 xtif_flags; 49 | #define XTIFFP_PRINT 0x00000001 50 | XTIFFDirectory xtif_dir; /* internal rep of current directory */ 51 | TIFFVSetMethod xtif_vsetfield; /* inherited tag set routine */ 52 | TIFFVGetMethod xtif_vgetfield; /* inherited tag get routine */ 53 | TIFFPrintMethod xtif_printdir; /* inherited dir print method */ 54 | }; 55 | typedef struct xtiff xtiff; 56 | 57 | 58 | #define PARENT(xt,pmember) ((xt)->xtif_ ## pmember) 59 | #define TIFFMEMBER(tf,pmember) ((tf)->tif_ ## pmember) 60 | #define XTIFFDIR(tif) ((xtiff *)TIFFMEMBER(tif,clientdir)) 61 | 62 | /* Extended TIFF flags */ 63 | #define XTIFF_INITIALIZED 0x80000000 64 | 65 | #endif /* __xtiffiop_h */ 66 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/win_dib/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = Makefile.w95 README.Tiffile README.tiff2dib Tiffile.cpp tiff2dib.c 27 | 28 | INCLUDES = -I../../libtiff -I$(top_srcdir)/libtiff -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/win_dib/README.Tiffile: -------------------------------------------------------------------------------- 1 | Frank, 2 | 3 | I attached a file that uses RGBA interface (tif_getimage.c) to read a tiff 4 | file and convert to a DIB. It's advantage is that it is easy to read *any* 5 | tiff file suported by libtiff and easily convert it to a DIB. The disadvantage 6 | is that bilevel (B&W) bitmaps (and all other non-rgba images) are also 7 | converted to RGBA, thus taking up 32x as much memory as needed (4 bytes per 8 | pixel, rather than 1 bit). I read tiff files, but don't need to 9 | write them. And my files are typically small, so the overhead is mostly 10 | inconsequential. But for bilevel images, I overrode the get() and put() 11 | routines of the RGBA interface to just copy the data from the input raster 12 | to the output raster, rather than expanding out to full 32 bit format. It 13 | would be nice if there were a simple way to handle all palletized images, 14 | but that would take more custom routines, and it's not that important to me. 15 | 16 | Usage: 17 | 18 | m_pDIB = (PBITMAPINFOHEADER)::ReadTIFF(pathName); 19 | if (m_pDIB != 0) { 20 | m_format = IMAGETYPE_TIF; 21 | } 22 | 23 | This is intended as Win32, but the modifications for new get() and put() 24 | routines may be independent of platform. 25 | 26 | Thanks for your work supporting the forum and the library! 27 | 28 | Regards, 29 | 30 | Mark James 31 | mark@james.net 32 | -------------------------------------------------------------------------------- /src/main/jni/tiff/contrib/win_dib/README.tiff2dib: -------------------------------------------------------------------------------- 1 | 2 | Date: 04 Dec 95 10:34:23 EST 3 | From: Philippe <100423.3705@compuserve.com> 4 | To: TIFF/sam Leffler 5 | Subject: TIFF library and Windows 95 6 | Message-Id: <951204153422_100423.3705_BHG101-1@CompuServe.COM> 7 | 8 | Sam, 9 | 10 | First, let me thanks all of you how have worked 11 | on that great TIFF library ! 12 | 13 | Here is some information that may help someone. 14 | 15 | I build the library under Windows 95 as a 32-bit library. 16 | The contribution of Scott Wagner (tif_win32.c) worked fine, but 17 | the makefile "makefile.msc" was unsable because it was 18 | written for DOS or Windows 3.1 and all the files names 19 | are limited to 8 characters. 20 | 21 | Here is the makefile I used : makefile.w95 22 | 23 | Also, I had to disable fax3 support because I wasn't able 24 | to build (as it is) the tool "mkg3states" to generate the include 25 | file "g3states.h". 26 | This source file must be modify to be build under Windows 95. 27 | 28 | To build the library under Windows 95 with Visual C++ 2.0, 29 | I had to : 30 | 31 | - undefine CCITT_SUPPORT in "tiffconf.h" 32 | 33 | - create the file version.h with this line : 34 | #define VERSION "3.4beta024" 35 | 36 | - build the makefile "makefile.w95" 37 | 38 | I also join the source file "tif2dib.c" that I created, 39 | it contain the function LoadTIFFinDIB that load 40 | a TIFF file and build a memory DIB with it and return the 41 | HANDLE (HDIB) of the memory bloc containing this DIB. 42 | Since DIB is the "natural" bitmap format for Windows 3.1, 95 and NT, 43 | this function sould be usefull for some Windows 95 (or NT) developer. 44 | 45 | 46 | Sorry for my approximate english ... 47 | 48 | Regards, 49 | 50 | Philippe Tenenhaus 100423.3705@compuserve.com 51 | Paris 52 | -------------------------------------------------------------------------------- /src/main/jni/tiff/html/Makefile.am: -------------------------------------------------------------------------------- 1 | # $Id: Makefile.am,v 1.16.2.1 2007/07/13 13:40:12 dron Exp $ 2 | # 3 | # Tag Image File Format (TIFF) Software 4 | # 5 | # Copyright (C) 2004, Andrey Kiselev 6 | # 7 | # Permission to use, copy, modify, distribute, and sell this software and 8 | # its documentation for any purpose is hereby granted without fee, provided 9 | # that (i) the above copyright notices and this permission notice appear in 10 | # all copies of the software and related documentation, and (ii) the names of 11 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | # publicity relating to the software without the specific, prior written 13 | # permission of Sam Leffler and Silicon Graphics. 14 | # 15 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | # 19 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | # OF THIS SOFTWARE. 25 | 26 | # Process this file with automake to produce Makefile.in. 27 | 28 | docdir = $(LIBTIFF_DOCDIR)/html 29 | 30 | docfiles = \ 31 | addingtags.html \ 32 | bugs.html \ 33 | build.html \ 34 | contrib.html \ 35 | document.html \ 36 | images.html \ 37 | index.html \ 38 | internals.html \ 39 | intro.html \ 40 | libtiff.html \ 41 | misc.html \ 42 | support.html \ 43 | TIFFTechNote2.html \ 44 | tools.html \ 45 | v3.4beta007.html \ 46 | v3.4beta016.html \ 47 | v3.4beta018.html \ 48 | v3.4beta024.html \ 49 | v3.4beta028.html \ 50 | v3.4beta029.html \ 51 | v3.4beta031.html \ 52 | v3.4beta032.html \ 53 | v3.4beta033.html \ 54 | v3.4beta034.html \ 55 | v3.4beta035.html \ 56 | v3.4beta036.html \ 57 | v3.5.1.html \ 58 | v3.5.2.html \ 59 | v3.5.3.html \ 60 | v3.5.4.html \ 61 | v3.5.5.html \ 62 | v3.5.6-beta.html \ 63 | v3.5.7.html \ 64 | v3.6.0.html \ 65 | v3.6.1.html \ 66 | v3.7.0alpha.html \ 67 | v3.7.0beta.html \ 68 | v3.7.0beta2.html \ 69 | v3.7.0.html \ 70 | v3.7.1.html \ 71 | v3.7.2.html \ 72 | v3.7.3.html \ 73 | v3.7.4.html \ 74 | v3.8.0.html \ 75 | v3.8.1.html \ 76 | v3.8.2.html \ 77 | v3.9.0beta.html \ 78 | v3.9.1.html \ 79 | v3.9.2.html 80 | 81 | dist_doc_DATA = $(docfiles) 82 | 83 | SUBDIRS = images man 84 | 85 | -------------------------------------------------------------------------------- /src/main/jni/tiff/html/bugs.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | Bugs and the TIFF Mailing List 4 | 5 | 6 | 7 |

8 | 9 | Bugs, Bugzilla, and the TIFF Mailing List 10 |

11 | 12 |

13 | This software is free. Please let us know when you find a problem or 14 | fix a bug. 15 | 16 |

17 | Thanks to MapTools.org, libtiff now uses 18 | bugzilla to track bugs. All bugs filed in the older bugzilla at 19 | bugzilla.remotesensing.org (pre April 2008) have unfortunately been lost. 20 |

21 | If you think you've discovered a bug, please first check to see if it is 22 | already known by looking at the list of already reported bugs. You can do so 23 | by visiting the buglist at 24 | http://bugzilla.maptools.org/buglist.cgi?product=libtiff. Also verify that 25 | the problem is still reproducable with the current development software 26 | from CVS. 27 |

28 | If you'd like to enter a new bug, you can do so at 29 | http://bugzilla.maptools.org/enter_bug.cgi?product=libtiff. 30 |

31 | If you'd like to inform us about some kind of security issue that should not 32 | be disclosed for a period of time, then you can contact maintainers directly. 33 | Send a copies of your report to the following people: Frank Warmerdam 34 | <warmerdam@pobox.com>, 35 | Andrey Kiselev 36 | <dron@ak4719.spb.edu>. 37 |

38 | 39 | Of course, reporting bugs is no substitute for discussion. The 40 | tiff@lists.maptools.org mailing 41 | list is for users of this software, and discussion TIFF issues in general. 42 | It is managed with the Mailman software, and the web interface for subscribing 43 | and managing your access to the list is at:

44 | 45 | http://lists.maptools.org/mailman/listinfo/tiff

46 | 47 | Posts to the list are only accepted from members of the list in order 48 | to limit the amount of spam propagated. Also, to be approved as a member 49 | you will need to email the list administrator with a brief description of 50 | why you are interested in TIFF so we can weed out spammers.

51 | 52 | A Long Term 53 | Archive including recent messages, and most messages back to 1993, 54 | with search capabilities is available, and 55 | has been prepared and hosted by AWare 56 | Systems.

57 | 58 | 59 |


60 | 61 | Last updated: $Date: 2008/09/03 08:04:26 $ 62 | 63 | 64 | -------------------------------------------------------------------------------- /src/main/jni/tiff/html/document.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | TIFF Documentation 5 | 6 | 7 | 8 | 9 |

10 | 11 | TIFF Documentation 12 |

13 | 14 |

15 | A copy of the 6.0 specification is available from Adobe at 16 | http://partners.adobe.com/public/developer/en/tiff/TIFF6.pdf, or from the libtiff 17 | ftp site at 18 | ftp://ftp.remotesensing.org/pub/libtiff/doc/TIFF6.pdf.

19 | 20 |

21 | Draft TIFF Technical Note #2 covers problems 22 | with the TIFF 6.0 design for embedding JPEG-compressed data in TIFF, and 23 | describes an alternative.

24 | 25 | Other Adobe information on TIFF can be retrieved from: 26 | 27 | 28 | http://partners.adobe.com/public/developer/tiff/index.html 29 | 30 |

31 | Joris Van Damme maintains a list of known tags and their descriptions and 32 | definitions. It is available online at 33 | 34 | http://www.awaresystems.be/imaging/tiff/tifftags.html 35 | 36 |

37 | There is a FAQ, related both to TIFF format and libtiff library: 38 | 39 | http://www.awaresystems.be/imaging/tiff/faq.html 40 | 41 |


42 | 43 |
44 | Last updated: $Date: 2009-08-20 22:31:00 $ 45 |
46 | 47 | 48 | 49 | -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | TIFF Test Images 5 | 6 | 7 | 8 | 9 |

10 | 11 | TIFF Test Images 12 |

13 | 14 |

15 | Test images are available for most formats supported by the library. 16 | Most of the images included in the test kit are also part of this 17 | documentation (albeit in TIFF rather than GIF or JFIF). 18 | The images are kept in a separate archive that should be located in 19 | the same directory as this software. 20 | 21 |
22 | 23 |

24 | The latest archive of test images is located at 25 | 26 | ftp://ftp.remotesensing.org/pub/libtiff/pics-3.8.0.tar.gz 27 | 28 |

29 | There are two other good sources for TIFF test images: 30 | the contributed software contrib/dbs includes several 31 | programs that generate test images suitable for debugging, and 32 | the tiffcp program can be used to generate a variety 33 | of images with different storage characteristics. 34 | 35 |

36 |


37 | 38 | Last updated: $Date: 2006/01/02 23:50:44 $ 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | docdir = $(LIBTIFF_DOCDIR)/html/images 27 | 28 | docfiles = \ 29 | back.gif \ 30 | bali.jpg \ 31 | cat.gif \ 32 | cover.jpg \ 33 | cramps.gif \ 34 | dave.gif \ 35 | info.gif \ 36 | jello.jpg \ 37 | jim.gif \ 38 | note.gif \ 39 | oxford.gif \ 40 | quad.jpg \ 41 | ring.gif \ 42 | smallliz.jpg \ 43 | strike.gif \ 44 | warning.gif 45 | 46 | dist_doc_DATA = $(docfiles) 47 | -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/back.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/back.gif -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/bali.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/bali.jpg -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/cat.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/cat.gif -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/cover.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/cover.jpg -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/cramps.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/cramps.gif -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/dave.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/dave.gif -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/info.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/info.gif -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/jello.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/jello.jpg -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/jim.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/jim.gif -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/note.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/note.gif -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/oxford.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/oxford.gif -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/quad.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/quad.jpg -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/ring.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/ring.gif -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/smallliz.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/smallliz.jpg -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/strike.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/strike.gif -------------------------------------------------------------------------------- /src/main/jni/tiff/html/images/warning.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Beyka/Android-TiffBitmapFactory/aca0b69befb13a72dae848e110b2bd1cc9007516/src/main/jni/tiff/html/images/warning.gif -------------------------------------------------------------------------------- /src/main/jni/tiff/html/intro.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Introduction to the TIFF Documentation 5 | 6 | 7 | 8 | 9 |

10 | 11 | Introduction to the TIFF Documentation 12 |

13 | 14 | 15 |

16 | The following definitions are used throughout this documentation. 17 | They are consistent with the terminology used in the TIFF 6.0 specification. 18 | 19 |

20 |
Sample 21 |
The unit of information stored in an image; often called a 22 | channel elsewhere. Sample values are numbers, usually unsigned 23 | integers, but possibly in some other format if the SampleFormat 24 | tag is specified in a TIFF 25 |
Pixel 26 |
A collection of one or more samples that go together. 27 |
Row 28 |
An Nx1 rectangular collection of pixels. 29 |
Tile 30 |
An NxM rectangular organization of data (or pixels). 31 |
Strip 32 |
A tile whose width is the full image width. 33 |
Compression 34 |
A scheme by which pixel or sample data are stored in 35 | an encoded form, specifically with the intent of reducing the 36 | storage cost. 37 |
Codec 38 |
Software that implements the decoding and encoding algorithms 39 | of a compression scheme. 40 | 41 | 42 |

43 | In order to better understand how TIFF works (and consequently this 44 | software) it is important to recognize the distinction between the 45 | physical organization of image data as it is stored in a TIFF and how 46 | the data is interpreted and manipulated as pixels in an image. TIFF 47 | supports a wide variety of storage and data compression schemes that 48 | can be used to optimize retrieval time and/or minimize storage space. 49 | These on-disk formats are independent of the image characteristics; it 50 | is the responsibility of the TIFF reader to process the on-disk storage 51 | into an in-memory format suitable for an application. Furthermore, it 52 | is the responsibility of the application to properly interpret the 53 | visual characteristics of the image data. TIFF defines a framework for 54 | specifying the on-disk storage format and image characteristics with 55 | few restrictions. This permits significant complexity that can be 56 | daunting. Good applications that handle TIFF work by handling as wide 57 | a range of storage formats as possible, while constraining the 58 | acceptable image characteristics to those that make sense for the 59 | application. 60 | 61 | 62 |

63 |


64 | 65 | Last updated: $Date: 1999/08/09 20:21:21 $ 66 | 67 | 68 | 69 | -------------------------------------------------------------------------------- /src/main/jni/tiff/html/man/TIFFClose.3tiff.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | TIFFClose 8 | 9 | 10 | 11 |

TIFFClose

12 | NAME
13 | SYNOPSIS
14 | DESCRIPTION
15 | DIAGNOSTICS
16 | SEE ALSO
17 | 18 |
19 | 20 |

NAME

21 | 22 | 24 | 25 | 26 | 30 |
27 |

TIFFClose − close a previously opened 28 | TIFF file

29 |
31 | 32 |

SYNOPSIS

33 | 34 | 36 | 37 | 38 | 43 |
39 |

#include <tiffio.h>

40 | 41 |

void TIFFClose(TIFF *tif)

42 |
44 | 45 |

DESCRIPTION

46 | 47 | 49 | 50 | 51 | 57 |
52 |

TIFFClose closes a file that was previously opened 53 | with TIFFOpen(3TIFF). Any buffered data are flushed 54 | to the file, including the contents of the current directory 55 | (if modified); and all resources are reclaimed.

56 |
58 | 59 |

DIAGNOSTICS

60 | 61 | 63 | 64 | 65 | 70 |
66 |

All error messages are directed to the routine. Likewise, 67 | warning messages are directed to the 68 | TIFFWarning(3TIFF) routine.

69 |
71 | 72 |

SEE ALSO

73 | 74 | 76 | 77 | 78 | 84 |
79 |

libtiff(3TIFF), TIFFOpen(3TIFF)

80 | 81 |

Libtiff library home page: 82 | http://www.remotesensing.org/libtiff/

83 |
85 |
86 | 87 | 88 | -------------------------------------------------------------------------------- /src/main/jni/tiff/html/v3.4beta033.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.4beta033 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | TIFF CHANGE INFORMATION 13 | 14 | 15 | 22 | 23 |

24 | This document describes the changes made to the software between the 25 | previous and current versions (see above). 26 | If you don't find something listed here, then it was not done in this 27 | timeframe, or it was not considered important enough to be mentioned. 28 | The following information is located here: 29 |

35 | 36 |


37 | 38 | CHANGES IN THE SOFTWARE CONFIGURATION: 39 | 40 |
    41 |
  • support was added for building the library as a DSO under OSF/1 42 |
43 | 44 |


45 | 46 | CHANGES IN LIBTIFF: 47 | 48 |
    49 |
  • fixes to the Pixar codec 50 |
  • portability mods for VMS 51 |
52 | 53 |


54 | 55 | CHANGES IN THE TOOLS: 56 | 57 |
    58 |
  • fixes to gif2tiff and ppm2tiff for building under MS/DOS 59 |
  • portability mods to fax2ps and ycbcr for VMS 60 |
61 | 62 |


63 | 64 | CHANGES IN THE CONTRIBUTED SOFTWARE: 65 | 66 |
    67 |
  • a new package from Alexander Lehmann 68 | for building the library and tools under MS/DOS with DJGPP v2 69 |
  • updated VMS support from Karsten Spang 70 |
71 | 72 | TIFF home page.
73 | 74 |
75 | 76 |
77 | Sam Leffler / sam@engr.sgi.com 78 | Last updated $Date: 1999/08/09 20:21:21 $. 79 |
80 | 81 | 82 | 83 | -------------------------------------------------------------------------------- /src/main/jni/tiff/html/v3.4beta034.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.4beta034 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | TIFF CHANGE INFORMATION 13 | 14 | 15 | 22 | 23 |

24 | This document describes the changes made to the software between the 25 | previous and current versions (see above). 26 | If you don't find something listed here, then it was not done in this 27 | timeframe, or it was not considered important enough to be mentioned. 28 | The following information is located here: 29 |

33 | 34 |


35 | 36 | CHANGES IN THE SOFTWARE CONFIGURATION: 37 | 38 |
    39 |
  • support was added for building the library as a DSO under NetBSD 40 |
  • a bug was fixed in the DSO support for Linux 41 |
  • the handling of version strings has changed slightly to simplify parsing 42 |
  • a new parameter, TIFFLIBREF, was added to control how the 43 | library is referenced when linking programs in the tools directory 44 |
45 | 46 |


47 | 48 | CHANGES IN LIBTIFF: 49 | 50 |
    51 |
  • DSO creation under Solaris now forces the DSO name with a -h option 52 |
  • the interface to the mkversion program was changed 53 | to eliminate the need to parse files 54 |
  • a bug was fixed in the EOL-detection logic of the T.4/T.6 decoder 55 |
  • ANSI IT8 TIFF/IT tag definitions were added to tiff.h 56 |
57 | 58 | TIFF home page.
59 | 60 |
61 | 62 |
63 | Sam Leffler / sam@engr.sgi.com 64 | Last updated $Date: 1999/08/09 20:21:21 $. 65 |
66 | 67 | 68 | 69 | -------------------------------------------------------------------------------- /src/main/jni/tiff/html/v3.4beta035.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.4beta035 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | TIFF CHANGE INFORMATION 13 | 14 | 15 | 22 | 23 |

24 | This document describes the changes made to the software between the 25 | previous and current versions (see above). 26 | If you don't find something listed here, then it was not done in this 27 | timeframe, or it was not considered important enough to be mentioned. 28 | The following information is located here: 29 |

33 | 34 |


35 | 36 | CHANGES IN THE SOFTWARE CONFIGURATION: 37 | 38 |
    39 |
  • support was added installing the HTML documentation 40 |
  • support was added for building the library as a DSO under FreeBSD 41 |
42 | 43 |


44 | 45 | CHANGES IN LIBTIFF: 46 | 47 |
    48 |
  • the interface to the mkversion program was restored to 49 | the form used prior to v3.4beta034 50 |
  • several portability problems for 16-bit systems were fixed 51 |
52 | 53 | TIFF home page.
54 | 55 |
56 | 57 |
58 | Sam Leffler / sam@engr.sgi.com 59 | Last updated $Date: 1999/08/09 20:21:21 $. 60 |
61 | 62 | 63 | 64 | -------------------------------------------------------------------------------- /src/main/jni/tiff/html/v3.5.1.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.5.1 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | TIFF CHANGE INFORMATION 14 | 15 | 16 | 36 | 37 |


38 | 39 | CHANGES IN THE SOFTWARE CONFIGURATION: 40 | 41 |
    42 |
  • None of consequence 43 |
44 | 45 |


46 | 47 | CHANGES IN LIBTIFF: 48 | 49 | 50 |
    51 |
  • Support was added for IPTC Newsphoto metadata (TIFFTAGE_IPTCNEWSPHOTO) 52 |
  • Support was added for photoshop caption handling (TIFFTAG_PHOTOSHOP) 53 |
54 | 55 |


56 | 57 | CHANGES IN THE TOOLS: 58 | 59 |
    60 |
  • Bill Radcliffe's iptcutil was 61 | added to the "contrib" subdirectory . It can convert an IPTC binary 62 | blob to ASCII text and vice-versa. The blob itself can be extracted 63 | from or added to an image with the ImageMagick convert(1) 65 | utility. 66 |
67 | 68 | TIFF home page.
69 | 70 |
71 | 72 | Last updated $Date: 2006/01/03 01:42:30 $. 73 | 74 | 75 | 76 | -------------------------------------------------------------------------------- /src/main/jni/tiff/html/v3.5.4.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.5.4 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | TIFF CHANGE INFORMATION 14 | 15 | 16 | 24 | 25 |

26 | This document describes the changes made to the software between the 27 | previous and current versions (see above). 28 | If you don't find something listed here, then it was not done in this 29 | timeframe, or it was not considered important enough to be mentioned. 30 | The following information is located here: 31 |

36 |

37 |


38 | 39 | CHANGES IN THE SOFTWARE CONFIGURATION: 40 | 41 |
    42 |
  • None 43 | 44 | 45 |
46 | 47 |


48 | 49 | CHANGES IN LIBTIFF: 50 | 51 | 52 |
    53 | 54 |
  • Added Pixar tag support. Contributed by Phil Beffery 55 | 56 |
  • Made one more change to tif_dir.c for removal of LZW compression. Also added notice 57 | when LZW compression invoked. 58 | 59 |
  • Fixed bug that caused LZW (non) compression to segfault. Added 60 | warning about LZW compression removed being removed, and why. 61 | 62 |
63 | 64 |


65 | 66 | CHANGES IN THE TOOLS: 67 | 68 |
    69 |
  • Changed default compression in tools to TIFF_PACKBITS, and changed usage descriptions 70 | in tools to reflect removal of LZW compression 71 | 72 |
  • Added nostrip to install in tools/Makefile.in so that debugging 73 | symbols are kept. 74 | 75 |
  • Made Packbits the default compression in tools/tiff2rgba.c instead 76 | of LZW. 77 | 78 | 79 |
80 | 81 | TIFF home page.
82 | 83 |
84 | 85 | Last updated $Date: 2006/01/03 01:45:41 $. 86 | 87 | 88 | 89 | -------------------------------------------------------------------------------- /src/main/jni/tiff/libtiff/SConstruct: -------------------------------------------------------------------------------- 1 | # $Id: SConstruct,v 1.4 2007/02/24 15:03:50 dron Exp $ 2 | 3 | # Tag Image File Format (TIFF) Software 4 | # 5 | # Copyright (C) 2005, Andrey Kiselev 6 | # 7 | # Permission to use, copy, modify, distribute, and sell this software and 8 | # its documentation for any purpose is hereby granted without fee, provided 9 | # that (i) the above copyright notices and this permission notice appear in 10 | # all copies of the software and related documentation, and (ii) the names of 11 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | # publicity relating to the software without the specific, prior written 13 | # permission of Sam Leffler and Silicon Graphics. 14 | # 15 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | # 19 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | # OF THIS SOFTWARE. 25 | 26 | # This file contains rules to build software with the SCons tool 27 | # (see the http://www.scons.org/ for details on SCons). 28 | 29 | # Import globally defined options 30 | Import([ 'env', 'idir_lib' ]) 31 | 32 | SRCS = [ \ 33 | 'tif_aux.c', \ 34 | 'tif_close.c', \ 35 | 'tif_codec.c', \ 36 | 'tif_color.c', \ 37 | 'tif_compress.c', \ 38 | 'tif_dir.c', \ 39 | 'tif_dirinfo.c', \ 40 | 'tif_dirread.c', \ 41 | 'tif_dirwrite.c', \ 42 | 'tif_dumpmode.c', \ 43 | 'tif_error.c', \ 44 | 'tif_extension.c', \ 45 | 'tif_fax3.c', \ 46 | 'tif_fax3sm.c', \ 47 | 'tif_flush.c', \ 48 | 'tif_getimage.c', \ 49 | 'tif_jbig.c', \ 50 | 'tif_jpeg.c', \ 51 | 'tif_luv.c', \ 52 | 'tif_lzw.c', \ 53 | 'tif_next.c', \ 54 | 'tif_ojpeg.c', \ 55 | 'tif_open.c', \ 56 | 'tif_packbits.c', \ 57 | 'tif_pixarlog.c', \ 58 | 'tif_predict.c', \ 59 | 'tif_print.c', \ 60 | 'tif_read.c', \ 61 | 'tif_strip.c', \ 62 | 'tif_swab.c', \ 63 | 'tif_thunder.c', \ 64 | 'tif_tile.c', \ 65 | 'tif_unix.c', \ 66 | 'tif_version.c', \ 67 | 'tif_warning.c', \ 68 | 'tif_write.c', \ 69 | 'tif_zip.c' ] 70 | 71 | StaticLibrary('tiff', SRCS) 72 | SharedLibrary('tiff', SRCS) 73 | 74 | -------------------------------------------------------------------------------- /src/main/jni/tiff/libtiff/tif_config.h-vms: -------------------------------------------------------------------------------- 1 | /* Define to 1 if you have the header file. */ 2 | #define HAVE_ASSERT_H 1 3 | 4 | /* Define to 1 if you have the header file. */ 5 | #define HAVE_FCNTL_H 1 6 | 7 | /* Define as 0 or 1 according to the floating point format suported by the 8 | machine */ 9 | #define HAVE_IEEEFP 1 10 | 11 | #define HAVE_UNISTD_H 1 12 | 13 | #define HAVE_STRING_H 1 14 | /* Define to 1 if you have the header file. */ 15 | #define HAVE_SYS_TYPES_H 1 16 | 17 | /* Define to 1 if you have the header file. */ 18 | //#define HAVE_IO_H 1 19 | 20 | /* Define to 1 if you have the header file. */ 21 | //#define HAVE_SEARCH_H 1 22 | 23 | /* The size of a `int', as computed by sizeof. */ 24 | #define SIZEOF_INT 4 25 | 26 | /* The size of a `long', as computed by sizeof. */ 27 | #define SIZEOF_LONG 4 28 | 29 | /* Set the native cpu bit order */ 30 | #define HOST_FILLORDER FILLORDER_LSB2MSB 31 | 32 | /* Define to 1 if your processor stores words with the most significant byte 33 | first (like Motorola and SPARC, unlike Intel and VAX). */ 34 | /* #undef WORDS_BIGENDIAN */ 35 | 36 | /* Define to `__inline__' or `__inline' if that's what the C compiler 37 | calls it, or to nothing if 'inline' is not supported under any name. */ 38 | /* 39 | #ifndef __cplusplus 40 | # ifndef inline 41 | # define inline __inline 42 | # endif 43 | #endif 44 | */ 45 | 46 | // #define lfind _lfind 47 | -------------------------------------------------------------------------------- /src/main/jni/tiff/libtiff/tif_config.vc.h: -------------------------------------------------------------------------------- 1 | /* Define to 1 if you have the header file. */ 2 | #define HAVE_ASSERT_H 1 3 | 4 | /* Define to 1 if you have the header file. */ 5 | #define HAVE_FCNTL_H 1 6 | 7 | /* Define as 0 or 1 according to the floating point format suported by the 8 | machine */ 9 | #define HAVE_IEEEFP 1 10 | 11 | /* Define to 1 if you have the `jbg_newlen' function. */ 12 | #define HAVE_JBG_NEWLEN 1 13 | 14 | /* Define to 1 if you have the header file. */ 15 | #define HAVE_STRING_H 1 16 | 17 | /* Define to 1 if you have the header file. */ 18 | #define HAVE_SYS_TYPES_H 1 19 | 20 | /* Define to 1 if you have the header file. */ 21 | #define HAVE_IO_H 1 22 | 23 | /* Define to 1 if you have the header file. */ 24 | #define HAVE_SEARCH_H 1 25 | 26 | /* Define to 1 if you have the `setmode' function. */ 27 | #define HAVE_SETMODE 1 28 | 29 | /* The size of a `int', as computed by sizeof. */ 30 | #define SIZEOF_INT 4 31 | 32 | /* The size of a `long', as computed by sizeof. */ 33 | #define SIZEOF_LONG 4 34 | 35 | /* Signed 64-bit type */ 36 | #define TIFF_INT64_T signed __int64 37 | 38 | /* Unsigned 64-bit type */ 39 | #define TIFF_UINT64_T unsigned __int64 40 | 41 | /* Set the native cpu bit order */ 42 | #define HOST_FILLORDER FILLORDER_LSB2MSB 43 | 44 | /* Define to 1 if your processor stores words with the most significant byte 45 | first (like Motorola and SPARC, unlike Intel and VAX). */ 46 | /* #undef WORDS_BIGENDIAN */ 47 | 48 | /* Define to `__inline__' or `__inline' if that's what the C compiler 49 | calls it, or to nothing if 'inline' is not supported under any name. */ 50 | #ifndef __cplusplus 51 | # ifndef inline 52 | # define inline __inline 53 | # endif 54 | #endif 55 | 56 | #define lfind _lfind 57 | -------------------------------------------------------------------------------- /src/main/jni/tiff/libtiff/tif_config.wince.h: -------------------------------------------------------------------------------- 1 | /* $Id: tif_config.wince.h,v 1.1 2007/01/15 18:40:39 mloskot Exp $ */ 2 | 3 | /* 4 | * TIFF library configuration header for Windows CE platform. 5 | */ 6 | #ifndef _WIN32_WCE 7 | # error This version of tif_config.h header is dedicated for Windows CE platform! 8 | #endif 9 | 10 | /* Define to 1 if you have the header file. */ 11 | #define HAVE_ASSERT_H 1 12 | 13 | /* Define to 1 if you have the header file. */ 14 | #define HAVE_FCNTL_H 1 15 | 16 | /* Define as 0 or 1 according to the floating point format suported by the 17 | machine */ 18 | #define HAVE_IEEEFP 1 19 | 20 | /* Define to 1 if you have the `jbg_newlen' function. */ 21 | #define HAVE_JBG_NEWLEN 1 22 | 23 | /* Define to 1 if you have the header file. */ 24 | #define HAVE_STRING_H 1 25 | 26 | /* Define to 1 if you have the header file. */ 27 | #undef HAVE_SYS_TYPES_H 28 | 29 | /* Define to 1 if you have the header file. */ 30 | #define HAVE_IO_H 1 31 | 32 | /* Define to 1 if you have the header file. */ 33 | #define HAVE_SEARCH_H 1 34 | 35 | /* Define to 1 if you have the `setmode' function. */ 36 | #define HAVE_SETMODE 1 37 | 38 | /* Define to 1 if you have the `bsearch' function. */ 39 | #define HAVE_BSEARCH 1 40 | #define bsearch wceex_bsearch 41 | 42 | /* Define to 1 if you have the `lfind' function. */ 43 | #define HAVE_LFIND 1 44 | #define lfind wceex_lfind 45 | 46 | /* The size of a `int', as computed by sizeof. */ 47 | #define SIZEOF_INT 4 48 | 49 | /* The size of a `long', as computed by sizeof. */ 50 | #define SIZEOF_LONG 4 51 | 52 | /* Set the native cpu bit order */ 53 | #define HOST_FILLORDER FILLORDER_LSB2MSB 54 | 55 | /* Define to 1 if your processor stores words with the most significant byte 56 | first (like Motorola and SPARC, unlike Intel and VAX). */ 57 | /* #undef WORDS_BIGENDIAN */ 58 | 59 | /* Define to `__inline__' or `__inline' if that's what the C compiler 60 | calls it, or to nothing if 'inline' is not supported under any name. */ 61 | #ifndef __cplusplus 62 | # ifndef inline 63 | # define inline __inline 64 | # endif 65 | #endif 66 | 67 | 68 | -------------------------------------------------------------------------------- /src/main/jni/tiff/libtiff/tif_error.c: -------------------------------------------------------------------------------- 1 | /* $Header: /cvs/maptools/cvsroot/libtiff/libtiff/tif_error.c,v 1.4 2005/12/23 01:18:59 joris Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1988-1997 Sam Leffler 5 | * Copyright (c) 1991-1997 Silicon Graphics, Inc. 6 | * 7 | * Permission to use, copy, modify, distribute, and sell this software and 8 | * its documentation for any purpose is hereby granted without fee, provided 9 | * that (i) the above copyright notices and this permission notice appear in 10 | * all copies of the software and related documentation, and (ii) the names of 11 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | * publicity relating to the software without the specific, prior written 13 | * permission of Sam Leffler and Silicon Graphics. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | * 19 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | * OF THIS SOFTWARE. 25 | */ 26 | 27 | /* 28 | * TIFF Library. 29 | */ 30 | #include "tiffiop.h" 31 | 32 | TIFFErrorHandlerExt _TIFFerrorHandlerExt = NULL; 33 | 34 | TIFFErrorHandler 35 | TIFFSetErrorHandler(TIFFErrorHandler handler) 36 | { 37 | TIFFErrorHandler prev = _TIFFerrorHandler; 38 | _TIFFerrorHandler = handler; 39 | return (prev); 40 | } 41 | 42 | TIFFErrorHandlerExt 43 | TIFFSetErrorHandlerExt(TIFFErrorHandlerExt handler) 44 | { 45 | TIFFErrorHandlerExt prev = _TIFFerrorHandlerExt; 46 | _TIFFerrorHandlerExt = handler; 47 | return (prev); 48 | } 49 | 50 | void 51 | TIFFError(const char* module, const char* fmt, ...) 52 | { 53 | va_list ap; 54 | va_start(ap, fmt); 55 | if (_TIFFerrorHandler) 56 | (*_TIFFerrorHandler)(module, fmt, ap); 57 | if (_TIFFerrorHandlerExt) 58 | (*_TIFFerrorHandlerExt)(0, module, fmt, ap); 59 | va_end(ap); 60 | } 61 | 62 | void 63 | TIFFErrorExt(thandle_t fd, const char* module, const char* fmt, ...) 64 | { 65 | va_list ap; 66 | va_start(ap, fmt); 67 | if (_TIFFerrorHandler) 68 | (*_TIFFerrorHandler)(module, fmt, ap); 69 | if (_TIFFerrorHandlerExt) 70 | (*_TIFFerrorHandlerExt)(fd, module, fmt, ap); 71 | va_end(ap); 72 | } 73 | 74 | -------------------------------------------------------------------------------- /src/main/jni/tiff/libtiff/tif_flush.c: -------------------------------------------------------------------------------- 1 | /* $Header: /cvs/maptools/cvsroot/libtiff/libtiff/tif_flush.c,v 1.3 2000/09/15 20:52:42 warmerda Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1988-1997 Sam Leffler 5 | * Copyright (c) 1991-1997 Silicon Graphics, Inc. 6 | * 7 | * Permission to use, copy, modify, distribute, and sell this software and 8 | * its documentation for any purpose is hereby granted without fee, provided 9 | * that (i) the above copyright notices and this permission notice appear in 10 | * all copies of the software and related documentation, and (ii) the names of 11 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | * publicity relating to the software without the specific, prior written 13 | * permission of Sam Leffler and Silicon Graphics. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | * 19 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | * OF THIS SOFTWARE. 25 | */ 26 | 27 | /* 28 | * TIFF Library. 29 | */ 30 | #include "tiffiop.h" 31 | 32 | int 33 | TIFFFlush(TIFF* tif) 34 | { 35 | 36 | if (tif->tif_mode != O_RDONLY) { 37 | if (!TIFFFlushData(tif)) 38 | return (0); 39 | if ((tif->tif_flags & TIFF_DIRTYDIRECT) && 40 | !TIFFWriteDirectory(tif)) 41 | return (0); 42 | } 43 | return (1); 44 | } 45 | 46 | /* 47 | * Flush buffered data to the file. 48 | * 49 | * Frank Warmerdam'2000: I modified this to return 1 if TIFF_BEENWRITING 50 | * is not set, so that TIFFFlush() will proceed to write out the directory. 51 | * The documentation says returning 1 is an error indicator, but not having 52 | * been writing isn't exactly a an error. Hopefully this doesn't cause 53 | * problems for other people. 54 | */ 55 | int 56 | TIFFFlushData(TIFF* tif) 57 | { 58 | if ((tif->tif_flags & TIFF_BEENWRITING) == 0) 59 | return (0); 60 | if (tif->tif_flags & TIFF_POSTENCODE) { 61 | tif->tif_flags &= ~TIFF_POSTENCODE; 62 | if (!(*tif->tif_postencode)(tif)) 63 | return (0); 64 | } 65 | return (TIFFFlushData1(tif)); 66 | } 67 | 68 | -------------------------------------------------------------------------------- /src/main/jni/tiff/libtiff/tif_version.c: -------------------------------------------------------------------------------- 1 | /* $Header: /cvs/maptools/cvsroot/libtiff/libtiff/tif_version.c,v 1.2 2000/11/13 14:42:38 warmerda Exp $ */ 2 | /* 3 | * Copyright (c) 1992-1997 Sam Leffler 4 | * Copyright (c) 1992-1997 Silicon Graphics, Inc. 5 | * 6 | * Permission to use, copy, modify, distribute, and sell this software and 7 | * its documentation for any purpose is hereby granted without fee, provided 8 | * that (i) the above copyright notices and this permission notice appear in 9 | * all copies of the software and related documentation, and (ii) the names of 10 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | * publicity relating to the software without the specific, prior written 12 | * permission of Sam Leffler and Silicon Graphics. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | * 18 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | * OF THIS SOFTWARE. 24 | */ 25 | #include "tiffiop.h" 26 | 27 | static const char TIFFVersion[] = TIFFLIB_VERSION_STR; 28 | 29 | const char* 30 | TIFFGetVersion(void) 31 | { 32 | return (TIFFVersion); 33 | } 34 | -------------------------------------------------------------------------------- /src/main/jni/tiff/libtiff/tif_warning.c: -------------------------------------------------------------------------------- 1 | /* $Header: /cvs/maptools/cvsroot/libtiff/libtiff/tif_warning.c,v 1.2 2005/12/23 01:18:59 joris Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1988-1997 Sam Leffler 5 | * Copyright (c) 1991-1997 Silicon Graphics, Inc. 6 | * 7 | * Permission to use, copy, modify, distribute, and sell this software and 8 | * its documentation for any purpose is hereby granted without fee, provided 9 | * that (i) the above copyright notices and this permission notice appear in 10 | * all copies of the software and related documentation, and (ii) the names of 11 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | * publicity relating to the software without the specific, prior written 13 | * permission of Sam Leffler and Silicon Graphics. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | * 19 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | * OF THIS SOFTWARE. 25 | */ 26 | 27 | /* 28 | * TIFF Library. 29 | */ 30 | #include "tiffiop.h" 31 | 32 | TIFFErrorHandlerExt _TIFFwarningHandlerExt = NULL; 33 | 34 | TIFFErrorHandler 35 | TIFFSetWarningHandler(TIFFErrorHandler handler) 36 | { 37 | TIFFErrorHandler prev = _TIFFwarningHandler; 38 | _TIFFwarningHandler = handler; 39 | return (prev); 40 | } 41 | 42 | TIFFErrorHandlerExt 43 | TIFFSetWarningHandlerExt(TIFFErrorHandlerExt handler) 44 | { 45 | TIFFErrorHandlerExt prev = _TIFFwarningHandlerExt; 46 | _TIFFwarningHandlerExt = handler; 47 | return (prev); 48 | } 49 | 50 | void 51 | TIFFWarning(const char* module, const char* fmt, ...) 52 | { 53 | va_list ap; 54 | va_start(ap, fmt); 55 | if (_TIFFwarningHandler) 56 | (*_TIFFwarningHandler)(module, fmt, ap); 57 | if (_TIFFwarningHandlerExt) 58 | (*_TIFFwarningHandlerExt)(0, module, fmt, ap); 59 | va_end(ap); 60 | } 61 | 62 | void 63 | TIFFWarningExt(thandle_t fd, const char* module, const char* fmt, ...) 64 | { 65 | va_list ap; 66 | va_start(ap, fmt); 67 | if (_TIFFwarningHandler) 68 | (*_TIFFwarningHandler)(module, fmt, ap); 69 | if (_TIFFwarningHandlerExt) 70 | (*_TIFFwarningHandlerExt)(fd, module, fmt, ap); 71 | va_end(ap); 72 | } 73 | 74 | 75 | -------------------------------------------------------------------------------- /src/main/jni/tiff/libtiff/tiffio.hxx: -------------------------------------------------------------------------------- 1 | /* $Id: tiffio.hxx,v 1.1 2004/11/21 16:12:08 dron Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1988-1997 Sam Leffler 5 | * Copyright (c) 1991-1997 Silicon Graphics, Inc. 6 | * 7 | * Permission to use, copy, modify, distribute, and sell this software and 8 | * its documentation for any purpose is hereby granted without fee, provided 9 | * that (i) the above copyright notices and this permission notice appear in 10 | * all copies of the software and related documentation, and (ii) the names of 11 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | * publicity relating to the software without the specific, prior written 13 | * permission of Sam Leffler and Silicon Graphics. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | * 19 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | * OF THIS SOFTWARE. 25 | */ 26 | 27 | #ifndef _TIFFIO_HXX_ 28 | #define _TIFFIO_HXX_ 29 | 30 | /* 31 | * TIFF I/O library definitions which provide C++ streams API. 32 | */ 33 | 34 | #include 35 | #include "tiff.h" 36 | 37 | extern TIFF* TIFFStreamOpen(const char*, std::ostream *); 38 | extern TIFF* TIFFStreamOpen(const char*, std::istream *); 39 | 40 | #endif /* _TIFFIO_HXX_ */ 41 | 42 | /* vim: set ts=8 sts=8 sw=8 noet: */ 43 | -------------------------------------------------------------------------------- /src/main/jni/tiff/libtiff/tiffvers.h: -------------------------------------------------------------------------------- 1 | #define TIFFLIB_VERSION_STR "LIBTIFF, Version 3.9.2\nCopyright (c) 1988-1996 Sam Leffler\nCopyright (c) 1991-1996 Silicon Graphics, Inc." 2 | /* 3 | * This define can be used in code that requires 4 | * compilation-related definitions specific to a 5 | * version or versions of the library. Runtime 6 | * version checking should be done based on the 7 | * string returned by TIFFGetVersion. 8 | */ 9 | #define TIFFLIB_VERSION 20091104 10 | -------------------------------------------------------------------------------- /src/main/jni/tiff/m4/ltversion.m4: -------------------------------------------------------------------------------- 1 | # ltversion.m4 -- version numbers -*- Autoconf -*- 2 | # 3 | # Copyright (C) 2004 Free Software Foundation, Inc. 4 | # Written by Scott James Remnant, 2004 5 | # 6 | # This file is free software; the Free Software Foundation gives 7 | # unlimited permission to copy and/or distribute it, with or without 8 | # modifications, as long as this notice is preserved. 9 | 10 | # Generated from ltversion.in. 11 | 12 | # serial 3012 ltversion.m4 13 | # This file is part of GNU Libtool 14 | 15 | m4_define([LT_PACKAGE_VERSION], [2.2.6]) 16 | m4_define([LT_PACKAGE_REVISION], [1.3012]) 17 | 18 | AC_DEFUN([LTVERSION_VERSION], 19 | [macro_version='2.2.6' 20 | macro_revision='1.3012' 21 | _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) 22 | _LT_DECL(, macro_revision, 0) 23 | ]) 24 | -------------------------------------------------------------------------------- /src/main/jni/tiff/man/TIFFClose.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFClose.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFClose 3TIFF "November 2, 2005" "libtiff" 27 | .SH NAME 28 | TIFFClose \- close a previously opened 29 | .SM TIFF 30 | file 31 | .SH SYNOPSIS 32 | .B "#include " 33 | .sp 34 | .BI "void TIFFClose(TIFF *" tif ")" 35 | .SH DESCRIPTION 36 | .IR TIFFClose 37 | closes a file that was previously opened with 38 | .BR TIFFOpen (3TIFF). 39 | Any buffered data are flushed to the file, including the contents of the 40 | current directory (if modified); and all resources are reclaimed. 41 | .SH DIAGNOSTICS 42 | All error messages are directed to the 43 | .bR TIFFError (3TIFF) 44 | routine. 45 | Likewise, warning messages are directed to the 46 | .BR TIFFWarning (3TIFF) 47 | routine. 48 | .SH "SEE ALSO" 49 | .BR libtiff (3TIFF), 50 | .BR TIFFOpen (3TIFF) 51 | .PP 52 | Libtiff library home page: 53 | .BR http://www.remotesensing.org/libtiff/ 54 | -------------------------------------------------------------------------------- /src/main/jni/tiff/man/TIFFDataWidth.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFDataWidth.3tiff,v 1.3 2006/03/23 14:54:02 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 2002, Andrey Kiselev 4 | .\" 5 | .\" Permission to use, copy, modify, distribute, and sell this software and 6 | .\" its documentation for any purpose is hereby granted without fee, provided 7 | .\" that (i) the above copyright notices and this permission notice appear in 8 | .\" all copies of the software and related documentation, and (ii) the names of 9 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | .\" publicity relating to the software without the specific, prior written 11 | .\" permission of Sam Leffler and Silicon Graphics. 12 | .\" 13 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | .\" 17 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | .\" OF THIS SOFTWARE. 23 | .\" 24 | .if n .po 0 25 | .TH TIFFDataWidth 3TIFF "September 12, 2002" "libtiff" 26 | .SH NAME 27 | TIFFDataWidth \- Get the size of TIFF data types 28 | .SH SYNOPSIS 29 | .B "#include " 30 | .sp 31 | .BI "int TIFFDataWidth(TIFFDataType " type ")" 32 | .SH DESCRIPTION 33 | .I TIFFDataWidth 34 | returns a size of 35 | .I type 36 | in bytes. 37 | Currently following data types are supported: 38 | .br 39 | .I TIFF_BYTE 40 | .br 41 | .I TIFF_ASCII 42 | .br 43 | .I TIFF_SBYTE 44 | .br 45 | .I TIFF_UNDEFINED 46 | .br 47 | .I TIFF_SHORT 48 | .br 49 | .I TIFF_SSHORT 50 | .br 51 | .I TIFF_LONG 52 | .br 53 | .I TIFF_SLONG 54 | .br 55 | .I TIFF_FLOAT 56 | .br 57 | .I TIFF_IFD 58 | .br 59 | .I TIFF_RATIONAL 60 | .br 61 | .I TIFF_SRATIONAL 62 | .br 63 | .I TIFF_DOUBLE 64 | .br 65 | .SH "RETURN VALUES" 66 | .br 67 | .IR TIFFDataWidth 68 | returns a number of bytes occupied by the item of given type. 0 returned when 69 | uknown data type supplied. 70 | .SH "SEE ALSO" 71 | .BR libtiff (3TIFF), 72 | .PP 73 | Libtiff library home page: 74 | .BR http://www.remotesensing.org/libtiff/ 75 | -------------------------------------------------------------------------------- /src/main/jni/tiff/man/TIFFError.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFError.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFError 3TIFF "October 15, 1995" "libtiff" 27 | .SH NAME 28 | TIFFError, TIFFSetErrorHandler \- library error handling interface 29 | .SH SYNOPSIS 30 | .B "#include " 31 | .sp 32 | .BI "void TIFFError(const char *" module ", const char *" fmt ", " ... ")" 33 | .sp 34 | .B "#include " 35 | .sp 36 | .BI "typedef void (*TIFFErrorHandler)(const char *" module ", const char *" fmt ", va_list " ap ");" 37 | .br 38 | .B "TIFFErrorHandler TIFFSetErrorHandler(TIFFErrorHandler handler);" 39 | .SH DESCRIPTION 40 | .I TIFFError 41 | invokes the library-wide error handling function to (normally) write an error 42 | message to the 43 | .BR stderr . 44 | The 45 | .I fmt 46 | parameter is a 47 | .IR printf (3S) 48 | format string, and any number arguments can be supplied. The 49 | .I module 50 | parameter, if non-zero, is printed before the message; it typically is used to 51 | identify the software module in which an error is detected. 52 | .PP 53 | Applications that desire to capture control in the event of an error should 54 | use 55 | .IR TIFFSetErrorHandler 56 | to override the default error handler. 57 | A 58 | .SM NULL 59 | (0) error handling function may be installed to suppress error messages. 60 | .SH "RETURN VALUES" 61 | .IR TIFFSetErrorHandler 62 | returns a reference to the previous error handling function. 63 | .SH "SEE ALSO" 64 | .BR TIFFWarning (3TIFF), 65 | .BR libtiff (3TIFF), 66 | .BR printf (3) 67 | .PP 68 | Libtiff library home page: 69 | .BR http://www.remotesensing.org/libtiff/ 70 | -------------------------------------------------------------------------------- /src/main/jni/tiff/man/TIFFFlush.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFFlush.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFFlush 3TIFF "December 16, 1991" "libtiff" 27 | .SH NAME 28 | TIFFFlush, TIFFFlushData \- flush pending writes to an open 29 | .SM TIFF 30 | file 31 | .SH SYNOPSIS 32 | .B "#include " 33 | .sp 34 | .BI "int TIFFFlush(TIFF *" tif ")" 35 | .br 36 | .BI "int TIFFFlushData(TIFF *" tif ")" 37 | .SH DESCRIPTION 38 | .IR TIFFFlush 39 | causes any pending writes for the specified file (including writes for the 40 | current directory) to be done. In normal operation this call is never needed \- 41 | the library automatically does any flushing required. 42 | .PP 43 | .IR TIFFFlushData 44 | flushes any pending image data for the specified file to be written out; 45 | directory-related data are not flushed. In normal operation this call is never 46 | needed \- the library automatically does any flushing required. 47 | .SH "RETURN VALUES" 48 | 0 is returned if an error is encountered, otherwise 1 is returned. 49 | .SH DIAGNOSTICS 50 | All error messages are directed to the 51 | .BR TIFFError (3TIFF) 52 | routine. 53 | .SH "SEE ALSO" 54 | .BR TIFFOpen (3TIFF), 55 | .BR TIFFWriteEncodedStrip (3TIFF), 56 | .BR TIFFWriteEncodedTile (3TIFF), 57 | .BR TIFFWriteRawStrip (3TIFF), 58 | .BR TIFFWriteRawTile (3TIFF), 59 | .BR TIFFWriteScanline (3TIFF), 60 | .BR TIFFWriteTile (3TIFF) 61 | .BR libtiff (3TIFF), 62 | .PP 63 | Libtiff library home page: 64 | .BR http://www.remotesensing.org/libtiff/ 65 | -------------------------------------------------------------------------------- /src/main/jni/tiff/man/TIFFPrintDirectory.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFPrintDirectory.3tiff,v 1.1 2004/11/11 14:39:16 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1991-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFPrintDirectory 3TIFF "December 12, 1991" "libtiff" 27 | .SH NAME 28 | TIFFPrintDirectory \- print a description of a 29 | .SM TIFF 30 | directory 31 | .SH SYNOPSIS 32 | .B "#include " 33 | .sp 34 | .BI "void TIFFPrintDirectory(TIFF *" tif ", FILE *" fd ", long " flags ")" 35 | .SH DESCRIPTION 36 | .I TIFFPrintDirectory 37 | prints a description of the current directory in the specified 38 | .SM TIFF 39 | file to the standard I/O output stream 40 | .IR fd . 41 | The 42 | .I flags 43 | parameter is used to control the 44 | .I "level of detail" 45 | of the printed information; it is a bit-or of the flags defined in 46 | .BR tiffio.h : 47 | .sp .5 48 | .nf 49 | .ta \w'#define 'u +\w'TIFFPRINT_JPEGDCTABLES 'u +\w'0x200 'u 50 | #define TIFFPRINT_NONE 0x0 /* no extra info */ 51 | #define TIFFPRINT_STRIPS 0x1 /* strips/tiles info */ 52 | #define TIFFPRINT_CURVES 0x2 /* color/gray response curves */ 53 | #define TIFFPRINT_COLORMAP 0x4 /* colormap */ 54 | #define TIFFPRINT_JPEGQTABLES 0x100 /* JPEG Q matrices */ 55 | #define TIFFPRINT_JPEGACTABLES 0x200 /* JPEG AC tables */ 56 | #define TIFFPRINT_JPEGDCTABLES 0x200 /* JPEG DC tables */ 57 | .fi 58 | .SH NOTES 59 | In C++ the 60 | .I flags 61 | parameter defaults to 0. 62 | .SH "RETURN VALUES" 63 | None. 64 | .SH DIAGNOSTICS 65 | None. 66 | .SH "SEE ALSO" 67 | .IR libtiff (3TIFF), 68 | .IR TIFFOpen (3TIFF), 69 | .IR TIFFReadDirectory (3TIFF), 70 | .IR TIFFSetDirectory (3TIFF) 71 | -------------------------------------------------------------------------------- /src/main/jni/tiff/man/TIFFReadRawStrip.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFReadRawStrip.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFReadRawStrip 3TIFF "October 15, 1995" "libtiff" 27 | .SH NAME 28 | TIFFReadRawStrip \- return the undecoded contents of a strip of data from an 29 | open 30 | .SM TIFF 31 | file 32 | .SH SYNOPSIS 33 | .B "#include " 34 | .sp 35 | .BI "tsize_t TIFFReadRawStrip(TIFF *" tif ", tstrip_t " strip ", tdata_t " buf ", tsize_t " size ")" 36 | .SH DESCRIPTION 37 | Read the contents of the specified strip into the (user supplied) data buffer. 38 | Note that the value of 39 | .I strip 40 | is a ``raw strip number.'' That is, the caller must take into account whether 41 | or not the data is organized in separate planes (\c 42 | .IR PlanarConfiguration =2). 43 | To read a full strip of data the data buffer should typically be at least as 44 | large as the number returned by 45 | .IR TIFFStripSize . 46 | .SH "RETURN VALUES" 47 | The actual number of bytes of data that were placed in 48 | .I buf 49 | is returned; 50 | .IR TIFFReadEncodedStrip 51 | returns \-1 if an error was encountered. 52 | .SH DIAGNOSTICS 53 | All error messages are directed to the 54 | .BR TIFFError (3TIFF) 55 | routine. 56 | .SH "SEE ALSO" 57 | .BR TIFFOpen (3TIFF), 58 | .BR TIFFReadEncodedStrip (3TIFF), 59 | .BR TIFFReadScanline (3TIFF), 60 | .BR TIFFStripSize (3TIFF), 61 | .BR libtiff (3TIFF) 62 | .PP 63 | Libtiff library home page: 64 | .BR http://www.remotesensing.org/libtiff/ 65 | -------------------------------------------------------------------------------- /src/main/jni/tiff/man/TIFFReadRawTile.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFReadRawTile.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFReadRawTile 3TIFF "October 15, 1995" "libtiff" 27 | .SH NAME 28 | TIFFReadRawTile \- return an undecoded tile of data from an open 29 | .SM TIFF 30 | file 31 | .SH SYNOPSIS 32 | .B "#include " 33 | .sp 34 | .BI "tsize_t TIFFReadRawTile(TIFF *" tif ", ttile_t " tile ", tdata_t " buf ", tsize_t " size ")" 35 | .SH DESCRIPTION 36 | Read the contents of the specified tile into the (user supplied) data buffer. 37 | Note that the value of 38 | .I tile 39 | is a ``raw tile number.'' That is, the caller must take into account whether 40 | or not the data is organized in separate planes (\c 41 | .IR PlanarConfiguration =2). 42 | .I TIFFComputeTile 43 | automatically does this when converting an (x,y,z,sample) coordinate quadruple 44 | to a tile number. To read a full tile of data the data buffer should typically 45 | be at least as large as the value returned by 46 | .IR TIFFTileSize . 47 | .SH "RETURN VALUES" 48 | The actual number of bytes of data that were placed in 49 | .I buf 50 | is returned; 51 | .IR TIFFReadEncodedTile 52 | returns \-1 if an error was encountered. 53 | .SH DIAGNOSTICS 54 | All error messages are directed to the 55 | .BR TIFFError (3TIFF) 56 | routine. 57 | .SH "SEE ALSO" 58 | .BR TIFFOpen (3TIFF), 59 | .BR TIFFReadEncodedTile (3TIFF), 60 | .BR TIFFReadTile (3TIFF), 61 | .BR TIFFTileSize (3TIFF), 62 | .BR libtiff (3TIFF) 63 | .PP 64 | Libtiff library home page: 65 | .BR http://www.remotesensing.org/libtiff/ 66 | -------------------------------------------------------------------------------- /src/main/jni/tiff/man/TIFFsize.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFsize.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFSIZE 3TIFF "October 15, 1995" "libtiff" 27 | .SH NAME 28 | TIFFScanlineSize, TIFFRasterScanlineSize, 29 | \- return the size of various items associated with an open 30 | .SM TIFF 31 | file 32 | .SH SYNOPSIS 33 | .B "#include " 34 | .sp 35 | .BI "tsize_t TIFFRasterScanlineSize(TIFF *" tif ")" 36 | .br 37 | .BI "tsize_t TIFFScanlineSize(TIFF *" tif ")" 38 | .SH DESCRIPTION 39 | .I TIFFScanlineSize 40 | returns the size in bytes of a row of data as it would be returned in a call 41 | to 42 | .IR TIFFReadScanline , 43 | or as it would be expected in a call to 44 | .IR TIFFWriteScanline . 45 | .PP 46 | .I TIFFRasterScanlineSize 47 | returns the size in bytes of a complete decoded and packed raster scanline. 48 | Note that this value may be different from the value returned by 49 | .I TIFFScanlineSize 50 | if data is stored as separate planes. 51 | .SH DIAGNOSTICS 52 | None. 53 | .SH "SEE ALSO" 54 | .BR TIFFOpen (3TIFF), 55 | .BR TIFFReadScanline (3TIFF), 56 | .BR libtiff (3TIFF) 57 | .PP 58 | Libtiff library home page: 59 | .BR http://www.remotesensing.org/libtiff/ 60 | -------------------------------------------------------------------------------- /src/main/jni/tiff/man/tiffset.1: -------------------------------------------------------------------------------- 1 | .\" $Id: tiffset.1,v 1.3 2006/04/20 12:17:19 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFSET 1 "November 21, 2004" "libtiff" 27 | .SH NAME 28 | tiffset \- set a field in a 29 | .SM TIFF 30 | header 31 | .SH SYNOPSIS 32 | .B tiffset 33 | [ 34 | .I options 35 | ] 36 | .I filename.tif 37 | .SH DESCRIPTION 38 | .I Tiffset 39 | sets the value of a 40 | .SM TIFF 41 | header to a specified value. 42 | .SH OPTIONS 43 | .TP 44 | .BI \-s " tagnumber" "\fR [\fP" " count" "\fR ]\fP" " value ..." 45 | Set the value of the named tag to the value or values specified. 46 | .TP 47 | .BI \-sf " tagnumber filename" 48 | Set the value of the tag to the contents of filename. This option is 49 | supported for ASCII tags only. 50 | .SH EXAMPLES 51 | The following example sets the image description tag (270) of a.tif to 52 | the contents of the file descrip: 53 | .RS 54 | .nf 55 | tiffset \-sf 270 descrip a.tif 56 | .fi 57 | .RE 58 | .PP 59 | The following example sets the artist tag (315) of a.tif to the string 60 | ``Anonymous'': 61 | .RS 62 | .nf 63 | tiffset \-s 305 Anonymous a.tif 64 | .fi 65 | .RE 66 | .PP 67 | This example sets the resolution of the file a.tif to 300 dpi: 68 | .RS 69 | .nf 70 | tiffset \-s 296 2 a.tif 71 | tiffset \-s 282 300.0 a.tif 72 | tiffset \-s 283 300.0 a.tif 73 | .fi 74 | .RE 75 | .SH "SEE ALSO" 76 | .BR tiffdump (1), 77 | .BR tiffinfo (1), 78 | .BR tiffcp (1), 79 | .BR libtiff (3TIFF) 80 | .PP 81 | Libtiff library home page: 82 | .BR http://www.remotesensing.org/libtiff/ 83 | -------------------------------------------------------------------------------- /src/main/jni/tiff/man/tiffsplit.1: -------------------------------------------------------------------------------- 1 | .\" $Id: tiffsplit.1,v 1.5 2005/11/02 11:07:19 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1992-1997 Sam Leffler 4 | .\" Copyright (c) 1992-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFSPLIT 1 "September 20, 2005" "libtiff" 27 | .SH NAME 28 | tiffsplit \- split a multi-image 29 | .SM TIFF 30 | into single-image 31 | .SM TIFF 32 | files 33 | .SH SYNOPSIS 34 | .B tiffsplit 35 | .I src.tif 36 | [ 37 | .I prefix 38 | ] 39 | .SH DESCRIPTION 40 | .I tiffsplit 41 | takes a multi-directory (page) 42 | .SM TIFF 43 | file and creates one or more single-directory (page) 44 | .SM TIFF 45 | files from it. 46 | The output files are given names created by concatenating 47 | a prefix, a lexically ordered 48 | suffix in the range [\fIaaa\fP-\fIzzz\fP], the suffix 49 | .I .tif 50 | (e.g. 51 | .IR xaaa.tif , 52 | .IR xaab.tif , 53 | \... 54 | .IR xzzz.tif ). 55 | If a prefix is not specified on the command line, 56 | the default prefix of 57 | .I x 58 | is used. 59 | .SH OPTIONS 60 | None. 61 | .SH BUGS 62 | Only a select set of ``known tags'' is copied when splitting. 63 | .SH "SEE ALSO" 64 | .BR tiffcp (1), 65 | .BR tiffinfo (1), 66 | .BR libtiff (3TIFF) 67 | .PP 68 | Libtiff library home page: 69 | .BR http://www.remotesensing.org/libtiff/ 70 | -------------------------------------------------------------------------------- /src/main/jni/tiff/port/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = Makefile.vc 27 | 28 | noinst_LTLIBRARIES = libport.la 29 | libport_la_SOURCES = dummy.c libport.h 30 | libport_la_LIBADD = @LTLIBOBJS@ 31 | 32 | -------------------------------------------------------------------------------- /src/main/jni/tiff/port/Makefile.vc: -------------------------------------------------------------------------------- 1 | # $Id: Makefile.vc,v 1.4 2006/03/23 14:54:02 dron Exp $ 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | # 24 | # Makefile for MS Visual C and Watcom C compilers. 25 | # 26 | # To build: 27 | # C:\libtiff\port> nmake /f makefile.vc 28 | 29 | !INCLUDE ..\nmake.opt 30 | 31 | OBJ = \ 32 | strcasecmp.obj \ 33 | getopt.obj 34 | 35 | all: libport.lib 36 | 37 | libport.lib: $(OBJ) 38 | $(AR) /out:libport.lib $(OBJ) 39 | 40 | clean: 41 | -del *.obj 42 | -del *.lib 43 | 44 | -------------------------------------------------------------------------------- /src/main/jni/tiff/port/dummy.c: -------------------------------------------------------------------------------- 1 | /* $Id: dummy.c,v 1.2.2.1 2007/03/21 14:53:46 dron Exp $ */ 2 | 3 | /* 4 | * Dummy function, just to be ensure that the library always will be created. 5 | */ 6 | 7 | void 8 | libport_dummy_function() 9 | { 10 | return; 11 | } 12 | 13 | -------------------------------------------------------------------------------- /src/main/jni/tiff/port/lfind.c: -------------------------------------------------------------------------------- 1 | /* $Id: lfind.c,v 1.4 2007/01/15 18:40:39 mloskot Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1989, 1993 5 | * The Regents of the University of California. All rights reserved. 6 | * 7 | * This code is derived from software contributed to Berkeley by 8 | * Roger L. Snyder. 9 | * 10 | * Redistribution and use in source and binary forms, with or without 11 | * modification, are permitted provided that the following conditions 12 | * are met: 13 | * 1. Redistributions of source code must retain the above copyright 14 | * notice, this list of conditions and the following disclaimer. 15 | * 2. Redistributions in binary form must reproduce the above copyright 16 | * notice, this list of conditions and the following disclaimer in the 17 | * documentation and/or other materials provided with the distribution. 18 | * 3. Neither the name of the University nor the names of its contributors 19 | * may be used to endorse or promote products derived from this software 20 | * without specific prior written permission. 21 | * 22 | * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 23 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 24 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 25 | * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 26 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 27 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 28 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 29 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 31 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 32 | * SUCH DAMAGE. 33 | */ 34 | 35 | #if 0 36 | static char sccsid[] = "@(#)lsearch.c 8.1 (Berkeley) 6/4/93"; 37 | __RCSID("$NetBSD: lsearch.c,v 1.2 2005/07/06 15:47:15 drochner Exp $"); 38 | #endif 39 | 40 | #ifdef _WIN32_WCE 41 | # include 42 | #else 43 | # include 44 | #endif 45 | 46 | #ifndef NULL 47 | # define NULL 0 48 | #endif 49 | 50 | void * 51 | lfind(const void *key, const void *base, size_t *nmemb, size_t size, 52 | int(*compar)(const void *, const void *)) 53 | { 54 | char *element, *end; 55 | 56 | end = (char *)base + *nmemb * size; 57 | for (element = (char *)base; element < end; element += size) 58 | if (!compar(element, key)) /* key found */ 59 | return element; 60 | 61 | return NULL; 62 | } 63 | -------------------------------------------------------------------------------- /src/main/jni/tiff/port/libport.h: -------------------------------------------------------------------------------- 1 | /* $Id: libport.h,v 1.2.2.2 2009-11-02 14:47:41 bfriesen Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 2009 Frank Warmerdam 5 | * 6 | * Permission to use, copy, modify, distribute, and sell this software and 7 | * its documentation for any purpose is hereby granted without fee, provided 8 | * that (i) the above copyright notices and this permission notice appear in 9 | * all copies of the software and related documentation, and (ii) the names of 10 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | * publicity relating to the software without the specific, prior written 12 | * permission of Sam Leffler and Silicon Graphics. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | * 18 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | * OF THIS SOFTWARE. 24 | */ 25 | 26 | #ifndef _LIBPORT_ 27 | #define _LIBPORT_ 28 | 29 | int getopt(int argc, char * const argv[], const char *optstring); 30 | extern char *optarg; 31 | extern int opterr; 32 | extern int optind; 33 | extern int optopt; 34 | 35 | int strcasecmp(const char *s1, const char *s2); 36 | 37 | #ifndef HAVE_GETOPT 38 | # define HAVE_GETOPT 1 39 | #endif 40 | 41 | #if 0 42 | unsigned long strtoul(const char *nptr, char **endptr, int base); 43 | #endif 44 | 45 | #if 0 46 | void * 47 | lfind(const void *key, const void *base, size_t *nmemb, size_t size, 48 | int(*compar)(const void *, const void *)); 49 | #endif 50 | 51 | #endif /* ndef _LIBPORT_ */ 52 | -------------------------------------------------------------------------------- /src/main/jni/tiff/port/strcasecmp.c: -------------------------------------------------------------------------------- 1 | /* $Id: strcasecmp.c,v 1.2 2005/07/07 16:34:06 dron Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1987, 1993 5 | * The Regents of the University of California. All rights reserved. 6 | * 7 | * Redistribution and use in source and binary forms, with or without 8 | * modification, are permitted provided that the following conditions 9 | * are met: 10 | * 1. Redistributions of source code must retain the above copyright 11 | * notice, this list of conditions and the following disclaimer. 12 | * 2. Redistributions in binary form must reproduce the above copyright 13 | * notice, this list of conditions and the following disclaimer in the 14 | * documentation and/or other materials provided with the distribution. 15 | * 3. Neither the name of the University nor the names of its contributors 16 | * may be used to endorse or promote products derived from this software 17 | * without specific prior written permission. 18 | * 19 | * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 21 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 23 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 24 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 25 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 26 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 27 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 28 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 29 | * SUCH DAMAGE. 30 | */ 31 | 32 | #if 0 33 | static char sccsid[] = "@(#)strcasecmp.c 8.1 (Berkeley) 6/4/93"; 34 | __RCSID("$NetBSD: strcasecmp.c,v 1.16 2003/08/07 16:43:49 agc Exp $"); 35 | #endif 36 | 37 | #include 38 | #include 39 | 40 | int 41 | strcasecmp(const char *s1, const char *s2) 42 | { 43 | const unsigned char *us1 = (const unsigned char *)s1, 44 | *us2 = (const unsigned char *)s2; 45 | 46 | while (tolower(*us1) == tolower(*us2++)) 47 | if (*us1++ == '\0') 48 | return (0); 49 | return (tolower(*us1) - tolower(*--us2)); 50 | } 51 | -------------------------------------------------------------------------------- /src/main/jni/tiff/test/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | AUTOMAKE_OPTIONS = 1.11 color-tests parallel-tests foreign 27 | 28 | LIBTIFF = $(top_builddir)/libtiff/libtiff.la 29 | 30 | #EXTRA_DIST = Makefile.vc 31 | 32 | TESTS = $(check_PROGRAMS) 33 | 34 | check_PROGRAMS = ascii_tag long_tag short_tag strip_rw 35 | 36 | ascii_tag_SOURCES = ascii_tag.c 37 | ascii_tag_LDADD = $(LIBTIFF) 38 | long_tag_SOURCES = long_tag.c check_tag.c 39 | long_tag_LDADD = $(LIBTIFF) 40 | short_tag_SOURCES = short_tag.c check_tag.c 41 | short_tag_LDADD = $(LIBTIFF) 42 | strip_rw_SOURCES = strip_rw.c strip.c test_arrays.c test_arrays.h 43 | strip_rw_LDADD = $(LIBTIFF) 44 | 45 | INCLUDES = -I$(top_srcdir)/libtiff 46 | 47 | -------------------------------------------------------------------------------- /src/main/jni/tiff/test/check_tag.c: -------------------------------------------------------------------------------- 1 | /* $Id: check_tag.c,v 1.2 2006/03/23 14:54:02 dron Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 2004, Andrey Kiselev 5 | * 6 | * Permission to use, copy, modify, distribute, and sell this software and 7 | * its documentation for any purpose is hereby granted without fee, provided 8 | * that (i) the above copyright notices and this permission notice appear in 9 | * all copies of the software and related documentation, and (ii) the names of 10 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | * publicity relating to the software without the specific, prior written 12 | * permission of Sam Leffler and Silicon Graphics. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | * 18 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | * OF THIS SOFTWARE. 24 | */ 25 | 26 | /* 27 | * TIFF Library 28 | * 29 | * Module to test LONG tags read/write functions. 30 | */ 31 | 32 | #include "tiffio.h" 33 | 34 | int 35 | CheckShortField(TIFF *tif, ttag_t field, uint16 value) 36 | { 37 | uint16 tmp = 0; 38 | 39 | if (!TIFFGetField(tif, field, &tmp)) { 40 | fprintf (stderr, "Problem fetching tag %lu.\n", 41 | (unsigned long) field); 42 | return -1; 43 | } 44 | if (tmp != value) { 45 | fprintf (stderr, "Wrong SHORT value fetched for tag %lu.\n", 46 | (unsigned long) field); 47 | return -1; 48 | } 49 | 50 | return 0; 51 | } 52 | 53 | int 54 | CheckLongField(TIFF *tif, ttag_t field, uint32 value) 55 | { 56 | uint32 tmp = 0; 57 | 58 | if (!TIFFGetField(tif, field, &tmp)) { 59 | fprintf (stderr, "Problem fetching tag %lu.\n", 60 | (unsigned long) field); 61 | return -1; 62 | } 63 | if (tmp != value) { 64 | fprintf (stderr, "Wrong LONG value fetched for tag %lu.\n", 65 | (unsigned long) field); 66 | return -1; 67 | } 68 | 69 | return 0; 70 | } 71 | 72 | 73 | -------------------------------------------------------------------------------- /src/main/jni/tiff/test/test_arrays.h: -------------------------------------------------------------------------------- 1 | /* $Id: test_arrays.h,v 1.3 2006/03/23 14:54:02 dron Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 2004, Andrey Kiselev 5 | * 6 | * Permission to use, copy, modify, distribute, and sell this software and 7 | * its documentation for any purpose is hereby granted without fee, provided 8 | * that (i) the above copyright notices and this permission notice appear in 9 | * all copies of the software and related documentation, and (ii) the names of 10 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | * publicity relating to the software without the specific, prior written 12 | * permission of Sam Leffler and Silicon Graphics. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | * 18 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | * OF THIS SOFTWARE. 24 | */ 25 | 26 | /* 27 | * TIFF Library 28 | * 29 | * Few declarations for the test numerical arrays. 30 | */ 31 | 32 | #ifndef _TEST_ARRAYS_ 33 | #define _TEST_ARRAYS_ 34 | 35 | #include 36 | 37 | #define XSIZE 37 38 | #define YSIZE 23 39 | 40 | extern const unsigned char byte_array1[]; 41 | extern const size_t byte_array1_size; 42 | 43 | extern const unsigned char byte_array2[]; 44 | extern const size_t byte_array2_size; 45 | 46 | extern const unsigned char byte_array3[]; 47 | extern const size_t byte_array3_size; 48 | 49 | extern const float array_float1[]; 50 | extern const size_t array_float1_size; 51 | 52 | extern const float array_float2[]; 53 | extern const size_t array_float2_size; 54 | 55 | extern const double array_double1[]; 56 | extern const size_t array_double1_size; 57 | 58 | extern const double array_double2[]; 59 | extern const size_t array_double2_size; 60 | 61 | #endif /* _TEST_ARRAYS_ */ 62 | 63 | /* vim: set ts=8 sts=8 sw=8 noet: */ 64 | -------------------------------------------------------------------------------- /src/main/jni/tiff/tools/Makefile.vc: -------------------------------------------------------------------------------- 1 | # $Id: Makefile.vc,v 1.13 2007/02/24 15:26:09 dron Exp $ 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | # 24 | # Makefile for MS Visual C and Watcom C compilers. 25 | # 26 | # To build: 27 | # C:\libtiff\tools> nmake /f makefile.vc 28 | 29 | !INCLUDE ..\nmake.opt 30 | 31 | TARGETS = bmp2tiff.exe tiffinfo.exe tiffdump.exe fax2tiff.exe \ 32 | fax2ps.exe gif2tiff.exe pal2rgb.exe ppm2tiff.exe \ 33 | rgb2ycbcr.exe thumbnail.exe ras2tiff.exe raw2tiff.exe \ 34 | tiff2bw.exe tiff2rgba.exe tiff2pdf.exe tiff2ps.exe \ 35 | tiffcmp.exe tiffcp.exe tiffcrop.exe tiffdither.exe \ 36 | tiffmedian.exe tiffset.exe tiffsplit.exe 37 | 38 | INCL = -I..\libtiff 39 | LIBS = $(LIBS) ..\port\libport.lib ..\libtiff\libtiff.lib 40 | 41 | default: $(TARGETS) 42 | 43 | .c.exe: 44 | $(CC) $(CFLAGS) $*.c $(EXTRA_OBJ) $(LIBS) 45 | 46 | tiffgt.exe: 47 | $(CC) $(CFLAGS) tiffgt.c $(EXTRA_OBJ) $(LIBS) 48 | 49 | clean: 50 | -del *.exe 51 | -del *.obj 52 | -------------------------------------------------------------------------------- /src/main/jni/tiff/tools/rasterfile.h: -------------------------------------------------------------------------------- 1 | /* $Header: /cvs/maptools/cvsroot/libtiff/tools/rasterfile.h,v 1.3 2003/11/12 19:14:33 dron Exp $ */ 2 | 3 | /* 4 | * Description of header for files containing raster images 5 | */ 6 | struct rasterfile { 7 | char ras_magic[4]; /* magic number */ 8 | long ras_width; /* width (pixels) of image */ 9 | long ras_height; /* height (pixels) of image */ 10 | long ras_depth; /* depth (1, 8, or 24 bits) of pixel */ 11 | long ras_length; /* length (bytes) of image */ 12 | long ras_type; /* type of file; see RT_* below */ 13 | long ras_maptype; /* type of colormap; see RMT_* below */ 14 | long ras_maplength; /* length (bytes) of following map */ 15 | /* color map follows for ras_maplength bytes, followed by image */ 16 | }; 17 | #define RAS_MAGIC "\x59\xa6\x6a\x95" 18 | #define RAS_MAGIC_INV "\x95\x6a\xa6\x59" 19 | 20 | /* Sun supported ras_type's */ 21 | #define RT_OLD 0 /* Raw pixrect image in 68000 byte order */ 22 | #define RT_STANDARD 1 /* Raw pixrect image in 68000 byte order */ 23 | #define RT_BYTE_ENCODED 2 /* Run-length compression of bytes */ 24 | #define RT_EXPERIMENTAL 0xffff /* Reserved for testing */ 25 | 26 | /* Sun registered ras_maptype's */ 27 | #define RMT_RAW 2 28 | /* Sun supported ras_maptype's */ 29 | #define RMT_NONE 0 /* ras_maplength is expected to be 0 */ 30 | #define RMT_EQUAL_RGB 1 /* red[ras_maplength/3],green[],blue[] */ 31 | 32 | /* 33 | * NOTES: 34 | * Each line of the image is rounded out to a multiple of 16 bits. 35 | * This corresponds to the rounding convention used by the memory pixrect 36 | * package (/usr/include/pixrect/memvar.h) of the SunWindows system. 37 | * The ras_encoding field (always set to 0 by Sun's supported software) 38 | * was renamed to ras_length in release 2.0. As a result, rasterfiles 39 | * of type 0 generated by the old software claim to have 0 length; for 40 | * compatibility, code reading rasterfiles must be prepared to compute the 41 | * true length from the width, height, and depth fields. 42 | */ 43 | -------------------------------------------------------------------------------- /src/main/jni/tiffvers.h: -------------------------------------------------------------------------------- 1 | #define TIFFLIB_VERSION_STR "LIBTIFF, Version 3.9.2\nCopyright (c) 1988-1996 Sam Leffler\nCopyright (c) 1991-1996 Silicon Graphics, Inc." 2 | /* 3 | * This define can be used in code that requires 4 | * compilation-related definitions specific to a 5 | * version or versions of the library. Runtime 6 | * version checking should be done based on the 7 | * string returned by TIFFGetVersion. 8 | */ 9 | #define TIFFLIB_VERSION 20091104 10 | -------------------------------------------------------------------------------- /src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | TiffBitmapFactory 3 | 4 | --------------------------------------------------------------------------------