Haiku's Translation Kit: Roster-Based Media Conversion Between Applications
How translators advertise formats and let applications decode or encode images and other data without bundling every codec.
Haiku’s Translation Kit provides a common interface for converting supported data formats. Translator add-ons declare input/output types and capabilities; applications ask the translation roster to identify data and perform conversion through streams.
This separates a viewer or editor from every individual file parser. Installing a translator can extend multiple applications at once. The boundary also demands care: malformed media reaches shared parser code, so translators need bounds checks, fuzzing, and conservative metadata handling.
Applications should preserve the original when conversion is lossy, expose format choices rather than guessing, and report which translator failed. A successful decode proves compatibility, not archival equivalence between formats.