"QuasiChameleon" <Kevin.Crosby@bigfoot.com> wrote in message
news:1125432400.674942.62970@g14g2000cwa.googlegro ups.com...[color=blue]
> Hi,
>
> I'm trying to create a grayscale image class that reads and writes
> grayscale Targa format. This works well with smaller images, but
> corrupts larger images and creates a "Segmentation fault (core dumped)"
> error. I am at a loss as to why this works only part of the time.
>
> I hope it's proper etiquette to post the code below (3 files).
>
> Can someone please show me what's wrong with the following code? I
> adapted this from an old matrix class of mine.
>
> Thanks in advance!
>
> Kevin Crosby
>
>
> Bare bones code below:[/color]
[snip]
I never tangled with Targa but I have written interfaces for reading and
writing jpeg, tiff, etc. My advice: don't even dream of writing your own
code for reading a graphic file format. These things tend to be complicated
and writing the code is almost sure to be time consuming. I just typed
"targa library" in Google and got plenty of useful looking hits.
--
Cy
http://home.rochester.rr.com/cyhome/