2 #------------------------------------------------------------------------------
3 # riff: file(1) magic for RIFF format
6 # http://www.seanet.com/users/matts/riffmci/riffmci.htm
10 # http://www.ora.com/centers/gff/formats/micriff/index.htm
14 # http://www.jtauber.com/music/encoding/niff/spec/
16 0 string RIFF RIFF (little-endian) data
18 >8 string PAL \b, palette
19 >>16 leshort x \b, version %d
20 >>18 leshort x \b, %d entries
21 # RIFF Device Independent Bitmap format
22 >8 string RDIB \b, device-independent bitmap
24 >>>30 leshort 12 \b, OS/2 1.x format
25 >>>>34 leshort x \b, %d x
27 >>>30 leshort 64 \b, OS/2 2.x format
28 >>>>34 leshort x \b, %d x
30 >>>30 leshort 40 \b, Windows 3.x format
31 >>>>34 lelong x \b, %d x
35 >8 string RMID \b, MIDI
36 # RIFF Multimedia Movie File format
37 >8 string RMMP \b, multimedia movie
38 # Microsoft WAVE format (*.wav)
39 >8 string WAVE \b, WAVE audio
40 >>20 leshort 1 \b, Microsoft PCM
41 >>>34 leshort >0 \b, %d bit
42 >>22 leshort =1 \b, mono
43 >>22 leshort =2 \b, stereo
44 >>22 leshort >2 \b, %d channels
46 # AVI == Audio Video Interleave
47 >8 string AVI\ \b, AVI
48 # Animated Cursor format
49 >8 string ACON \b, animated cursor
52 # XXX - some of the below may only appear in little-endian form.
54 # Also "MV93" appears to be for one form of Macromedia Director
55 # files, and "GDMF" appears to be another multimedia format.
57 0 string RIFX RIFF (big-endian) data
59 >8 string PAL \b, palette
60 >>16 beshort x \b, version %d
61 >>18 beshort x \b, %d entries
62 # RIFF Device Independent Bitmap format
63 >8 string RDIB \b, device-independent bitmap
65 >>>30 beshort 12 \b, OS/2 1.x format
66 >>>>34 beshort x \b, %d x
68 >>>30 beshort 64 \b, OS/2 2.x format
69 >>>>34 beshort x \b, %d x
71 >>>30 beshort 40 \b, Windows 3.x format
72 >>>>34 belong x \b, %d x
76 >8 string RMID \b, MIDI
77 # RIFF Multimedia Movie File format
78 >8 string RMMP \b, multimedia movie
79 # Microsoft WAVE format (*.wav)
80 >8 string WAVE \b, WAVE audio
81 >>20 leshort 1 \b, Microsoft PCM
82 >>>34 leshort >0 \b, %d bit
83 >>22 beshort =1 \b, mono
84 >>22 beshort =2 \b, stereo
85 >>22 beshort >2 \b, %d channels
87 # AVI == Audio Video Interleave
88 >8 string AVI\ \b, AVI
89 # Animated Cursor format
90 >8 string ACON \b, animated cursor
91 # Notation Interchange File Format (big-endian only)
92 >8 string NIFF \b, Notation Interchange File Format