[File] [PATCH] Magdir/riff Microsoft Flight Simulator *.MDL described only generic
Jörg Jenderek (GMX)
joerg.jen.der.ek at gmx.net
Sun Aug 6 18:35:53 UTC 2023
Hello,
some weeks ago i handled some RIFF based video files. When i run
file command version 5.45 on more RIFF based samples with MDL file name
suffix i get an output like:
XL5.mdl: RIFF (little-endian) data
tb1.mdl: RIFF (little-endian) data
With --extension option only ??? is displayed for MDL samples.
Furthermore with option -i for inspected MDL samples only generic
application/octet-stream is shown.
For comparison reason i also run the file format identification
utility DROID ( See https://sourceforge.net/projects/droid/). This
does not recognize the the MDL examples.
For comparison reason i run the file format identification utility
TrID ( See https://mark0.net/soft-trid-e.html). This identifies also
all my MDL examples with low priority as "Generic RIFF container" by
riff.trid.xml. The examples are described with high rate as "Microsoft
Flight Simulator 3D model (generic)" by mdl-fs-gen.trid.xml (See
appended trid-v-mdl.txt.gz).
This tool list the used file name extension and with -v option the
related URL pointing to used software company. Luckily with shown
information i found page about "MDL file format". That informations are
expressed by comment lines inside Magdir/riff like:
# URL: https://en.wikipedia.org/wiki/Microsoft_Flight_Simulator
# Ref.: https://www.fsdeveloper.com/wiki/index.php
# ?title=MDL_file_format_(FSX)
# http://mark0.net/download/triddefs_xml.7z
# defs/m/mdl-fs-gen.trid.xml
All detected MDL samples are at least general described by Magdir/riff
with line like:
0 string RIFF RIFF (little-endian) data
For other RIFF samples the sub classification is done by considering 4
byte string at offset 8. According to references this is 3 byte MDL
string. So this is now done by additional lines inside Magdir/riff like:
>8 string MDL
>>12 string MDLH \b, Microsoft Flight Simulator 3D model
!:mime application/x-ms-mdl
!:ext mdl
Instead of generic mime type application/octet-stream or
application/x-riff i show an user defined one.
After applying the above mentioned modifications by patch
file-5.45-riff-mdl.diff then all my inspected Microsoft Flight Simulator
examples are now described with more details. This now looks like:
XL5.mdl: RIFF (little-endian) data, Microsoft Flight Simulator 3D model
tb1.mdl: RIFF (little-endian) data, Microsoft Flight Simulator 3D model
I hope my diff file can be applied in future version of file
utility.
Unfortunately the MDL file name suffix is also used for other file formats.
With best wishes,
Jörg Jenderek
--
Jörg Jenderek
-------------- next part --------------
A non-text attachment was scrubbed...
Name: trid-v-mdl.txt.gz
Type: application/x-gzip
Size: 561 bytes
Desc: not available
URL: <https://mailman.astron.com/pipermail/file/attachments/20230806/2c9c77eb/attachment.bin>
-------------- next part --------------
--- file-5.45/magic/Magdir/riff.old 2022-08-16 13:15:19.000000000 +0200
+++ file-5.45/magic/Magdir/riff 2023-08-06 20:29:02.666751300 +0200
@@ -354,6 +354,17 @@
>>0x31 search/256 inst by
# probably manufacture name like: "Unspecified Company" "NVidia Corporation"
>>>&0x24 string x "%s"
+# From: Joerg Jenderek
+# URL: https://en.wikipedia.org/wiki/Microsoft_Flight_Simulator
+# Reference: https://www.fsdeveloper.com/wiki/index.php?title=MDL_file_format_(FSX)
+# http://mark0.net/download/triddefs_xml.7z/defs/m/mdl-fs-gen.trid.xml
+# Note: called "Microsoft Flight Simulator 3D model (generic)" by TrID
+>8 string MDL
+>>12 string MDLH \b, Microsoft Flight Simulator 3D model
+#!:mime application/x-riff
+!:mime application/x-ms-mdl
+!:ext mdl
+#>>>8 string MDL8 \b, version 8?
# AVI == Audio Video Interleave
# Reference: http://fileformats.archiveteam.org/wiki/AVI
>8 string AVI\040 \b, AVI
-------------- next part --------------
A non-text attachment was scrubbed...
Name: file-5.45-riff-mdl.diff.sig
Type: application/octet-stream
Size: 733 bytes
Desc: not available
URL: <https://mailman.astron.com/pipermail/file/attachments/20230806/2c9c77eb/attachment.obj>
More information about the File
mailing list