pngread does not read 12bit gray images

Søren Hauberg soren at hauberg.org
Thu Jul 10 12:51:42 CDT 2008


tor, 10 07 2008 kl. 19:23 +0200, skrev Bengt-Arne Fjellner:
> On 2008-07-05 7:41 PM, "de Almeida, Valmor F." <dealmeidav at ornl.gov> wrote:
> > I am using imread() to read 12-bit png images. The result of
> > 
> > Y = imread("foo.png");
> > class(I);
> > 
> > is uint16. However the max and min values of Y are not correct. I
> > tracked the problem down to this section of pngread.cc in the
> > octave-forge package image-1.06
>
> I'm working on one to:
> Download and try:
> http://pinus.tt.ltu.se/~baf/pngread.cc
> The test for endianness of the machine should be done during compilation but
> I haven't figured out how.
> 
> And if it seems to work just include it in the distro.

Can any of you 16 bit people check that the __magick_read__ function can
read your images? I don't have any 16 bit images available at the
moment, so I can't check this...

Søren



More information about the Help-octave mailing list