GreycLab / CImg

The CImg Library is a small and open-source C++ toolkit for image processing
http://cimg.eu
Other
1.48k stars 282 forks source link

Rendering a 3D object with gouraud shading on a RBGA has broken alpha values for the shading #324

Open MacDue opened 3 years ago

MacDue commented 3 years ago

If you attempt to render any 3D object onto an RGBA image (with a transparent background -- initially the image is all zeros), any shaded areas of the object will be transparent in the output image (rather than just being shaded with a dark colour -- and a transparent background where the object is not).

There does not seem to be any way to work around this (especially if you render the object with an opacity < 1).