Friday, May 12, 2006

PNG format and alpha

850 is turning out similar to most feature-based X-Plane releases - like a tropical storm picking up speed features keep getting sucked in, creating more chaos in its core. I thought I would be working on airports and lighting only for 850, but there's already a number of other things floating around in the release. The end result should be better visuals.

A quick note on usage of PNG: the formats of X-Plane and PNG images are not quite the same.
  • To provide a non-alpha image in X-Plane, use an RGB or grayscale PNG.
  • To provide an image with alpha in X-Plane, use an RGB or grayscale PNG with an alpha channel.
  • To provide an alpha mask in X-Plane, use a grayscale PNG.
This last case is the strange one: as far as I can tell PNG does not allow an alpha-only image. So when X-Plane needs an alpha mask (a 1-channel image) it uses a grayscale (1-channel image).

Also please note tht you can use a color or grayscale PNG for a color texture, but internally X-Plane always operates in RGB, so you don't save any VRAM by reducing your PNGs to grayscale. You might save some space on disk.

No comments: