List Info

Thread: Re: Oddity when handling < 8bpp images.




Re: Oddity when handling < 8bpp images.
country flaguser name
United States
2007-03-04 23:10:32
At 04:54 AM 3/5/2007 +0000, mal content wrote:
>else to host the file.

OK, got it.  It's too much for me to assimilate right now
though.
You may be on the right track about png_set_expand(), since
you are
trying to read 1-bit pixels.

Glenn

------------------------------------------------------------
-------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the
chance to share your
opinions on IT & business topics through brief
surveys-and earn cash
http://www.techsay.com/default.
php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
png-mng-implement mailing list
png-mng-implementlists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/png-m
ng-implement

Re: Oddity when handling < 8bpp images.
country flaguser name
United States
2007-03-05 07:08:40
Using "long" pos, len, and r to point into a char*
array looks suspicious:

in png-pixels.c
void pixels()
{
  unsigned long len;
  unsigned long pos;
  long r;

  len = png.len;
  pos = 0;
  for (;;) {
    r = write(1, png.pixels + pos, len);
[...]

I suppose "len" is 1 in your example with 8-bit
(1-byte) scanlines.
I didn't find in your code where you unpack the 8-bit pixels
into
8 one-bit samples for printing, nor where you print the
pixel
values.


------------------------------------------------------------
-------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the
chance to share your
opinions on IT & business topics through brief
surveys-and earn cash
http://www.techsay.com/default.
php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
png-mng-implement mailing list
png-mng-implementlists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/png-m
ng-implement

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )