MDL is the file format used by Microsoft Flight Simulator to store visual model data. It uses the .mdl file extension.
The MDL format can be broken down into 2 main types; the DLL-based type and the RIFF-based type.
The DLL-based format was used in legacy versions of MSFS, before Flight Simulator 2002. It was actually written as a windows DLL library, and simply used the .mdl extension. It is believed to have been coded in Assembly language. More information may be found at Legacy MDL Format.
The RIFF-based format MDL was introduced in FS2002, and has been updated in every subsequent version of FS. It can be broken into different main versions:
- MDL8 was introduced with FS2002 and was used in aircraft models. It used a simple architecture, containing mostly BGL opcodes wrapped around a simple RIFF shell.
- MDL9 was introduced with FS2004. FS2004 is especially interesting because the scenery models used the new MDL9 format, but the aircraft models still used the MDL8 format. The MDL9 format introduced some new fourCC tags, and was better organized, but still relied heavily upon BGL codes to actually draw the model.
- MDLX was introduced with FSX. It is a complete departure away from the old BGL drawing codes and relies solely on data structures defined within 57 different fourCC tags.
- PV20 was introduced with Prepar3D v2 and was an upgrade to the MDLX format. The main differences are that indices can be stored as integer instead of shorts, allowing more vertices per model part and that additional material attributes were introduced.
- PV44 was introduced with Prepar3D v4.4 and was a further upgrade of the MDLX format. The main difference is the addition of PBR materials.
- GLTF was introduced with MSFS. It uses a similar RIFF-based structure as FSX, but with different sections to store the glTF data of models.