Closed cccccz closed 6 months ago
In rgba_to_rgb
, you just drop the alpha channel when copying to the output buffer. To find out what's going on here, try using a debugger to see what values you copy to the output buffer, or print out each RGBA pixel and compare it with your ppm file read as a text file.
In
rgba_to_rgb
, you just drop the alpha channel when copying to the output buffer. To find out what's going on here, try using a debugger to see what values you copy to the output buffer, or print out each RGBA pixel and compare it with your ppm file read as a text file.
Thank you for the reply! I see that in my ppm file, the blue value is always 0, i think that's where the problem came from.
This is my output for rgb.ppm. It looks too yellow to me but I have no clue how to fix it...