Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-09 Thread Marco van de Voort
In our previous episode, Mattias Gaertner said: > > Are there still no ways around the 64-bit storage format? I thought > > TLazintfImage was meant to be a step in that direction? > > There are various image formats (TLazintfImage, > TFPCompactImgRGBA8Bit, TFPCompactImgGrayAlpha8Bit, ..), so memor

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-09 Thread Sven Barth
Am 09.12.2016 10:05 schrieb "Graeme Geldenhuys" < mailingli...@geldenhuys.co.uk>: > The most widely used image editing software for X11 based > systems, The GIMP, doesn't even support 16bit color channel images. If I remember correctly the next major version of The GIMP is supposed to support 16-b

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-09 Thread Michael Van Canneyt
On Fri, 9 Dec 2016, Marco van de Voort wrote: In our previous episode, Michael Van Canneyt said: Why FPImage uses 64bit per pixel is beyond me! The original author of FPImage clearly thought he/she saw something cool in that, but 99.9% of the time *nobody* needs that. It's causing more gr

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-09 Thread Mattias Gaertner
On Fri, 9 Dec 2016 12:39:54 +0100 (CET) mar...@stack.nl (Marco van de Voort) wrote: >[...] > Are there still no ways around the 64-bit storage format? I thought > TLazintfImage was meant to be a step in that direction? There are various image formats (TLazintfImage, TFPCompactImgRGBA8Bit, TFPComp

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-09 Thread Marco van de Voort
In our previous episode, Michael Van Canneyt said: > >> Why FPImage uses 64bit per pixel is beyond me! The original author of > >> FPImage clearly thought he/she saw something cool in that, but 99.9% > >> of the time *nobody* needs that. It's causing more grief (and code to do > >> conversions)

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-09 Thread Graeme Geldenhuys
On 2016-12-09 09:04, Graeme Geldenhuys wrote: > What I'm > saying is that FPImage uses 16bit color channels, but literally only a > hand full (and I mean less than 5) of image editing programs support > 16bit color channel images. Impressively, the now discontinued cross-platform image editor Pix

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-09 Thread Graeme Geldenhuys
On 2016-12-09 09:14, Michael Van Canneyt wrote: > > The desire was to be able to support all possible channels when reading a > file. > That means 16bit. OK, I can see the logic behind that. Time for another coffee, to kick my brain into gear. ;-) Regards, Graeme _

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-09 Thread Michael Van Canneyt
On Fri, 9 Dec 2016, Graeme Geldenhuys wrote: On 2016-12-09 07:28, Michael Van Canneyt wrote: The 64bit is the maximum limit. I doubt the 99.9%. Image editing require more than 8bit per channel since decades. And that is why we decided to use 64-bit. Sorry, maybe I'm getting confused wi

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-09 Thread Graeme Geldenhuys
On 2016-12-09 07:28, Michael Van Canneyt wrote: >> > The 64bit is the maximum limit. I doubt the 99.9%. Image editing >> > require more than 8bit per channel since decades. > And that is why we decided to use 64-bit. Sorry, maybe I'm getting confused with the meaning of all than. What I'm sayi

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-08 Thread Michael Van Canneyt
On Thu, 8 Dec 2016, Mattias Gaertner wrote: On Thu, 8 Dec 2016 14:09:53 + Graeme Geldenhuys wrote: On 2016-12-08 14:01, Mattias Gaertner wrote: That would be a 64bit per pixel image, wasting a lot of memory. Why FPImage uses 64bit per pixel is beyond me! The original author of FPImag

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-08 Thread Graeme Geldenhuys
On 2016-12-08 16:24, Mattias Gaertner wrote: > Even rocket scientists can't read minds. :-) > Will you create the patch or should I? I'll create a patch. Regards, Graeme ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.fre

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-08 Thread Mattias Gaertner
On Thu, 8 Dec 2016 15:15:55 + Graeme Geldenhuys wrote: > On 2016-12-08 14:22, Mattias Gaertner wrote: >[...] > It's not rocket science. ;-) Even rocket scientists can't read minds. Will you create the patch or should I? Mattias ___ fpc-pascal mai

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-08 Thread Graeme Geldenhuys
On 2016-12-08 14:22, Mattias Gaertner wrote: >> > This might be a good solution. Some ready-made event handlers. > Any idea how that should look like? In the TFPReaderTiff class, define public methods (possibly marked as virtual) as follows Here's one example: procedure TFPReaderTiff.CreateC

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-08 Thread Mattias Gaertner
On Thu, 8 Dec 2016 14:09:53 + Graeme Geldenhuys wrote: > On 2016-12-08 14:01, Mattias Gaertner wrote: > > That would be a 64bit per pixel image, wasting a lot of memory. > > Why FPImage uses 64bit per pixel is beyond me! The original author of > FPImage clearly thought he/she saw something

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-08 Thread Graeme Geldenhuys
On 2016-12-08 14:01, Mattias Gaertner wrote: > That would be a 64bit per pixel image, wasting a lot of memory. Why FPImage uses 64bit per pixel is beyond me! The original author of FPImage clearly thought he/she saw something cool in that, but 99.9% of the time *nobody* needs that. It's causin

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-08 Thread Mattias Gaertner
On Thu, 8 Dec 2016 12:12:27 + Graeme Geldenhuys wrote: > On 2016-12-07 17:47, Mattias Gaertner wrote: > >> > t := TFPReaderTiff.Create; > > t.OnCreateImage:=@... > > > > Thanks that solved it. > > But why can't TFPReaderTiff do that for us, or at least have a default > implementation

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-08 Thread Graeme Geldenhuys
On 2016-12-07 17:47, Mattias Gaertner wrote: >> > t := TFPReaderTiff.Create; > t.OnCreateImage:=@... > Thanks that solved it. But why can't TFPReaderTiff do that for us, or at least have a default implementation (override'able by developers if really needed). Regards, Graeme -- fpGUI Tool

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-07 Thread Mattias Gaertner
On Wed, 7 Dec 2016 15:34:13 + Graeme Geldenhuys wrote: >[...] > fs := TFileStream.Create('/tmp/multipage_tiff_example.tif', fmOpenRead); > t := TFPReaderTiff.Create; t.OnCreateImage:=@... > t.LoadFromStream(fs, true); Mattias ___ fpc-pascal

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-07 Thread Graeme Geldenhuys
On 2016-12-07 11:43, Mattias Gaertner wrote: > TFPReaderTiff and TFPWriterTiff support multiple IFD using multiple > TFPCustomImage. I just tried with FPC 3.1.1 and it fails. The initial loading of the TIFF file works, it correctly tells me there are 10 images (confirmed with the Unix 'identify'

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-07 Thread Graeme Geldenhuys
On 2016-12-07 11:43, Mattias Gaertner wrote: > Do you mean multiple IFD? Yes. > TFPReaderTiff and TFPWriterTiff support multiple IFD using multiple > TFPCustomImage. Perfect, many thanks for the confirmation. Regards, Graeme ___ fpc-pascal maillis

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-07 Thread Mattias Gaertner
On Wed, 7 Dec 2016 09:58:13 + Graeme Geldenhuys wrote: > Hi, > > Does anybody know if FPImage supports multi-page TIFF's? Reading or > Writing. Do you mean multiple IFD? TFPReaderTiff and TFPWriterTiff support multiple IFD using multiple TFPCustomImage. Mattias ___

Re: [fpc-pascal] FPImage and mult-page TIFF support

2016-12-07 Thread Žilvinas Ledas
Hi, when I needed to read multi-page tiff files some years ago, I used TLazReaderTiff. I don't remember if multi-page code worked out of the box, but I had to extend tiff reader to handle some more exotic format that came from some imaging software (I think I didn't contribute the changes bac

[fpc-pascal] FPImage and mult-page TIFF support

2016-12-07 Thread Graeme Geldenhuys
Hi, Does anybody know if FPImage supports multi-page TIFF's? Reading or Writing. Regards, Graeme -- fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://fpgui.sourceforge.net/ My public PGP key: http://tinyurl.com/graeme-pgp ___