Should I match pdc's expected formats as closely as possible?

When inspecting the media files in my Source folder, I wonder whether I should spend the effort to export all those files exactly to the standards mentioned in the docs, while pdc handles conversion of 24-bit color images (containing black and white or almost-white pixels) to 1-bit just fine.

For example:

  • 24-bit color images containing only black and white pixels without transparency
  • stereo audio where both channels have equal content
  • mono audio at 48 khz

Should I convert these to 1-bit graphics, 44.1 khz mono adpcm audio etc.?

All of this seems to work fine in the simulator without conversion

Q: You should. Are you lazy or something? Just do it already.
A: Well, these formats are very old / not widely supported by software. Krita, for example can't work with anything lower than 8-bit per channel. So it slows down my workflow when doing an extra conversion pass in some other app.

The way I deal with this is currently is making notes about what could be optimized and doing that as a last step before testing and publishing the game; not during development. Is this the right approach?

1 Like

You don't need to manually convert those. PDC will do it fine.

If you think you can do a better job than PDC with the audio (eg adpcm-xq tool) youbcould do that. Best place would be in a make file or elsewhere in your build process.

For example, I generate new sprite sheets for any changed 3D models in my make file/build process.

We need to be clearer in the docs about what the compiler accepts and what it produces. For images it just averages the R/G/B values together and checks if it's above 0x7f to decide if it's black or white. (There's also a new feature, can't remember if it's been released yet, where green pixels are made transparent if the image doesn't have normal transparency.) For audio we keep the input format and do sample rate conversion at runtime; In the 48k case you'll get better quality if you convert it to 44.1k ahead of time.. Maybe pdc should give a warning in that case? I'll file a feature request to have it check for stereo files that are actually mono and save the data that way, saving a bunch of disk space.

One thing I've wanted to add to pdc for a long time is a (optional) command file that tells the compiler what to do, like ignore folders, or generate image tables for rotated/scaled images. Automatic rate conversion would be a useful feature useful here.

1 Like