I'm SO close (I think!) to being done with "Resize (Less)" after a grueling run. After running check50, I'm a bit kerfuffled. Hexadecimal form of output file seems correct, as do the values of and bfsize and imagesize (I added in printf to check these values). However, check50 is telling me bfsize is wrong, and I'm also getting pixel colors that don't match hexadecimal. More explanation below:
My code (see images attached) compiles. I added in printf for all the header values for clarity. When running for scale factor of "2" with infile "small.bmp" and outfile "large22.bmp" (./resize 2 small.bmp large22.bmp), I get the following error message from check50: "expected 0xae not 0x5a for bfsize." However. My printf for bfSize(outfile) yields 174 (decimal form of 0xae). Also, when I open large22.bmp as hexadecimal, everything looks like a 2x enlarged version of small.bmp, with 2 bytes of padding. HOWEVER. When I open up the .bmp of large22, I see blue and black pixels. This doesn't seem to match up with the hexadecimal form of the file.
Note: I'm having trouble with debug50. When I set breakpoint at line 8, and start going through, it jumps to end as soon as I get to the first "return 1". I try setting breakpoints after (say, line 99), but then it doesn't run at all.
THank you for any insight. I hope my question helps others struggling with the same problems!
1.)