Note: You must be registered in order to post a reply. To register, click here. Registration is FREE!
T O P I C R E V I E W
charlie1972
Posted - Jun 02 2012 : 17:38:07 Hello to all of You, I'd like ask some help. I have stored TIFF data in an Oracle BLOB field. I have to print this picture via Delphi Report Builder created by Digital-Metamorph. This reporting component does not handle TIFF, but it has a image component with loadfromstream attribute and has canvas. I have saved the TIFF blob data into a STREAM variable, now I'd like to make a convertion into JPEG stream with this ImageEn package. But I have no idea how I have to start it. Please somebody could help me.
Thx,
Charlie
2 L A T E S T R E P L I E S (Newest First)
charlie1972
Posted - Jun 13 2012 : 03:01:48 Fabrizio!
You are the greatest ever. I'm very grateful for Your help. It is working perfectly.
Thx
Charlie
fab
Posted - Jun 03 2012 : 00:47:30 Hello, if TIFF contains a single page you could write:
with TImageEnView.Create(nil) do
try
IO.LoadFromStreamTIFF( inStream ); // is inStream at position 0? Otherwise you need inStream.Position := 0
IO.SaveToStreamJpeg( outStream );
finally
Free();
end;
// now reset outStream position and read it in your image component
outStream.Position := 0;
...etc...
That code also assumes the original TIFF is 24 bit RGB, otherwise a color conversion is necessary.