ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 TIETIFFHandler Compression

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

View 
UserName:
Password:
Format  Bold Italicized Underline  Align Left Centered Align Right  Horizontal Rule  Insert Hyperlink   Browse for an image to attach to your post Browse for a zip to attach to your post Insert Code  Insert Quote Insert List
   
Message 

 

Emoji
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Black Eye [B)]
Frown [:(] Shocked [:0] Angry [:(!] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
Elemental Posted - Apr 22 2014 : 09:36:01
Is there a way to specify the TIFF compression used with TIETIFFHandler.WriteFile? I, for one, would like to specify ioTIFF_G4FAX as the TIOTIFFCompression type used. I am writing the file from a series of TIEBitmaps that get converted to Streams and then appended to the handler.
7   L A T E S T    R E P L I E S    (Newest First)
xequte Posted - May 04 2014 : 19:33:58
Oops, neglected to mention another non visual option.

Attach an IEBitmap to a TImageEnIO, and then call:

http://www.imageen.com/help/TImageEnIO.InsertToFileTIFF.html

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
xequte Posted - Apr 25 2014 : 17:13:32
Hi

TIETiffHandler is not suitable for your requirements because it does not handle custom compression.

So you could use a hidden TImageEnMView. You are unlikely to have memory issues unless your images are huge.

Another option is to code your own code only solution. Have a look at the source of TImageEnMIO.SaveToFileTIFF and TImageEnMIO.SaveToStreamTIFF. You need only replace the calls to retrieve the Bitmap and params from the TImageEnMView with your own source.



Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
w2m Posted - Apr 22 2014 : 12:06:59
I am sure memory requirements would increase....

William Miller
Elemental Posted - Apr 22 2014 : 11:36:18
I'll think on it some more, because it seems that your solution might take up a whole lot of memory, and some of these documents are quite large. It seems like having two TImageEnMViews, with most of the same images, would take up twice as much space in RAM.
w2m Posted - Apr 22 2014 : 10:49:32
I suppose you could have a "hidden" not visible TImageEnMView and then copy the images from the tiff handler to the hidden TImageEnMView or a TIEMIO component and then use the TImageEnMView or TImageEnMIO to save the file with the the compression parameter.

William Miller
Adirondack Software & Graphics
Email: w2m@frontiernet.net
EBook: http://www.imageen.com/ebook/
Apprehend: http://www.frontiernet.net/~w2m/index.html
Custom ImageEn Development
Elemental Posted - Apr 22 2014 : 09:58:21
I can't use TImageEnMView's MIO property in my project. As it stands, the TImageEnMView on my form shows the annotated pages from TImageEnVect. This is great for printing, exporting as various file types (including TIFF), and so forth. But my project requires that the TIFF be saved without annotations; annotations are saved in a database and loaded on demand. Therefore, I have a TIETIFFHandler do the job for me. I kinda wish that TImageEnMView and TIETIFFHandler were better coupled than just through streams.
w2m Posted - Apr 22 2014 : 09:54:25
I do not think the TIFHandler allows you to set the compression. I suspect you need to use TImageEnMIO instead:

ImageEnMView1.MIO.Params[ImageEnMView1.SelectedImage].TIFF_Compression := ioTIFF_G4FAX;
ImageEnMView1.MIO.SaveToFile(AFilename);

William Miller
Adirondack Software & Graphics
Email: w2m@frontiernet.net
EBook: http://www.imageen.com/ebook/
Apprehend: http://www.frontiernet.net/~w2m/index.html
Custom ImageEn Development