tiff

Create a Bigtiff (>4GB) File with Bitmiracle Libtiff.net

♀尐吖头ヾ 提交于 2019-12-07 18:30:01
问题 First I want to thank Bitmiracle for this great lib. Even while creating very big files, the memory footprint is very low. A few days ago I ran into a problem where I wanted to create a tiff file bigger than 4GB. I created the tiled tiff file successfully, but it seems that the color of the tiles created beyond 4GB are somehow inverted. Here the code relevant code: Usage: WriteTiledTiff("bigtiff.tiff",BitmapSourceFromBrush(new RadialGradientBrush(Colors.Aqua,Colors.Red), 256)); Methods:

Create multipage Tiff with JPEG compression .NET

二次信任 提交于 2019-12-07 18:08:27
问题 Is there any way to create multipage tiff with jpeg compression using .NET? I can create tiff's with LZW compression, but files are extremely big. Looks like EncoderValue enumeration (which I use to set up compression) doesn't even have suitable member. 回答1: You can have a look at >> this post, where I explain how to wrap existing JPEGs in a simple multi-page TIFF container. But there's a variety of other possibilities. FreeImage.Net (freeimage.sourceforge.net) is a very powerful library. You

How to add GPS metadata to TIFF in Java?

那年仲夏 提交于 2019-12-07 17:09:27
问题 I am attempting to add GPS data to a TIFF file I am creating in Java. I am using the JAI-ImageIO libraries, although if there is a better library for doing both GPS metadata and custom metadata, I am willing to look into it. I have attempted to add the GPS metadata to the nodes directly, but it seems to strip off the GPS IDF tag. I have attempted to add the GPS IFD to the TIFFIFD object (from the TIFFIMageMetadata object), but that doesn't seem to save the data properly. Basically, I am

How to read TIFF header File c#?

天大地大妈咪最大 提交于 2019-12-07 16:28:19
问题 I wanna know how it is possible to read a file in binary format. for example a tiff image file may have the following binary format in hex 0000 4949 002A 0000. how can i get these values in c#? 回答1: Here is how I usually read files in hexadecimal format, changed for the header, as you need: using System; using System.Linq; using System.IO; namespace FileToHex { class Program { static void Main(string[] args) { //read only 4 bytes from the file const int HEADER_SIZE = 4; byte[] bytesFile = new

Convert UIImage to tiff/tif file

无人久伴 提交于 2019-12-07 15:18:42
问题 In my iPhone app, I need to convert UIImage to tiff/tif file for calling some API with tif type of parameter. So I'm supposed to get the UIImage from iphone photo library or taking a photo from camera. Please let me know whether this conversion (UIImage to tif/tiff) is possible and if possible what would be the best way to do it. Thanks in advance. 回答1: ImageMagick runs on iOS and seems to fit the bill. However, I would consider modifying the API, assuming you have access to it. If the

Merge multiple multi-page tiff images to a single tiff C#

安稳与你 提交于 2019-12-07 14:26:10
问题 In my scenario I have 3 or more multi-page tiff images which I need to merge into a single tiff image. Below is the the code I have tried. It merges in to a single tiff image but only with first page of all tiff images. private static void MergeTiff(string[] sourceFiles) { string[] sa = sourceFiles; //get the codec for tiff files ImageCodecInfo info = null; foreach (ImageCodecInfo ice in ImageCodecInfo.GetImageEncoders()) if (ice.MimeType == "image/tiff") info = ice; //use the save encoder

Showing TIFF images in Java

烈酒焚心 提交于 2019-12-07 12:27:32
问题 Someone can tell me how to load a multipage TIFF image in Java and show it in a JScrollPane? Which class can I use? 回答1: AFAIK, you can't do that with Java's standard API. JAI can however: import java.io.File; import java.io.IOException; import java.awt.Frame; import java.awt.image.RenderedImage; import javax.media.jai.widget.ScrollingImagePanel; import javax.media.jai.NullOpImage; import javax.media.jai.OpImage; import com.sun.media.jai.codec.SeekableStream; import com.sun.media.jai.codec

The are any CMYK graphics library?

狂风中的少年 提交于 2019-12-07 12:19:26
问题 I'm looking for graphics library with CMYK support(JPG or TIF). I have to read one big image file and one small, then write second on first. Output have to be also CMYK(without any CMYK->RGB conversion). There are any? (C#/C++/Java or somthing else) 回答1: (Disclaimer, I work for Atalasoft) Atalasoft dotImage will read and write images in as CMYK as well as perform overlay operations in CMYK space. the code you would need to do this is: public void OverlayCMYKOnCMYK(Stream bottomStm, Stream

Convert a bitmap image to an uncompressed tif image in Java

自闭症网瘾萝莉.ら 提交于 2019-12-07 09:04:34
问题 I'm trying to convert a bitmap image into an uncompressed tif file for use with the Tesseract OCR engine. I can use this method to produce a compressed tif file... final BufferedImage bmp = ImageIO.read(new File("input.bmp")); ImageIO.write(bmp, "jpg", new File("output.tif")); This produces an empty tif file when the "jpg" is changed to tif as these files are dealt with in Java Advanced Imaging (JAI). How can I create an uncompressed tif image? Should I decompress the tif image produced from

MATLAB write multipage tiff exponentially slow

£可爱£侵袭症+ 提交于 2019-12-07 07:30:38
问题 I am trying to write a single multipage tiff file which is 128 pixels x 128 pixels x 122000 frames of 16-bit unsigned integers. ImageJ or a short Python script can do this in less than one minute on a fast machine. On the same machine, MATLAB would likely take days to do so using any method I have tried. Here is what I have tried so far: Use imwrite to write IMG to test.tif (recommended by MATLAB documentation) tic numframes=size(IMG,3); divider=10^(floor(log10(numframes))-1); imwrite(IMG(:,: