From a87ad994105f83702d0b9ea040e5bc84b9c5f1d5 Mon Sep 17 00:00:00 2001 From: 4DBug Date: Mon, 2 Nov 2026 21:12:36 -0600 Subject: [PATCH 1/2] perf (LuaJIT): stop cross-codec trace pollution in long mixed processes; bench.sh mixed - compat math.clamp is vararg: LuaJIT never starts a root trace at a vararg function but still inlines it. The plain shim, called from interpreted code, collected aborted root traces until it was blacklisted, after which every trace through it aborted: in one process, png (or anything earlier) left jpeg / webp / tiff / ImageOps 2-10x slower. - Dct.fdctQuantize: branch-free quantiser and a divisor table (q * 8) from Jpeg.Encode; the sign branch among the column pass's live values made LuaJIT retry side traces it could not compile (register coalescing) forever. Also faster in luau -O2 (~5%) and native (~10%). Outputs unchanged. - tools/bench_mixed.luau + bash tools/bench.sh mixed: core, audio, video, image in one LuaJIT process against the per-codec benches, marking lines more than 1.3x slower mixed. --- build/Rosetta.luau | 39 +- build/Rosetta.luau.linemap.json | 852 +++++++++++----------- build/Rosetta.rbxm | Bin 3073887 -> 3074009 bytes build/Rosetta.rbxmx | 39 +- build/rosetta.lua | 44 +- build/rosetta.lua.linemap.json | 380 +++++----- compat/luajit.lua | 7 +- src/Rosetta/codecs/image/Dct/init.luau | 33 +- src/Rosetta/codecs/image/Jpeg/Encode.luau | 6 +- tests/codecs/dct.luau | 13 +- tools/bench.sh | 14 +- tools/bench_mixed.luau | 85 +++ 12 files changed, 802 insertions(+), 710 deletions(-) create mode 100644 tools/bench_mixed.luau diff --git a/build/Rosetta.luau b/build/Rosetta.luau index 30d5dab..ada131d 100644 --- a/build/Rosetta.luau +++ b/build/Rosetta.luau @@ -71201,7 +71201,7 @@ __FILES["codecs/image/Dct"] = function() -- libjpeg's islow (jidctint.c / jfdctint.c), the reduced IDCTs (jidctred.c) and jcdctmgr.c's rounding quantiser, bit-exact -- with libjpeg-turbo. From jpeg-luau 1.0 (same author); IJG code: licenses/libjpeg-turbo-LICENSE.md. local readi16, readu16, writeu16, writeu32, readu8, writei16 = buffer.readi16, buffer.readu16, buffer.writeu16, buffer.writeu32, buffer.readu8, buffer.writei16 -local clamp = math.clamp +local clamp, abs, sign = math.clamp, math.abs, math.sign local Dct = {} @@ -71580,18 +71580,13 @@ end local fw = table.create(64, 0) -local function quant(coef: buffer, off: number, div: buffer, v: number, i: number) - local qv = readu16(div, i * 2) * 8 - local h = qv // 2 - if v < 0 then - writei16(coef, off + i * 2, -((h - v) // qv)) - else - writei16(coef, off + i * 2, (v + h) // qv) - end +-- (|v| + q * 4) // (q * 8) with v's sign, branch-free (a sign branch here gave LuaJIT side traces it could not compile) +local function quant(coef: buffer, off: number, qv: number, v: number, i: number) + writei16(coef, off + i * 2, (abs(v) + qv / 2) // qv * sign(v)) end --- quantised as jcdctmgr.c: (|v| + q * 4) // (q * 8) with the sign restored -function Dct.fdctQuantize(src: buffer, stride: number, x: number, y: number, w: number, h: number, div: buffer, coef: buffer, off: number) +-- quantised as jcdctmgr.c: (|v| + q * 4) // (q * 8) with the sign restored; div[i + 1] = q * 8 for natural index i +function Dct.fdctQuantize(src: buffer, stride: number, x: number, y: number, w: number, h: number, div: { number }, coef: buffer, off: number) local lastX, lastY = w - 1, h - 1 for r = 0, 7 do local row = math.min(y + r, lastY) * stride @@ -71680,14 +71675,14 @@ function Dct.fdctQuantize(src: buffer, stride: number, x: number, y: number, w: local o3 = (tmp6 + z2 + z3 + 16384) // 32768 local o1 = (tmp7 + z1 + z4 + 16384) // 32768 local cc = c - 1 - quant(coef, off, div, o0, cc) - quant(coef, off, div, o1, cc + 8) - quant(coef, off, div, o2, cc + 16) - quant(coef, off, div, o3, cc + 24) - quant(coef, off, div, o4, cc + 32) - quant(coef, off, div, o5, cc + 40) - quant(coef, off, div, o6, cc + 48) - quant(coef, off, div, o7, cc + 56) + quant(coef, off, div[c], o0, cc) + quant(coef, off, div[c + 8], o1, cc + 8) + quant(coef, off, div[c + 16], o2, cc + 16) + quant(coef, off, div[c + 24], o3, cc + 24) + quant(coef, off, div[c + 32], o4, cc + 32) + quant(coef, off, div[c + 40], o5, cc + 40) + quant(coef, off, div[c + 48], o6, cc + 48) + quant(coef, off, div[c + 56], o7, cc + 56) end end @@ -74550,11 +74545,11 @@ function Encode.run(px: buffer, w: number, h: number, bpp: number, o: Options): local qt = { Tables.quant(Tables.LUMA, o.quality), Tables.quant(Tables.CHROMA, o.quality) } local qdiv = {} for t = 1, 2 do - local b = buffer.create(128) + local d = table.create(64, 0) for i = 1, 64 do - writeu16(b, (i - 1) * 2, qt[t][i]) + d[i] = qt[t][i] * 8 end - qdiv[t] = b + qdiv[t] = d end local comps: { Comp } = {} diff --git a/build/Rosetta.luau.linemap.json b/build/Rosetta.luau.linemap.json index 740e512..c5b85e2 100644 --- a/build/Rosetta.luau.linemap.json +++ b/build/Rosetta.luau.linemap.json @@ -189,430 +189,430 @@ [70389, "src/Rosetta/codecs/image/Bcn/Encode.luau"], [70818, "src/Rosetta/codecs/image/Blend.luau"], [71197, "src/Rosetta/codecs/image/Dct/init.luau"], -[71697, "src/Rosetta/codecs/image/Etc.luau"], -[71995, "src/Rosetta/codecs/image/Half.luau"], -[72064, "src/Rosetta/codecs/image/Jpeg/init.luau"], -[72418, "src/Rosetta/codecs/image/Jpeg/Arith.luau"], -[72826, "src/Rosetta/codecs/image/Jpeg/Color.luau"], -[73191, "src/Rosetta/codecs/image/Jpeg/Decode.luau"], -[73956, "src/Rosetta/codecs/image/Jpeg/Encode.luau"], -[74837, "src/Rosetta/codecs/image/Jpeg/Scan.luau"], -[75306, "src/Rosetta/codecs/image/Jpeg/Tables.luau"], -[75384, "src/Rosetta/codecs/image/Jpeg/Yuv.luau"], -[75451, "src/Rosetta/codecs/image/Miptex.luau"], -[75751, "src/Rosetta/codecs/image/Pixels.luau"], -[76071, "src/Rosetta/codecs/image/Quantize/init.luau"], -[76532, "src/Rosetta/codecs/image/Raster.luau"], -[77229, "src/Rosetta/codecs/image/Texel.luau"], -[77602, "src/Rosetta/codecs/image/Texture.luau"], -[77747, "src/Rosetta/codecs/image/Vp8/init.luau"], -[77878, "src/Rosetta/codecs/image/Vp8/Decode.luau"], -[79834, "src/Rosetta/codecs/image/Vp8/Predict.luau"], -[80097, "src/Rosetta/codecs/image/Vp8/Tables.luau"], -[80347, "src/Rosetta/codecs/image/Vp8/Yuv.luau"], -[80489, "src/Rosetta/codecs/image/Vp8L/init.luau"], -[80593, "src/Rosetta/codecs/image/Vp8L/Decode.luau"], -[81533, "src/Rosetta/codecs/image/Vp8L/Encode.luau"], -[82485, "src/Rosetta/codecs/image/Yuv.luau"], -[82790, "src/Rosetta/codecs/model/Brush.luau"], -[83430, "src/Rosetta/codecs/model/Displacement.luau"], -[83579, "src/Rosetta/codecs/model/DoomMap/init.luau"], -[84024, "src/Rosetta/codecs/model/DoomMap/Udmf.luau"], -[84274, "src/Rosetta/codecs/model/Draco/init.luau"], -[84606, "src/Rosetta/codecs/model/Draco/Attributes.luau"], -[85075, "src/Rosetta/codecs/model/Draco/Connectivity.luau"], -[86264, "src/Rosetta/codecs/model/Draco/Int64.luau"], -[86413, "src/Rosetta/codecs/model/Draco/KdTree.luau"], -[86772, "src/Rosetta/codecs/model/Draco/Predict.luau"], -[87734, "src/Rosetta/codecs/model/Draco/Reader.luau"], -[88208, "src/Rosetta/codecs/model/Mat4.luau"], -[88467, "src/Rosetta/codecs/model/MeshFlatten.luau"], -[88995, "src/Rosetta/codecs/model/Minecraft/init.luau"], -[89547, "src/Rosetta/codecs/model/Minecraft/Colors.luau"], -[89626, "src/Rosetta/codecs/model/Minecraft/Legacy.luau"], -[89733, "src/Rosetta/codecs/model/Minecraft/Packed.luau"], -[89939, "src/Rosetta/codecs/model/Patch.luau"], -[90063, "src/Rosetta/codecs/model/Polygon.luau"], -[90297, "src/Rosetta/codecs/model/Rbx/init.luau"], -[90534, "src/Rosetta/codecs/model/Rbx/Binary.luau"], -[91288, "src/Rosetta/codecs/model/Rig.luau"], -[91531, "src/Rosetta/codecs/model/Sampler.luau"], -[91691, "src/Rosetta/codecs/model/SourceAnim.luau"], -[91912, "src/Rosetta/codecs/model/Vrml/init.luau"], -[92060, "src/Rosetta/codecs/model/Vrml/Build.luau"], -[92634, "src/Rosetta/codecs/model/Vrml/Fields.luau"], -[92797, "src/Rosetta/codecs/model/Vrml/Geometry.luau"], -[93546, "src/Rosetta/codecs/model/Vrml/Parse.luau"], -[94068, "src/Rosetta/codecs/model/Vrml/Write.luau"], -[94795, "src/Rosetta/codecs/model/Vrml/Xml.luau"], -[95027, "src/Rosetta/codecs/text/GodotVariant.luau"], -[95686, "src/Rosetta/codecs/text/Json/init.luau"], -[95955, "src/Rosetta/codecs/text/Json/Decode.luau"], -[96390, "src/Rosetta/codecs/text/Json/Encode.luau"], -[96735, "src/Rosetta/codecs/text/KeyValues/init.luau"], -[97305, "src/Rosetta/codecs/text/KeyValues/Binary.luau"], -[97611, "src/Rosetta/codecs/text/Lexer/init.luau"], -[97743, "src/Rosetta/codecs/text/Nbt/init.luau"], -[98096, "src/Rosetta/codecs/text/Nbt/Binary.luau"], -[98788, "src/Rosetta/codecs/text/Nbt/Snbt.luau"], -[99428, "src/Rosetta/codecs/text/Nbt/Value.luau"], -[99666, "src/Rosetta/codecs/text/Text/init.luau"], -[99757, "src/Rosetta/codecs/text/Url/init.luau"], -[99962, "src/Rosetta/codecs/text/Xml/init.luau"], -[100412, "src/Rosetta/codecs/text/Xml/Parse.luau"], -[101216, "src/Rosetta/codecs/video/Dsp.luau"], -[102054, "src/Rosetta/codecs/video/H263/init.luau"], -[102211, "src/Rosetta/codecs/video/H263/Decoder.luau"], -[103069, "src/Rosetta/codecs/video/H263/Tables.luau"], -[103273, "src/Rosetta/codecs/video/H264/init.luau"], -[103647, "src/Rosetta/codecs/video/H264/Bitstream.luau"], -[103922, "src/Rosetta/codecs/video/H264/Cabac.luau"], -[105053, "src/Rosetta/codecs/video/H264/Cavlc.luau"], -[105821, "src/Rosetta/codecs/video/H264/Deblock.luau"], -[106083, "src/Rosetta/codecs/video/H264/Decoder.luau"], -[107093, "src/Rosetta/codecs/video/H264/Inter.luau"], -[107419, "src/Rosetta/codecs/video/H264/Intra.luau"], -[107826, "src/Rosetta/codecs/video/H264/Mb.luau"], -[108765, "src/Rosetta/codecs/video/H264/Params.luau"], -[109213, "src/Rosetta/codecs/video/H264/Slice.luau"], -[109465, "src/Rosetta/codecs/video/H264/Tables.luau"], -[109507, "src/Rosetta/codecs/video/H264/Transform.luau"], -[109672, "src/Rosetta/codecs/video/Legacy/init.luau"], -[109871, "src/Rosetta/codecs/video/Legacy/Cinepak.luau"], -[110168, "src/Rosetta/codecs/video/Legacy/Flic.luau"], -[110535, "src/Rosetta/codecs/video/Legacy/Msvideo1.luau"], -[110653, "src/Rosetta/codecs/video/Legacy/Picture.luau"], -[110761, "src/Rosetta/codecs/video/Legacy/QtRle.luau"], -[111034, "src/Rosetta/codecs/video/Legacy/Smacker.luau"], -[111429, "src/Rosetta/codecs/video/Legacy/Smc.luau"], -[111606, "src/Rosetta/codecs/video/Mpeg1/init.luau"], -[111619, "src/Rosetta/codecs/video/Mpeg2/init.luau"], -[111987, "src/Rosetta/codecs/video/Mpeg2/Decoder.luau"], -[113514, "src/Rosetta/codecs/video/Mpeg2/Tables.luau"], -[113654, "src/Rosetta/codecs/video/Mpeg2/Vlc.luau"], -[113793, "src/Rosetta/codecs/video/Theora/init.luau"], -[114057, "src/Rosetta/codecs/video/Theora/Decoder.luau"], -[115321, "src/Rosetta/codecs/video/Theora/Header.luau"], -[115685, "src/Rosetta/codecs/video/Video/init.luau"], -[116243, "src/Rosetta/codecs/video/Video/Source.luau"], -[116529, "src/Rosetta/containers/Archive.luau"], -[116796, "src/Rosetta/containers/AudioWrap.luau"], -[117306, "src/Rosetta/containers/Avi/init.luau"], -[117859, "src/Rosetta/containers/Blend.luau"], -[118598, "src/Rosetta/containers/Chunks.luau"], -[118733, "src/Rosetta/containers/Cpio.luau"], -[119161, "src/Rosetta/containers/Demux.luau"], -[119436, "src/Rosetta/containers/Ebml/init.luau"], -[119750, "src/Rosetta/containers/Fat.luau"], -[120438, "src/Rosetta/containers/Iso9660.luau"], -[120943, "src/Rosetta/containers/IsoBmff/init.luau"], -[121114, "src/Rosetta/containers/IsoBmff/Box.luau"], -[121303, "src/Rosetta/containers/IsoBmff/Demux.luau"], -[122149, "src/Rosetta/containers/IsoBmff/Meta.luau"], -[122671, "src/Rosetta/containers/IsoBmff/Mux.luau"], -[123188, "src/Rosetta/containers/IsoBmff/QtPalette.luau"], -[123306, "src/Rosetta/containers/MacFile.luau"], -[123455, "src/Rosetta/containers/MpegEs.luau"], -[123622, "src/Rosetta/containers/MpegPs/init.luau"], -[123843, "src/Rosetta/containers/MpegTs/init.luau"], -[124636, "src/Rosetta/containers/Ogg/init.luau"], -[125061, "src/Rosetta/containers/Ogg/Mux.luau"], -[125250, "src/Rosetta/containers/Ogg/Page.luau"], -[125416, "src/Rosetta/containers/Riff/init.luau"], -[125733, "src/Rosetta/containers/Tar.luau"], -[126147, "src/Rosetta/containers/Zip/init.luau"], -[126779, "src/Rosetta/core/Adler32.luau"], -[126839, "src/Rosetta/core/Base64.luau"], -[127067, "src/Rosetta/core/Bits.luau"], -[127360, "src/Rosetta/core/Bytes.luau"], -[127887, "src/Rosetta/core/Crc16.luau"], -[127939, "src/Rosetta/core/Crc32.luau"], -[128090, "src/Rosetta/core/Err.luau"], -[128172, "src/Rosetta/core/Input.luau"], -[128248, "src/Rosetta/core/Md5.luau"], -[128406, "src/Rosetta/core/Sniff.luau"], -[128435, "src/Rosetta/data/cbor/init.luau"], -[128534, "src/Rosetta/data/cbor/Codec.luau"], -[129103, "src/Rosetta/data/csv/init.luau"], -[129415, "src/Rosetta/data/ini/init.luau"], -[129661, "src/Rosetta/data/json/init.luau"], -[129753, "src/Rosetta/data/msgpack/init.luau"], -[129842, "src/Rosetta/data/msgpack/Codec.luau"], -[130284, "src/Rosetta/data/nbt/init.luau"], -[130343, "src/Rosetta/data/plist/init.luau"], -[130649, "src/Rosetta/data/plist/Binary.luau"], -[130916, "src/Rosetta/data/q3shader/init.luau"], -[131155, "src/Rosetta/data/q3skin/init.luau"], -[131251, "src/Rosetta/data/snbt/init.luau"], -[131314, "src/Rosetta/data/toml/init.luau"], -[131381, "src/Rosetta/data/toml/Decode.luau"], -[132009, "src/Rosetta/data/toml/Encode.luau"], -[132218, "src/Rosetta/data/tres/init.luau"], -[132363, "src/Rosetta/data/vdf/init.luau"], -[132464, "src/Rosetta/data/xml/init.luau"], -[132520, "src/Rosetta/data/yaml/init.luau"], -[132593, "src/Rosetta/data/yaml/Emit.luau"], -[132883, "src/Rosetta/data/yaml/Parse.luau"], -[134176, "src/Rosetta/font/bdf/init.luau"], -[134465, "src/Rosetta/font/bmfont/init.luau"], -[134892, "src/Rosetta/font/bmfont/Parse.luau"], -[135345, "src/Rosetta/font/eot/init.luau"], -[135577, "src/Rosetta/font/fon/init.luau"], -[135860, "src/Rosetta/font/hershey/init.luau"], -[136055, "src/Rosetta/font/pcf/init.luau"], -[136335, "src/Rosetta/font/psf/init.luau"], -[136655, "src/Rosetta/font/ttf/init.luau"], -[136706, "src/Rosetta/font/type1/init.luau"], -[137065, "src/Rosetta/font/type1/Charstring.luau"], -[137343, "src/Rosetta/font/woff/init.luau"], -[137475, "src/Rosetta/font/woff2/init.luau"], -[137532, "src/Rosetta/font/woff2/Rebuild.luau"], -[138072, "src/Rosetta/host/init.luau"], -[138117, "src/Rosetta/host/Love.luau"], -[138260, "src/Rosetta/host/LuaJIT.luau"], -[138310, "src/Rosetta/host/Luau.luau"], -[138333, "src/Rosetta/host/Roblox.luau"], -[138692, "src/Rosetta/image/ani/init.luau"], -[138872, "src/Rosetta/image/art/init.luau"], -[139360, "src/Rosetta/image/blp/init.luau"], -[139618, "src/Rosetta/image/bmp/init.luau"], -[140033, "src/Rosetta/image/dds/init.luau"], -[140516, "src/Rosetta/image/exr/init.luau"], -[141276, "src/Rosetta/image/exr/Codec.luau"], -[141387, "src/Rosetta/image/exr/Piz.luau"], -[141744, "src/Rosetta/image/gif/init.luau"], -[142260, "src/Rosetta/image/gif/Decode.luau"], -[142336, "src/Rosetta/image/hdr/init.luau"], -[142565, "src/Rosetta/image/hdr/Codec.luau"], -[142776, "src/Rosetta/image/icns/init.luau"], -[143107, "src/Rosetta/image/ico/init.luau"], -[143384, "src/Rosetta/image/ico/Dib.luau"], -[143479, "src/Rosetta/image/ilbm/init.luau"], -[143798, "src/Rosetta/image/jpeg/init.luau"], -[143934, "src/Rosetta/image/ktx/init.luau"], -[144594, "src/Rosetta/image/lmp/init.luau"], -[144727, "src/Rosetta/image/pcx/init.luau"], -[144991, "src/Rosetta/image/png/init.luau"], -[145571, "src/Rosetta/image/png/Apng.luau"], -[145651, "src/Rosetta/image/png/Decode.luau"], -[146024, "src/Rosetta/image/png/Encode.luau"], -[146227, "src/Rosetta/image/pnm/init.luau"], -[146605, "src/Rosetta/image/pnm/Codec.luau"], -[146882, "src/Rosetta/image/qoi/init.luau"], -[147004, "src/Rosetta/image/qoi/Codec.luau"], -[147161, "src/Rosetta/image/sgi/init.luau"], -[147446, "src/Rosetta/image/spr/init.luau"], -[147759, "src/Rosetta/image/sunras/init.luau"], -[148005, "src/Rosetta/image/tga/init.luau"], -[148275, "src/Rosetta/image/tga/Codec.luau"], -[148475, "src/Rosetta/image/tiff/init.luau"], -[149302, "src/Rosetta/image/tiff/Pixels.luau"], -[149692, "src/Rosetta/image/tim/init.luau"], -[149934, "src/Rosetta/image/vtf/init.luau"], -[150169, "src/Rosetta/image/webp/init.luau"], -[150779, "src/Rosetta/image/webp/Alpha.luau"], -[150855, "src/Rosetta/image/webp/Anim.luau"], -[151010, "src/Rosetta/image/xbm/init.luau"], -[151171, "src/Rosetta/image/xpm/init.luau"], -[151439, "src/Rosetta/image/xpm/Names.luau"], -[151495, "src/Rosetta/layered/aseprite/init.luau"], -[152233, "src/Rosetta/layered/ora/init.luau"], -[152520, "src/Rosetta/layered/psd/init.luau"], -[153255, "src/Rosetta/layered/psd/Channels.luau"], -[153607, "src/Rosetta/model/3ds/init.luau"], -[153690, "src/Rosetta/model/3ds/Build.luau"], -[154337, "src/Rosetta/model/3ds/Read.luau"], -[154833, "src/Rosetta/model/3ds/Write.luau"], -[155638, "src/Rosetta/model/3mf/init.luau"], -[155720, "src/Rosetta/model/3mf/Read.luau"], -[156308, "src/Rosetta/model/3mf/Write.luau"], -[156713, "src/Rosetta/model/ase/init.luau"], -[156836, "src/Rosetta/model/ase/Build.luau"], -[157410, "src/Rosetta/model/ase/Parse.luau"], -[157479, "src/Rosetta/model/ase/Write.luau"], -[157942, "src/Rosetta/model/b3d/init.luau"], -[157997, "src/Rosetta/model/b3d/Read.luau"], -[158568, "src/Rosetta/model/blend/init.luau"], -[158664, "src/Rosetta/model/blend/Anim.luau"], -[159010, "src/Rosetta/model/blend/Material.luau"], -[159362, "src/Rosetta/model/blend/Mesh.luau"], -[159997, "src/Rosetta/model/blend/Normals.luau"], -[160158, "src/Rosetta/model/blend/Prim.luau"], -[160607, "src/Rosetta/model/blend/Read.luau"], -[161507, "src/Rosetta/model/bsp/init.luau"], -[161698, "src/Rosetta/model/bsp/Lightmap.luau"], -[161764, "src/Rosetta/model/bsp/Quake.luau"], -[162153, "src/Rosetta/model/bsp/Quake3.luau"], -[162382, "src/Rosetta/model/bsp/Tree.luau"], -[162770, "src/Rosetta/model/buildmap/init.luau"], -[163042, "src/Rosetta/model/buildmap/Geometry.luau"], -[163445, "src/Rosetta/model/d3map/init.luau"], -[163727, "src/Rosetta/model/d3map/Parse.luau"], -[163925, "src/Rosetta/model/dae/init.luau"], -[164114, "src/Rosetta/model/dae/Math.luau"], -[164161, "src/Rosetta/model/dae/Read.luau"], -[166011, "src/Rosetta/model/dae/Write.luau"], -[166380, "src/Rosetta/model/fbx/init.luau"], -[166528, "src/Rosetta/model/fbx/Ascii.luau"], -[166798, "src/Rosetta/model/fbx/Binary.luau"], -[167253, "src/Rosetta/model/fbx/Read.luau"], -[168615, "src/Rosetta/model/fbx/Write.luau"], -[169600, "src/Rosetta/model/fbx/Xform.luau"], -[169641, "src/Rosetta/model/gltf/init.luau"], -[169878, "src/Rosetta/model/gltf/Pack.luau"], -[169947, "src/Rosetta/model/gltf/Read.luau"], -[170678, "src/Rosetta/model/gltf/Write.luau"], -[171358, "src/Rosetta/model/godot/init.luau"], -[171449, "src/Rosetta/model/godot/Build.luau"], -[171991, "src/Rosetta/model/godot/Primitives.luau"], -[172266, "src/Rosetta/model/godot/Surface.luau"], -[172751, "src/Rosetta/model/godot/Write.luau"], -[173080, "src/Rosetta/model/iqm/init.luau"], -[173156, "src/Rosetta/model/iqm/Read.luau"], -[173511, "src/Rosetta/model/iqm/Write.luau"], -[174198, "src/Rosetta/model/ldraw/init.luau"], -[174276, "src/Rosetta/model/ldraw/Colors.luau"], -[174594, "src/Rosetta/model/ldraw/Read.luau"], -[175171, "src/Rosetta/model/lwo/init.luau"], -[175247, "src/Rosetta/model/lwo/Build.luau"], -[175709, "src/Rosetta/model/lwo/Parse.luau"], -[176252, "src/Rosetta/model/map/init.luau"], -[176569, "src/Rosetta/model/map/Build.luau"], -[176813, "src/Rosetta/model/map/Parse.luau"], -[177198, "src/Rosetta/model/map/Write.luau"], -[177344, "src/Rosetta/model/mca/init.luau"], -[177686, "src/Rosetta/model/mca/Chunk.luau"], -[177819, "src/Rosetta/model/mca/Lz4Block.luau"], -[177889, "src/Rosetta/model/md2/init.luau"], -[178088, "src/Rosetta/model/md3/init.luau"], -[178316, "src/Rosetta/model/md5/init.luau"], -[178397, "src/Rosetta/model/md5/Read.luau"], -[178830, "src/Rosetta/model/mdl/init.luau"], -[178912, "src/Rosetta/model/mdl/HalfLife.luau"], -[179216, "src/Rosetta/model/mdl/Quake.luau"], -[179434, "src/Rosetta/model/ms3d/init.luau"], -[179506, "src/Rosetta/model/ms3d/Read.luau"], -[179952, "src/Rosetta/model/ms3d/Write.luau"], -[180421, "src/Rosetta/model/obj/init.luau"], -[181239, "src/Rosetta/model/obj/Mtl.luau"], -[181527, "src/Rosetta/model/off/init.luau"], -[181989, "src/Rosetta/model/ply/init.luau"], -[183094, "src/Rosetta/model/ply/Binary.luau"], -[183295, "src/Rosetta/model/pmx/init.luau"], -[183364, "src/Rosetta/model/pmx/Build.luau"], -[183660, "src/Rosetta/model/pmx/Pmd.luau"], -[183995, "src/Rosetta/model/pmx/Read.luau"], -[184399, "src/Rosetta/model/proc/init.luau"], -[184781, "src/Rosetta/model/qb/init.luau"], -[185174, "src/Rosetta/model/rbxm/init.luau"], -[185767, "src/Rosetta/model/rbxmx/init.luau"], -[186443, "src/Rosetta/model/robloxmesh/init.luau"], -[187102, "src/Rosetta/model/robloxmesh/Parse.luau"], -[187559, "src/Rosetta/model/robloxmesh/Write.luau"], -[187668, "src/Rosetta/model/schematic/init.luau"], -[187989, "src/Rosetta/model/schematic/Common.luau"], -[188109, "src/Rosetta/model/schematic/Litematic.luau"], -[188320, "src/Rosetta/model/schematic/Mcedit.luau"], -[188564, "src/Rosetta/model/schematic/Sponge.luau"], -[188693, "src/Rosetta/model/smd/init.luau"], -[188760, "src/Rosetta/model/smd/Read.luau"], -[189029, "src/Rosetta/model/smd/Write.luau"], -[189272, "src/Rosetta/model/sourcemdl/init.luau"], -[189443, "src/Rosetta/model/sourcemdl/Build.luau"], -[189873, "src/Rosetta/model/sourcemdl/Material.luau"], -[190034, "src/Rosetta/model/sourcemdl/Mdl.luau"], -[190561, "src/Rosetta/model/sourcemdl/Phy.luau"], -[190684, "src/Rosetta/model/sourcemdl/Vtx.luau"], -[190866, "src/Rosetta/model/sourcemdl/Vvd.luau"], -[190960, "src/Rosetta/model/stl/init.luau"], -[191410, "src/Rosetta/model/stl/Decode.luau"], -[191484, "src/Rosetta/model/t3d/init.luau"], -[191578, "src/Rosetta/model/t3d/Build.luau"], -[191983, "src/Rosetta/model/t3d/Parse.luau"], -[192151, "src/Rosetta/model/udmf/init.luau"], -[192234, "src/Rosetta/model/usda/init.luau"], -[192443, "src/Rosetta/model/usda/Build.luau"], -[193721, "src/Rosetta/model/usda/Parse.luau"], -[194519, "src/Rosetta/model/usda/Write.luau"], -[195336, "src/Rosetta/model/vbsp/init.luau"], -[195782, "src/Rosetta/model/vbsp/Faces.luau"], -[196006, "src/Rosetta/model/vbsp/Props.luau"], -[196098, "src/Rosetta/model/vmf/init.luau"], -[196423, "src/Rosetta/model/vmf/Build.luau"], -[196847, "src/Rosetta/model/vox/init.luau"], -[197733, "src/Rosetta/model/vox/Grid.luau"], -[197790, "src/Rosetta/model/vrml/init.luau"], -[197856, "src/Rosetta/model/x/init.luau"], -[197986, "src/Rosetta/model/x/Build.luau"], -[198549, "src/Rosetta/model/x/Parse.luau"], -[198846, "src/Rosetta/model/x3d/init.luau"], -[198924, "src/Rosetta/music/669/init.luau"], -[199131, "src/Rosetta/music/ahx/init.luau"], -[199183, "src/Rosetta/music/far/init.luau"], -[199413, "src/Rosetta/music/hmp/init.luau"], -[199678, "src/Rosetta/music/hvl/init.luau"], -[199730, "src/Rosetta/music/it/init.luau"], -[200149, "src/Rosetta/music/it/Itsex.luau"], -[200266, "src/Rosetta/music/med/init.luau"], -[200914, "src/Rosetta/music/midi/init.luau"], -[201058, "src/Rosetta/music/midi/Smf.luau"], -[201470, "src/Rosetta/music/mod/init.luau"], -[201824, "src/Rosetta/music/mtm/init.luau"], -[202047, "src/Rosetta/music/mus/init.luau"], -[202205, "src/Rosetta/music/okt/init.luau"], -[202487, "src/Rosetta/music/ptm/init.luau"], -[202710, "src/Rosetta/music/s3m/init.luau"], -[202947, "src/Rosetta/music/sf2/init.luau"], -[202991, "src/Rosetta/music/stm/init.luau"], -[203223, "src/Rosetta/music/ult/init.luau"], -[203528, "src/Rosetta/music/umx/init.luau"], -[203745, "src/Rosetta/music/xm/init.luau"], -[204307, "src/Rosetta/music/xmi/init.luau"], -[204516, "src/Rosetta/ops/AudioOps.luau"], -[204995, "src/Rosetta/ops/ImageOps/init.luau"], -[205643, "src/Rosetta/ops/ImageOps/Kernels.luau"], -[206283, "src/Rosetta/ops/LayerOps.luau"], -[206376, "src/Rosetta/ops/MeshOps/init.luau"], -[207428, "src/Rosetta/ops/MeshOps/Greedy.luau"], -[207595, "src/Rosetta/ops/MusicOps.luau"], -[207944, "src/Rosetta/playlist/m3u/init.luau"], -[208297, "src/Rosetta/playlist/pls/init.luau"], -[208475, "src/Rosetta/playlist/xspf/init.luau"], -[208678, "src/Rosetta/subtitle/ass/init.luau"], -[209122, "src/Rosetta/subtitle/srt/init.luau"], -[209295, "src/Rosetta/subtitle/vtt/init.luau"], -[209498, "src/Rosetta/vector/gamemaps/init.luau"], -[209685, "src/Rosetta/vector/gamemaps/Expand.luau"], -[209782, "src/Rosetta/vector/ldtk/init.luau"], -[209874, "src/Rosetta/vector/ldtk/Read.luau"], -[210210, "src/Rosetta/vector/ldtk/Write.luau"], -[210858, "src/Rosetta/vector/ogmo/init.luau"], -[210977, "src/Rosetta/vector/ogmo/Read.luau"], -[211382, "src/Rosetta/vector/ogmo/Write.luau"], -[211736, "src/Rosetta/vector/svg/init.luau"], -[211822, "src/Rosetta/vector/svg/Parse.luau"], -[212568, "src/Rosetta/vector/svg/PathData.luau"], -[212936, "src/Rosetta/vector/svg/Render.luau"], -[213353, "src/Rosetta/vector/svg/Style.luau"], -[213725, "src/Rosetta/vector/svg/Write.luau"], -[213925, "src/Rosetta/vector/tiled/init.luau"], -[214105, "src/Rosetta/vector/tiled/Data.luau"], -[214256, "src/Rosetta/vector/tiled/Tmj.luau"], -[214887, "src/Rosetta/vector/tiled/Tmx.luau"], -[215499, "src/Rosetta/video/avi/init.luau"], -[215793, "src/Rosetta/video/fli/init.luau"], -[215944, "src/Rosetta/video/flv/init.luau"], -[216328, "src/Rosetta/video/flv/Amf.luau"], -[216486, "src/Rosetta/video/flv/Mux.luau"], -[216767, "src/Rosetta/video/h264/init.luau"], -[216906, "src/Rosetta/video/mkv/init.luau"], -[217062, "src/Rosetta/video/mkv/Mux.luau"], -[217341, "src/Rosetta/video/mkv/Parse.luau"], -[218062, "src/Rosetta/video/mp4/init.luau"], -[218390, "src/Rosetta/video/mpegps/init.luau"], -[218577, "src/Rosetta/video/mpegts/init.luau"], -[218823, "src/Rosetta/video/ogv/init.luau"], -[219218, "src/Rosetta/video/smk/init.luau"], -[219527, "src/Rosetta/video/smk/Audio.luau"], -[219647, "src/Rosetta/video/y4m/init.luau"] +[71692, "src/Rosetta/codecs/image/Etc.luau"], +[71990, "src/Rosetta/codecs/image/Half.luau"], +[72059, "src/Rosetta/codecs/image/Jpeg/init.luau"], +[72413, "src/Rosetta/codecs/image/Jpeg/Arith.luau"], +[72821, "src/Rosetta/codecs/image/Jpeg/Color.luau"], +[73186, "src/Rosetta/codecs/image/Jpeg/Decode.luau"], +[73951, "src/Rosetta/codecs/image/Jpeg/Encode.luau"], +[74832, "src/Rosetta/codecs/image/Jpeg/Scan.luau"], +[75301, "src/Rosetta/codecs/image/Jpeg/Tables.luau"], +[75379, "src/Rosetta/codecs/image/Jpeg/Yuv.luau"], +[75446, "src/Rosetta/codecs/image/Miptex.luau"], +[75746, "src/Rosetta/codecs/image/Pixels.luau"], +[76066, "src/Rosetta/codecs/image/Quantize/init.luau"], +[76527, "src/Rosetta/codecs/image/Raster.luau"], +[77224, "src/Rosetta/codecs/image/Texel.luau"], +[77597, "src/Rosetta/codecs/image/Texture.luau"], +[77742, "src/Rosetta/codecs/image/Vp8/init.luau"], +[77873, "src/Rosetta/codecs/image/Vp8/Decode.luau"], +[79829, "src/Rosetta/codecs/image/Vp8/Predict.luau"], +[80092, "src/Rosetta/codecs/image/Vp8/Tables.luau"], +[80342, "src/Rosetta/codecs/image/Vp8/Yuv.luau"], +[80484, "src/Rosetta/codecs/image/Vp8L/init.luau"], +[80588, "src/Rosetta/codecs/image/Vp8L/Decode.luau"], +[81528, "src/Rosetta/codecs/image/Vp8L/Encode.luau"], +[82480, "src/Rosetta/codecs/image/Yuv.luau"], +[82785, "src/Rosetta/codecs/model/Brush.luau"], +[83425, "src/Rosetta/codecs/model/Displacement.luau"], +[83574, "src/Rosetta/codecs/model/DoomMap/init.luau"], +[84019, "src/Rosetta/codecs/model/DoomMap/Udmf.luau"], +[84269, "src/Rosetta/codecs/model/Draco/init.luau"], +[84601, "src/Rosetta/codecs/model/Draco/Attributes.luau"], +[85070, "src/Rosetta/codecs/model/Draco/Connectivity.luau"], +[86259, "src/Rosetta/codecs/model/Draco/Int64.luau"], +[86408, "src/Rosetta/codecs/model/Draco/KdTree.luau"], +[86767, "src/Rosetta/codecs/model/Draco/Predict.luau"], +[87729, "src/Rosetta/codecs/model/Draco/Reader.luau"], +[88203, "src/Rosetta/codecs/model/Mat4.luau"], +[88462, "src/Rosetta/codecs/model/MeshFlatten.luau"], +[88990, "src/Rosetta/codecs/model/Minecraft/init.luau"], +[89542, "src/Rosetta/codecs/model/Minecraft/Colors.luau"], +[89621, "src/Rosetta/codecs/model/Minecraft/Legacy.luau"], +[89728, "src/Rosetta/codecs/model/Minecraft/Packed.luau"], +[89934, "src/Rosetta/codecs/model/Patch.luau"], +[90058, "src/Rosetta/codecs/model/Polygon.luau"], +[90292, "src/Rosetta/codecs/model/Rbx/init.luau"], +[90529, "src/Rosetta/codecs/model/Rbx/Binary.luau"], +[91283, "src/Rosetta/codecs/model/Rig.luau"], +[91526, "src/Rosetta/codecs/model/Sampler.luau"], +[91686, "src/Rosetta/codecs/model/SourceAnim.luau"], +[91907, "src/Rosetta/codecs/model/Vrml/init.luau"], +[92055, "src/Rosetta/codecs/model/Vrml/Build.luau"], +[92629, "src/Rosetta/codecs/model/Vrml/Fields.luau"], +[92792, "src/Rosetta/codecs/model/Vrml/Geometry.luau"], +[93541, "src/Rosetta/codecs/model/Vrml/Parse.luau"], +[94063, "src/Rosetta/codecs/model/Vrml/Write.luau"], +[94790, "src/Rosetta/codecs/model/Vrml/Xml.luau"], +[95022, "src/Rosetta/codecs/text/GodotVariant.luau"], +[95681, "src/Rosetta/codecs/text/Json/init.luau"], +[95950, "src/Rosetta/codecs/text/Json/Decode.luau"], +[96385, "src/Rosetta/codecs/text/Json/Encode.luau"], +[96730, "src/Rosetta/codecs/text/KeyValues/init.luau"], +[97300, "src/Rosetta/codecs/text/KeyValues/Binary.luau"], +[97606, "src/Rosetta/codecs/text/Lexer/init.luau"], +[97738, "src/Rosetta/codecs/text/Nbt/init.luau"], +[98091, "src/Rosetta/codecs/text/Nbt/Binary.luau"], +[98783, "src/Rosetta/codecs/text/Nbt/Snbt.luau"], +[99423, "src/Rosetta/codecs/text/Nbt/Value.luau"], +[99661, "src/Rosetta/codecs/text/Text/init.luau"], +[99752, "src/Rosetta/codecs/text/Url/init.luau"], +[99957, "src/Rosetta/codecs/text/Xml/init.luau"], +[100407, "src/Rosetta/codecs/text/Xml/Parse.luau"], +[101211, "src/Rosetta/codecs/video/Dsp.luau"], +[102049, "src/Rosetta/codecs/video/H263/init.luau"], +[102206, "src/Rosetta/codecs/video/H263/Decoder.luau"], +[103064, "src/Rosetta/codecs/video/H263/Tables.luau"], +[103268, "src/Rosetta/codecs/video/H264/init.luau"], +[103642, "src/Rosetta/codecs/video/H264/Bitstream.luau"], +[103917, "src/Rosetta/codecs/video/H264/Cabac.luau"], +[105048, "src/Rosetta/codecs/video/H264/Cavlc.luau"], +[105816, "src/Rosetta/codecs/video/H264/Deblock.luau"], +[106078, "src/Rosetta/codecs/video/H264/Decoder.luau"], +[107088, "src/Rosetta/codecs/video/H264/Inter.luau"], +[107414, "src/Rosetta/codecs/video/H264/Intra.luau"], +[107821, "src/Rosetta/codecs/video/H264/Mb.luau"], +[108760, "src/Rosetta/codecs/video/H264/Params.luau"], +[109208, "src/Rosetta/codecs/video/H264/Slice.luau"], +[109460, "src/Rosetta/codecs/video/H264/Tables.luau"], +[109502, "src/Rosetta/codecs/video/H264/Transform.luau"], +[109667, "src/Rosetta/codecs/video/Legacy/init.luau"], +[109866, "src/Rosetta/codecs/video/Legacy/Cinepak.luau"], +[110163, "src/Rosetta/codecs/video/Legacy/Flic.luau"], +[110530, "src/Rosetta/codecs/video/Legacy/Msvideo1.luau"], +[110648, "src/Rosetta/codecs/video/Legacy/Picture.luau"], +[110756, "src/Rosetta/codecs/video/Legacy/QtRle.luau"], +[111029, "src/Rosetta/codecs/video/Legacy/Smacker.luau"], +[111424, "src/Rosetta/codecs/video/Legacy/Smc.luau"], +[111601, "src/Rosetta/codecs/video/Mpeg1/init.luau"], +[111614, "src/Rosetta/codecs/video/Mpeg2/init.luau"], +[111982, "src/Rosetta/codecs/video/Mpeg2/Decoder.luau"], +[113509, "src/Rosetta/codecs/video/Mpeg2/Tables.luau"], +[113649, "src/Rosetta/codecs/video/Mpeg2/Vlc.luau"], +[113788, "src/Rosetta/codecs/video/Theora/init.luau"], +[114052, "src/Rosetta/codecs/video/Theora/Decoder.luau"], +[115316, "src/Rosetta/codecs/video/Theora/Header.luau"], +[115680, "src/Rosetta/codecs/video/Video/init.luau"], +[116238, "src/Rosetta/codecs/video/Video/Source.luau"], +[116524, "src/Rosetta/containers/Archive.luau"], +[116791, "src/Rosetta/containers/AudioWrap.luau"], +[117301, "src/Rosetta/containers/Avi/init.luau"], +[117854, "src/Rosetta/containers/Blend.luau"], +[118593, "src/Rosetta/containers/Chunks.luau"], +[118728, "src/Rosetta/containers/Cpio.luau"], +[119156, "src/Rosetta/containers/Demux.luau"], +[119431, "src/Rosetta/containers/Ebml/init.luau"], +[119745, "src/Rosetta/containers/Fat.luau"], +[120433, "src/Rosetta/containers/Iso9660.luau"], +[120938, "src/Rosetta/containers/IsoBmff/init.luau"], +[121109, "src/Rosetta/containers/IsoBmff/Box.luau"], +[121298, "src/Rosetta/containers/IsoBmff/Demux.luau"], +[122144, "src/Rosetta/containers/IsoBmff/Meta.luau"], +[122666, "src/Rosetta/containers/IsoBmff/Mux.luau"], +[123183, "src/Rosetta/containers/IsoBmff/QtPalette.luau"], +[123301, "src/Rosetta/containers/MacFile.luau"], +[123450, "src/Rosetta/containers/MpegEs.luau"], +[123617, "src/Rosetta/containers/MpegPs/init.luau"], +[123838, "src/Rosetta/containers/MpegTs/init.luau"], +[124631, "src/Rosetta/containers/Ogg/init.luau"], +[125056, "src/Rosetta/containers/Ogg/Mux.luau"], +[125245, "src/Rosetta/containers/Ogg/Page.luau"], +[125411, "src/Rosetta/containers/Riff/init.luau"], +[125728, "src/Rosetta/containers/Tar.luau"], +[126142, "src/Rosetta/containers/Zip/init.luau"], +[126774, "src/Rosetta/core/Adler32.luau"], +[126834, "src/Rosetta/core/Base64.luau"], +[127062, "src/Rosetta/core/Bits.luau"], +[127355, "src/Rosetta/core/Bytes.luau"], +[127882, "src/Rosetta/core/Crc16.luau"], +[127934, "src/Rosetta/core/Crc32.luau"], +[128085, "src/Rosetta/core/Err.luau"], +[128167, "src/Rosetta/core/Input.luau"], +[128243, "src/Rosetta/core/Md5.luau"], +[128401, "src/Rosetta/core/Sniff.luau"], +[128430, "src/Rosetta/data/cbor/init.luau"], +[128529, "src/Rosetta/data/cbor/Codec.luau"], +[129098, "src/Rosetta/data/csv/init.luau"], +[129410, "src/Rosetta/data/ini/init.luau"], +[129656, "src/Rosetta/data/json/init.luau"], +[129748, "src/Rosetta/data/msgpack/init.luau"], +[129837, "src/Rosetta/data/msgpack/Codec.luau"], +[130279, "src/Rosetta/data/nbt/init.luau"], +[130338, "src/Rosetta/data/plist/init.luau"], +[130644, "src/Rosetta/data/plist/Binary.luau"], +[130911, "src/Rosetta/data/q3shader/init.luau"], +[131150, "src/Rosetta/data/q3skin/init.luau"], +[131246, "src/Rosetta/data/snbt/init.luau"], +[131309, "src/Rosetta/data/toml/init.luau"], +[131376, "src/Rosetta/data/toml/Decode.luau"], +[132004, "src/Rosetta/data/toml/Encode.luau"], +[132213, "src/Rosetta/data/tres/init.luau"], +[132358, "src/Rosetta/data/vdf/init.luau"], +[132459, "src/Rosetta/data/xml/init.luau"], +[132515, "src/Rosetta/data/yaml/init.luau"], +[132588, "src/Rosetta/data/yaml/Emit.luau"], +[132878, "src/Rosetta/data/yaml/Parse.luau"], +[134171, "src/Rosetta/font/bdf/init.luau"], +[134460, "src/Rosetta/font/bmfont/init.luau"], +[134887, "src/Rosetta/font/bmfont/Parse.luau"], +[135340, "src/Rosetta/font/eot/init.luau"], +[135572, "src/Rosetta/font/fon/init.luau"], +[135855, "src/Rosetta/font/hershey/init.luau"], +[136050, "src/Rosetta/font/pcf/init.luau"], +[136330, "src/Rosetta/font/psf/init.luau"], +[136650, "src/Rosetta/font/ttf/init.luau"], +[136701, "src/Rosetta/font/type1/init.luau"], +[137060, "src/Rosetta/font/type1/Charstring.luau"], +[137338, "src/Rosetta/font/woff/init.luau"], +[137470, "src/Rosetta/font/woff2/init.luau"], +[137527, "src/Rosetta/font/woff2/Rebuild.luau"], +[138067, "src/Rosetta/host/init.luau"], +[138112, "src/Rosetta/host/Love.luau"], +[138255, "src/Rosetta/host/LuaJIT.luau"], +[138305, "src/Rosetta/host/Luau.luau"], +[138328, "src/Rosetta/host/Roblox.luau"], +[138687, "src/Rosetta/image/ani/init.luau"], +[138867, "src/Rosetta/image/art/init.luau"], +[139355, "src/Rosetta/image/blp/init.luau"], +[139613, "src/Rosetta/image/bmp/init.luau"], +[140028, "src/Rosetta/image/dds/init.luau"], +[140511, "src/Rosetta/image/exr/init.luau"], +[141271, "src/Rosetta/image/exr/Codec.luau"], +[141382, "src/Rosetta/image/exr/Piz.luau"], +[141739, "src/Rosetta/image/gif/init.luau"], +[142255, "src/Rosetta/image/gif/Decode.luau"], +[142331, "src/Rosetta/image/hdr/init.luau"], +[142560, "src/Rosetta/image/hdr/Codec.luau"], +[142771, "src/Rosetta/image/icns/init.luau"], +[143102, "src/Rosetta/image/ico/init.luau"], +[143379, "src/Rosetta/image/ico/Dib.luau"], +[143474, "src/Rosetta/image/ilbm/init.luau"], +[143793, "src/Rosetta/image/jpeg/init.luau"], +[143929, "src/Rosetta/image/ktx/init.luau"], +[144589, "src/Rosetta/image/lmp/init.luau"], +[144722, "src/Rosetta/image/pcx/init.luau"], +[144986, "src/Rosetta/image/png/init.luau"], +[145566, "src/Rosetta/image/png/Apng.luau"], +[145646, "src/Rosetta/image/png/Decode.luau"], +[146019, "src/Rosetta/image/png/Encode.luau"], +[146222, "src/Rosetta/image/pnm/init.luau"], +[146600, "src/Rosetta/image/pnm/Codec.luau"], +[146877, "src/Rosetta/image/qoi/init.luau"], +[146999, "src/Rosetta/image/qoi/Codec.luau"], +[147156, "src/Rosetta/image/sgi/init.luau"], +[147441, "src/Rosetta/image/spr/init.luau"], +[147754, "src/Rosetta/image/sunras/init.luau"], +[148000, "src/Rosetta/image/tga/init.luau"], +[148270, "src/Rosetta/image/tga/Codec.luau"], +[148470, "src/Rosetta/image/tiff/init.luau"], +[149297, "src/Rosetta/image/tiff/Pixels.luau"], +[149687, "src/Rosetta/image/tim/init.luau"], +[149929, "src/Rosetta/image/vtf/init.luau"], +[150164, "src/Rosetta/image/webp/init.luau"], +[150774, "src/Rosetta/image/webp/Alpha.luau"], +[150850, "src/Rosetta/image/webp/Anim.luau"], +[151005, "src/Rosetta/image/xbm/init.luau"], +[151166, "src/Rosetta/image/xpm/init.luau"], +[151434, "src/Rosetta/image/xpm/Names.luau"], +[151490, "src/Rosetta/layered/aseprite/init.luau"], +[152228, "src/Rosetta/layered/ora/init.luau"], +[152515, "src/Rosetta/layered/psd/init.luau"], +[153250, "src/Rosetta/layered/psd/Channels.luau"], +[153602, "src/Rosetta/model/3ds/init.luau"], +[153685, "src/Rosetta/model/3ds/Build.luau"], +[154332, "src/Rosetta/model/3ds/Read.luau"], +[154828, "src/Rosetta/model/3ds/Write.luau"], +[155633, "src/Rosetta/model/3mf/init.luau"], +[155715, "src/Rosetta/model/3mf/Read.luau"], +[156303, "src/Rosetta/model/3mf/Write.luau"], +[156708, "src/Rosetta/model/ase/init.luau"], +[156831, "src/Rosetta/model/ase/Build.luau"], +[157405, "src/Rosetta/model/ase/Parse.luau"], +[157474, "src/Rosetta/model/ase/Write.luau"], +[157937, "src/Rosetta/model/b3d/init.luau"], +[157992, "src/Rosetta/model/b3d/Read.luau"], +[158563, "src/Rosetta/model/blend/init.luau"], +[158659, "src/Rosetta/model/blend/Anim.luau"], +[159005, "src/Rosetta/model/blend/Material.luau"], +[159357, "src/Rosetta/model/blend/Mesh.luau"], +[159992, "src/Rosetta/model/blend/Normals.luau"], +[160153, "src/Rosetta/model/blend/Prim.luau"], +[160602, "src/Rosetta/model/blend/Read.luau"], +[161502, "src/Rosetta/model/bsp/init.luau"], +[161693, "src/Rosetta/model/bsp/Lightmap.luau"], +[161759, "src/Rosetta/model/bsp/Quake.luau"], +[162148, "src/Rosetta/model/bsp/Quake3.luau"], +[162377, "src/Rosetta/model/bsp/Tree.luau"], +[162765, "src/Rosetta/model/buildmap/init.luau"], +[163037, "src/Rosetta/model/buildmap/Geometry.luau"], +[163440, "src/Rosetta/model/d3map/init.luau"], +[163722, "src/Rosetta/model/d3map/Parse.luau"], +[163920, "src/Rosetta/model/dae/init.luau"], +[164109, "src/Rosetta/model/dae/Math.luau"], +[164156, "src/Rosetta/model/dae/Read.luau"], +[166006, "src/Rosetta/model/dae/Write.luau"], +[166375, "src/Rosetta/model/fbx/init.luau"], +[166523, "src/Rosetta/model/fbx/Ascii.luau"], +[166793, "src/Rosetta/model/fbx/Binary.luau"], +[167248, "src/Rosetta/model/fbx/Read.luau"], +[168610, "src/Rosetta/model/fbx/Write.luau"], +[169595, "src/Rosetta/model/fbx/Xform.luau"], +[169636, "src/Rosetta/model/gltf/init.luau"], +[169873, "src/Rosetta/model/gltf/Pack.luau"], +[169942, "src/Rosetta/model/gltf/Read.luau"], +[170673, "src/Rosetta/model/gltf/Write.luau"], +[171353, "src/Rosetta/model/godot/init.luau"], +[171444, "src/Rosetta/model/godot/Build.luau"], +[171986, "src/Rosetta/model/godot/Primitives.luau"], +[172261, "src/Rosetta/model/godot/Surface.luau"], +[172746, "src/Rosetta/model/godot/Write.luau"], +[173075, "src/Rosetta/model/iqm/init.luau"], +[173151, "src/Rosetta/model/iqm/Read.luau"], +[173506, "src/Rosetta/model/iqm/Write.luau"], +[174193, "src/Rosetta/model/ldraw/init.luau"], +[174271, "src/Rosetta/model/ldraw/Colors.luau"], +[174589, "src/Rosetta/model/ldraw/Read.luau"], +[175166, "src/Rosetta/model/lwo/init.luau"], +[175242, "src/Rosetta/model/lwo/Build.luau"], +[175704, "src/Rosetta/model/lwo/Parse.luau"], +[176247, "src/Rosetta/model/map/init.luau"], +[176564, "src/Rosetta/model/map/Build.luau"], +[176808, "src/Rosetta/model/map/Parse.luau"], +[177193, "src/Rosetta/model/map/Write.luau"], +[177339, "src/Rosetta/model/mca/init.luau"], +[177681, "src/Rosetta/model/mca/Chunk.luau"], +[177814, "src/Rosetta/model/mca/Lz4Block.luau"], +[177884, "src/Rosetta/model/md2/init.luau"], +[178083, "src/Rosetta/model/md3/init.luau"], +[178311, "src/Rosetta/model/md5/init.luau"], +[178392, "src/Rosetta/model/md5/Read.luau"], +[178825, "src/Rosetta/model/mdl/init.luau"], +[178907, "src/Rosetta/model/mdl/HalfLife.luau"], +[179211, "src/Rosetta/model/mdl/Quake.luau"], +[179429, "src/Rosetta/model/ms3d/init.luau"], +[179501, "src/Rosetta/model/ms3d/Read.luau"], +[179947, "src/Rosetta/model/ms3d/Write.luau"], +[180416, "src/Rosetta/model/obj/init.luau"], +[181234, "src/Rosetta/model/obj/Mtl.luau"], +[181522, "src/Rosetta/model/off/init.luau"], +[181984, "src/Rosetta/model/ply/init.luau"], +[183089, "src/Rosetta/model/ply/Binary.luau"], +[183290, "src/Rosetta/model/pmx/init.luau"], +[183359, "src/Rosetta/model/pmx/Build.luau"], +[183655, "src/Rosetta/model/pmx/Pmd.luau"], +[183990, "src/Rosetta/model/pmx/Read.luau"], +[184394, "src/Rosetta/model/proc/init.luau"], +[184776, "src/Rosetta/model/qb/init.luau"], +[185169, "src/Rosetta/model/rbxm/init.luau"], +[185762, "src/Rosetta/model/rbxmx/init.luau"], +[186438, "src/Rosetta/model/robloxmesh/init.luau"], +[187097, "src/Rosetta/model/robloxmesh/Parse.luau"], +[187554, "src/Rosetta/model/robloxmesh/Write.luau"], +[187663, "src/Rosetta/model/schematic/init.luau"], +[187984, "src/Rosetta/model/schematic/Common.luau"], +[188104, "src/Rosetta/model/schematic/Litematic.luau"], +[188315, "src/Rosetta/model/schematic/Mcedit.luau"], +[188559, "src/Rosetta/model/schematic/Sponge.luau"], +[188688, "src/Rosetta/model/smd/init.luau"], +[188755, "src/Rosetta/model/smd/Read.luau"], +[189024, "src/Rosetta/model/smd/Write.luau"], +[189267, "src/Rosetta/model/sourcemdl/init.luau"], +[189438, "src/Rosetta/model/sourcemdl/Build.luau"], +[189868, "src/Rosetta/model/sourcemdl/Material.luau"], +[190029, "src/Rosetta/model/sourcemdl/Mdl.luau"], +[190556, "src/Rosetta/model/sourcemdl/Phy.luau"], +[190679, "src/Rosetta/model/sourcemdl/Vtx.luau"], +[190861, "src/Rosetta/model/sourcemdl/Vvd.luau"], +[190955, "src/Rosetta/model/stl/init.luau"], +[191405, "src/Rosetta/model/stl/Decode.luau"], +[191479, "src/Rosetta/model/t3d/init.luau"], +[191573, "src/Rosetta/model/t3d/Build.luau"], +[191978, "src/Rosetta/model/t3d/Parse.luau"], +[192146, "src/Rosetta/model/udmf/init.luau"], +[192229, "src/Rosetta/model/usda/init.luau"], +[192438, "src/Rosetta/model/usda/Build.luau"], +[193716, "src/Rosetta/model/usda/Parse.luau"], +[194514, "src/Rosetta/model/usda/Write.luau"], +[195331, "src/Rosetta/model/vbsp/init.luau"], +[195777, "src/Rosetta/model/vbsp/Faces.luau"], +[196001, "src/Rosetta/model/vbsp/Props.luau"], +[196093, "src/Rosetta/model/vmf/init.luau"], +[196418, "src/Rosetta/model/vmf/Build.luau"], +[196842, "src/Rosetta/model/vox/init.luau"], +[197728, "src/Rosetta/model/vox/Grid.luau"], +[197785, "src/Rosetta/model/vrml/init.luau"], +[197851, "src/Rosetta/model/x/init.luau"], +[197981, "src/Rosetta/model/x/Build.luau"], +[198544, "src/Rosetta/model/x/Parse.luau"], +[198841, "src/Rosetta/model/x3d/init.luau"], +[198919, "src/Rosetta/music/669/init.luau"], +[199126, "src/Rosetta/music/ahx/init.luau"], +[199178, "src/Rosetta/music/far/init.luau"], +[199408, "src/Rosetta/music/hmp/init.luau"], +[199673, "src/Rosetta/music/hvl/init.luau"], +[199725, "src/Rosetta/music/it/init.luau"], +[200144, "src/Rosetta/music/it/Itsex.luau"], +[200261, "src/Rosetta/music/med/init.luau"], +[200909, "src/Rosetta/music/midi/init.luau"], +[201053, "src/Rosetta/music/midi/Smf.luau"], +[201465, "src/Rosetta/music/mod/init.luau"], +[201819, "src/Rosetta/music/mtm/init.luau"], +[202042, "src/Rosetta/music/mus/init.luau"], +[202200, "src/Rosetta/music/okt/init.luau"], +[202482, "src/Rosetta/music/ptm/init.luau"], +[202705, "src/Rosetta/music/s3m/init.luau"], +[202942, "src/Rosetta/music/sf2/init.luau"], +[202986, "src/Rosetta/music/stm/init.luau"], +[203218, "src/Rosetta/music/ult/init.luau"], +[203523, "src/Rosetta/music/umx/init.luau"], +[203740, "src/Rosetta/music/xm/init.luau"], +[204302, "src/Rosetta/music/xmi/init.luau"], +[204511, "src/Rosetta/ops/AudioOps.luau"], +[204990, "src/Rosetta/ops/ImageOps/init.luau"], +[205638, "src/Rosetta/ops/ImageOps/Kernels.luau"], +[206278, "src/Rosetta/ops/LayerOps.luau"], +[206371, "src/Rosetta/ops/MeshOps/init.luau"], +[207423, "src/Rosetta/ops/MeshOps/Greedy.luau"], +[207590, "src/Rosetta/ops/MusicOps.luau"], +[207939, "src/Rosetta/playlist/m3u/init.luau"], +[208292, "src/Rosetta/playlist/pls/init.luau"], +[208470, "src/Rosetta/playlist/xspf/init.luau"], +[208673, "src/Rosetta/subtitle/ass/init.luau"], +[209117, "src/Rosetta/subtitle/srt/init.luau"], +[209290, "src/Rosetta/subtitle/vtt/init.luau"], +[209493, "src/Rosetta/vector/gamemaps/init.luau"], +[209680, "src/Rosetta/vector/gamemaps/Expand.luau"], +[209777, "src/Rosetta/vector/ldtk/init.luau"], +[209869, "src/Rosetta/vector/ldtk/Read.luau"], +[210205, "src/Rosetta/vector/ldtk/Write.luau"], +[210853, "src/Rosetta/vector/ogmo/init.luau"], +[210972, "src/Rosetta/vector/ogmo/Read.luau"], +[211377, "src/Rosetta/vector/ogmo/Write.luau"], +[211731, "src/Rosetta/vector/svg/init.luau"], +[211817, "src/Rosetta/vector/svg/Parse.luau"], +[212563, "src/Rosetta/vector/svg/PathData.luau"], +[212931, "src/Rosetta/vector/svg/Render.luau"], +[213348, "src/Rosetta/vector/svg/Style.luau"], +[213720, "src/Rosetta/vector/svg/Write.luau"], +[213920, "src/Rosetta/vector/tiled/init.luau"], +[214100, "src/Rosetta/vector/tiled/Data.luau"], +[214251, "src/Rosetta/vector/tiled/Tmj.luau"], +[214882, "src/Rosetta/vector/tiled/Tmx.luau"], +[215494, "src/Rosetta/video/avi/init.luau"], +[215788, "src/Rosetta/video/fli/init.luau"], +[215939, "src/Rosetta/video/flv/init.luau"], +[216323, "src/Rosetta/video/flv/Amf.luau"], +[216481, "src/Rosetta/video/flv/Mux.luau"], +[216762, "src/Rosetta/video/h264/init.luau"], +[216901, "src/Rosetta/video/mkv/init.luau"], +[217057, "src/Rosetta/video/mkv/Mux.luau"], +[217336, "src/Rosetta/video/mkv/Parse.luau"], +[218057, "src/Rosetta/video/mp4/init.luau"], +[218385, "src/Rosetta/video/mpegps/init.luau"], +[218572, "src/Rosetta/video/mpegts/init.luau"], +[218818, "src/Rosetta/video/ogv/init.luau"], +[219213, "src/Rosetta/video/smk/init.luau"], +[219522, "src/Rosetta/video/smk/Audio.luau"], +[219642, "src/Rosetta/video/y4m/init.luau"] ] diff --git a/build/Rosetta.rbxm b/build/Rosetta.rbxm index 14fe6cc6a1a872860c89c824f08d31a87e55809f..c1c44df5853ccd9db737ae177615130344473a5a 100644 GIT binary patch delta 19756 zcmcbAZa3r2^Sc>0#4xexKGkDLlxR+3YENQfY)@hW(ah~hOf1`zm{=EaF&^H|%F7zh zSU({-Co#7`M7lTW2W_sRP7lx_KjDNYAy%+?_ zqgk09xL6|X807TX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LcUkoW^^fr>FbJC}FsK+Mu4Q1UVWRR#tjarPVrCRGMOLrFK~%#zX)raO#+ z$&Zv6=7835GpwGZP+~A+y3l=AWhJ$#T=k3s1-v3G#~GNOF)%D-WI8IrF#W$na$(_37dFS%Z|?Cz+=dx(M={rxZH!F|c|FFv`fX%;#c^pTrcM%`3~yC_4T0eby4D z5a#KQ4_M^{TP`w8V&H!$%FJ+(fk8!x{q^*M2dvsUOcE>%k_`MTj7$u+49u}2ELMz+ zyo?OS3~alELDS4<7}!-97!)}8gBe(-pMSt=rX2K|F<(T9lQWb-Mb}n_pJ5R*!yX2P zb;8Vxn3>uc7*_~07);lA$hw}7et3b(D36^d80){<){IgcGFzK_MSQ{7w5+ei!GTj9QGCxiid&0WkKzcv31p|K< z0|UcMFNS&*<}(aTD zebWn8H%3PH=|5kxrZaX;PkhCi!x*#u+$&abM#k6EpS@<)Va%H@{D#$qovDaN$Vg9Y zdg2?_BaD92)!wpNG47e3_?9(~$%kY5#kZ`F8Kb6eeaCu|@xb=__pIzJjPs|re`cM< z_Q`Hl4~GpmV?f)VrfJ-=A385w76|M8o(myvPl_O`#QX)KJtroUxmQ((;6&d0=N z%Eb6~y9*1OhCGw;^6h!bY?_in0hT%nMkd_znJgFt%q hi then error("max must be greater than or equal to min", 2) end if x ~= x then return x end return mmin(mmax(x, lo), hi) @@ -71838,7 +71843,7 @@ local __compat = __compat local buffer = __compat.buffer --!strict -- libjpeg's islow (jidctint.c / jfdctint.c), the reduced IDCTs (jidctred.c) and jcdctmgr.c's rounding quantiser, bit-exact -- with libjpeg-turbo. From jpeg-luau 1.0 (same author); IJG code: licenses/libjpeg-turbo-LICENSE.md. local readi16, readu16, writeu16, writeu32, readu8, writei16 = buffer.readi16, buffer.readu16, buffer.writeu16, buffer.writeu32, buffer.readu8, buffer.writei16 -local clamp = math.clamp +local clamp, abs, sign = math.clamp, math.abs, math.sign local Dct = {} @@ -72217,17 +72222,12 @@ end local fw = table.create(64, 0) -local function quant(coef, off, div, v, i) - local qv = readu16(div, i * 2) * 8 - local h = math.floor(qv / 2 -) if v < 0 then - writei16(coef, off + i * 2, -(math.floor((h - v) / qv))) - else - writei16(coef, off + i * 2, math.floor((v + h) / qv)) - end +-- (|v| + q * 4) // (q * 8) with v's sign, branch-free (a sign branch here gave LuaJIT side traces it could not compile) +local function quant(coef, off, qv, v, i) + writei16(coef, off + i * 2, math.floor((abs(v) + qv / 2) / qv )* sign(v)) end --- quantised as jcdctmgr.c: (|v| + q * 4) // (q * 8) with the sign restored +-- quantised as jcdctmgr.c: (|v| + q * 4) // (q * 8) with the sign restored; div[i + 1] = q * 8 for natural index i function Dct.fdctQuantize(src, stride, x, y, w, h, div, coef, off) local lastX, lastY = w - 1, h - 1 for r = 0, 7 do @@ -72317,14 +72317,14 @@ else ) local o3 = math.floor((tmp6 + z2 + z3 + 16384) / 32768 ) local o1 = math.floor((tmp7 + z1 + z4 + 16384) / 32768 ) local cc = c - 1 - quant(coef, off, div, o0, cc) - quant(coef, off, div, o1, cc + 8) - quant(coef, off, div, o2, cc + 16) - quant(coef, off, div, o3, cc + 24) - quant(coef, off, div, o4, cc + 32) - quant(coef, off, div, o5, cc + 40) - quant(coef, off, div, o6, cc + 48) - quant(coef, off, div, o7, cc + 56) + quant(coef, off, div[c], o0, cc) + quant(coef, off, div[c + 8], o1, cc + 8) + quant(coef, off, div[c + 16], o2, cc + 16) + quant(coef, off, div[c + 24], o3, cc + 24) + quant(coef, off, div[c + 32], o4, cc + 32) + quant(coef, off, div[c + 40], o5, cc + 40) + quant(coef, off, div[c + 48], o6, cc + 48) + quant(coef, off, div[c + 56], o7, cc + 56) end end @@ -75187,11 +75187,11 @@ OUT = buffer.create(math.max(1024, math.floor(w * h / 2))) local qt = { Tables.quant(Tables.LUMA, o.quality), Tables.quant(Tables.CHROMA, o.quality) } local qdiv = {} for t = 1, 2 do - local b = buffer.create(128) + local d = table.create(64, 0) for i = 1, 64 do - writeu16(b, (i - 1) * 2, qt[t][i]) + d[i] = qt[t][i] * 8 end - qdiv[t] = b + qdiv[t] = d end local comps= {} diff --git a/build/rosetta.lua.linemap.json b/build/rosetta.lua.linemap.json index 1f5f820..9de4308 100644 --- a/build/rosetta.lua.linemap.json +++ b/build/rosetta.lua.linemap.json @@ -1,194 +1,194 @@ [ -[666, "src/Rosetta/init.luau"], -[1550, "src/Rosetta/Registry.luau"], -[3959, "src/Rosetta/Types.luau"], -[5072, "src/Rosetta/archive/7z/init.luau"], -[5457, "src/Rosetta/archive/7z/Header.luau"], -[5984, "src/Rosetta/archive/adf/init.luau"], -[6266, "src/Rosetta/archive/applesingle/init.luau"], -[6452, "src/Rosetta/archive/ar/init.luau"], -[6855, "src/Rosetta/archive/arj/init.luau"], -[7065, "src/Rosetta/archive/binhex/init.luau"], -[7314, "src/Rosetta/archive/br/init.luau"], -[7389, "src/Rosetta/archive/bz2/init.luau"], -[7453, "src/Rosetta/archive/cab/init.luau"], -[7866, "src/Rosetta/archive/cab/Sum.luau"], -[7907, "src/Rosetta/archive/cpio/init.luau"], -[8075, "src/Rosetta/archive/d64/init.luau"], -[8489, "src/Rosetta/archive/fat/init.luau"], -[8611, "src/Rosetta/archive/grp/init.luau"], -[8725, "src/Rosetta/archive/gzip/init.luau"], -[8910, "src/Rosetta/archive/iso/init.luau"], -[8982, "src/Rosetta/archive/lha/init.luau"], -[9407, "src/Rosetta/archive/lz4/init.luau"], -[9751, "src/Rosetta/archive/macbinary/init.luau"], -[9949, "src/Rosetta/archive/mpq/init.luau"], -[10355, "src/Rosetta/archive/mpq/Crypt.luau"], -[10420, "src/Rosetta/archive/pak/init.luau"], -[10554, "src/Rosetta/archive/rpm/init.luau"], -[10878, "src/Rosetta/archive/tar/init.luau"], -[10996, "src/Rosetta/archive/unitypackage/init.luau"], -[11232, "src/Rosetta/archive/uu/init.luau"], -[11502, "src/Rosetta/archive/vpk/init.luau"], -[11813, "src/Rosetta/archive/vswap/init.luau"], -[12083, "src/Rosetta/archive/wad/init.luau"], -[12537, "src/Rosetta/archive/wad/Picture.luau"], -[12639, "src/Rosetta/archive/wad2/init.luau"], -[12921, "src/Rosetta/archive/xz/init.luau"], -[13021, "src/Rosetta/archive/yenc/init.luau"], -[13293, "src/Rosetta/archive/z/init.luau"], -[13389, "src/Rosetta/archive/zip/init.luau"], -[13608, "src/Rosetta/archive/zoo/init.luau"], -[13804, "src/Rosetta/archive/zst/init.luau"], -[13868, "src/Rosetta/audio/aac/init.luau"], -[14081, "src/Rosetta/audio/ac3/init.luau"], -[14228, "src/Rosetta/audio/adpcm/init.luau"], -[14374, "src/Rosetta/audio/adx/init.luau"], -[14606, "src/Rosetta/audio/aiff/init.luau"], -[14998, "src/Rosetta/audio/ape/init.luau"], -[15127, "src/Rosetta/audio/au/init.luau"], -[15289, "src/Rosetta/audio/brstm/init.luau"], -[15581, "src/Rosetta/audio/caf/init.luau"], -[16248, "src/Rosetta/audio/flac/init.luau"], -[16397, "src/Rosetta/audio/flac/Meta.luau"], -[16619, "src/Rosetta/audio/flac/Stream.luau"], -[16989, "src/Rosetta/audio/m4a/init.luau"], -[17332, "src/Rosetta/audio/mp3/init.luau"], -[17593, "src/Rosetta/audio/mp3/Index.luau"], -[17784, "src/Rosetta/audio/mp3/Stream.luau"], -[18011, "src/Rosetta/audio/mp3/Tags.luau"], -[18323, "src/Rosetta/audio/mpc/init.luau"], -[18418, "src/Rosetta/audio/opus/init.luau"], -[18797, "src/Rosetta/audio/opus/Encode.luau"], -[18909, "src/Rosetta/audio/qoa/init.luau"], -[19090, "src/Rosetta/audio/tta/init.luau"], -[19209, "src/Rosetta/audio/vag/init.luau"], -[19433, "src/Rosetta/audio/voc/init.luau"], -[19709, "src/Rosetta/audio/vorbis/init.luau"], -[20164, "src/Rosetta/audio/vorbis/Encode.luau"], -[20977, "src/Rosetta/audio/wav/init.luau"], -[21598, "src/Rosetta/audio/wav/Codecs.luau"], -[21777, "src/Rosetta/audio/wavpack/init.luau"], -[21985, "src/Rosetta/cad/step/init.luau"], -[22367, "src/Rosetta/cad/step/Brep.luau"], -[22602, "src/Rosetta/cad/step/Parse.luau"], -[23159, "src/Rosetta/cad/step/Write.luau"], -[23407, "src/Rosetta/codecs/audio/Aac/init.luau"], -[23815, "src/Rosetta/codecs/audio/Aac/Decode.luau"], -[24791, "src/Rosetta/codecs/audio/Aac/Ps.luau"], -[25381, "src/Rosetta/codecs/audio/Aac/Sbr.luau"], -[26448, "src/Rosetta/codecs/audio/Aac/SbrBits.luau"], -[26567, "src/Rosetta/codecs/audio/Aac/SbrDct.luau"], -[27809, "src/Rosetta/codecs/audio/Aac/SbrHf.luau"], -[28301, "src/Rosetta/codecs/audio/Aac/SbrQmf.luau"], -[28418, "src/Rosetta/codecs/audio/Aac/SbrTables.luau"], -[28831, "src/Rosetta/codecs/audio/Aac/Tables.luau"], -[29167, "src/Rosetta/codecs/audio/Ac3/init.luau"], -[29327, "src/Rosetta/codecs/audio/Ac3/Decode.luau"], -[30212, "src/Rosetta/codecs/audio/Ac3/Tables.luau"], -[30314, "src/Rosetta/codecs/audio/Adpcm/init.luau"], -[31068, "src/Rosetta/codecs/audio/Adpcm/Decoder.luau"], -[31371, "src/Rosetta/codecs/audio/Alac/init.luau"], -[31606, "src/Rosetta/codecs/audio/Alac/Decode.luau"], -[32025, "src/Rosetta/codecs/audio/Alac/Encode.luau"], -[32437, "src/Rosetta/codecs/audio/Ape/init.luau"], -[32653, "src/Rosetta/codecs/audio/Ape/Decode.luau"], -[33414, "src/Rosetta/codecs/audio/ApeTag.luau"], -[33512, "src/Rosetta/codecs/audio/Flac/init.luau"], -[33524, "src/Rosetta/codecs/audio/Flac/Encode.luau"], -[34473, "src/Rosetta/codecs/audio/Flac/Frame.luau"], -[35093, "src/Rosetta/codecs/audio/Hively/init.luau"], -[35290, "src/Rosetta/codecs/audio/Hively/Load.luau"], -[35540, "src/Rosetta/codecs/audio/Hively/Player.luau"], -[36499, "src/Rosetta/codecs/audio/Hively/Tables.luau"], -[36719, "src/Rosetta/codecs/audio/Mdct/init.luau"], -[36939, "src/Rosetta/codecs/audio/Mdct/Fft.luau"], -[37193, "src/Rosetta/codecs/audio/MidiRender.luau"], -[37540, "src/Rosetta/codecs/audio/Mpa/init.luau"], -[37555, "src/Rosetta/codecs/audio/Mpa/Analysis.luau"], -[37614, "src/Rosetta/codecs/audio/Mpa/Core.luau"], -[39272, "src/Rosetta/codecs/audio/Mpa/EncTables.luau"], -[39565, "src/Rosetta/codecs/audio/Mpa/Encode2.luau"], -[39950, "src/Rosetta/codecs/audio/Mpa/Encode3.luau"], -[40591, "src/Rosetta/codecs/audio/Mpa/Header.luau"], -[40732, "src/Rosetta/codecs/audio/Mpa/Tables.luau"], -[40959, "src/Rosetta/codecs/audio/Musepack/init.luau"], -[41305, "src/Rosetta/codecs/audio/Musepack/Decode.luau"], -[42199, "src/Rosetta/codecs/audio/Musepack/Tables.luau"], -[42578, "src/Rosetta/codecs/audio/Opus/init.luau"], -[42593, "src/Rosetta/codecs/audio/Opus/Celt.luau"], -[44465, "src/Rosetta/codecs/audio/Opus/CeltEncoder.luau"], -[45530, "src/Rosetta/codecs/audio/Opus/CeltTables.luau"], -[45591, "src/Rosetta/codecs/audio/Opus/Decoder.luau"], -[46055, "src/Rosetta/codecs/audio/Opus/Mdct.luau"], -[46406, "src/Rosetta/codecs/audio/Opus/Packet.luau"], -[46639, "src/Rosetta/codecs/audio/Opus/Silk.luau"], -[48681, "src/Rosetta/codecs/audio/Opus/SilkTables.luau"], -[49055, "src/Rosetta/codecs/audio/Pcm/init.luau"], -[49319, "src/Rosetta/codecs/audio/Pcm/Convert.luau"], -[49616, "src/Rosetta/codecs/audio/Qoa/init.luau"], -[49898, "src/Rosetta/codecs/audio/Resample/init.luau"], -[50293, "src/Rosetta/codecs/audio/SoundFont/init.luau"], -[50348, "src/Rosetta/codecs/audio/SoundFont/Fallback.luau"], -[50492, "src/Rosetta/codecs/audio/SoundFont/Parse.luau"], -[51006, "src/Rosetta/codecs/audio/SoundFont/Synth.luau"], -[51805, "src/Rosetta/codecs/audio/Stream.luau"], -[51967, "src/Rosetta/codecs/audio/Tracker/init.luau"], -[52450, "src/Rosetta/codecs/audio/Tracker/Load.luau"], -[52729, "src/Rosetta/codecs/audio/Tracker/Mixer.luau"], -[52976, "src/Rosetta/codecs/audio/Tracker/Pcm.luau"], -[53105, "src/Rosetta/codecs/audio/Tracker/Player.luau"], -[55094, "src/Rosetta/codecs/audio/Tracker/Tables.luau"], -[55211, "src/Rosetta/codecs/audio/Tta/init.luau"], -[55329, "src/Rosetta/codecs/audio/Tta/Decode.luau"], -[55581, "src/Rosetta/codecs/audio/Vorbis/init.luau"], -[55595, "src/Rosetta/codecs/audio/Vorbis/Codebook.luau"], -[55979, "src/Rosetta/codecs/audio/Vorbis/Packet.luau"], -[56552, "src/Rosetta/codecs/audio/Vorbis/Setup.luau"], -[56974, "src/Rosetta/codecs/audio/Vorbis/Tables.luau"], -[57014, "src/Rosetta/codecs/audio/VorbisComment.luau"], -[57067, "src/Rosetta/codecs/audio/WavPack/init.luau"], -[57290, "src/Rosetta/codecs/audio/WavPack/Block.luau"], -[58745, "src/Rosetta/codecs/audio/WavPack/Tables.luau"], -[58808, "src/Rosetta/codecs/compress/Brotli/init.luau"], -[58895, "src/Rosetta/codecs/compress/Brotli/Decode.luau"], -[59871, "src/Rosetta/codecs/compress/Brotli/Static.luau"], -[60739, "src/Rosetta/codecs/compress/Bzip2/init.luau"], -[60783, "src/Rosetta/codecs/compress/Bzip2/Decode.luau"], -[61296, "src/Rosetta/codecs/compress/Deflate/init.luau"], -[61622, "src/Rosetta/codecs/compress/Deflate/Compress.luau"], -[62104, "src/Rosetta/codecs/compress/Deflate/Inflate.luau"], -[62552, "src/Rosetta/codecs/compress/Explode.luau"], -[62748, "src/Rosetta/codecs/compress/Lz4.luau"], -[63017, "src/Rosetta/codecs/compress/Lzh/init.luau"], -[63621, "src/Rosetta/codecs/compress/Lzma/init.luau"], -[64161, "src/Rosetta/codecs/compress/Lzma/Crc64.luau"], -[64228, "src/Rosetta/codecs/compress/Lzma/Decode.luau"], -[64701, "src/Rosetta/codecs/compress/Lzma/Filters.luau"], -[64877, "src/Rosetta/codecs/compress/Lzw/init.luau"], -[65145, "src/Rosetta/codecs/compress/Lzx.luau"], -[65579, "src/Rosetta/codecs/compress/PackBits.luau"], -[65669, "src/Rosetta/codecs/compress/Quantum.luau"], -[65906, "src/Rosetta/codecs/compress/UnixCompress.luau"], -[66210, "src/Rosetta/codecs/compress/Xxh32.luau"], -[66279, "src/Rosetta/codecs/compress/Zstd/init.luau"], -[66336, "src/Rosetta/codecs/compress/Zstd/Decode.luau"], -[67320, "src/Rosetta/codecs/compress/Zstd/Xxh64.luau"], -[67472, "src/Rosetta/codecs/entropy/Huffman.luau"], -[67759, "src/Rosetta/codecs/entropy/RangeCoder/init.luau"], -[67770, "src/Rosetta/codecs/entropy/RangeCoder/Decoder.luau"], -[67991, "src/Rosetta/codecs/entropy/RangeCoder/Encoder.luau"], -[68235, "src/Rosetta/codecs/font/Bitmap.luau"], -[68436, "src/Rosetta/codecs/font/Cff/init.luau"], -[69077, "src/Rosetta/codecs/font/GlyphNames.luau"], -[69227, "src/Rosetta/codecs/font/TrueType/init.luau"], -[69541, "src/Rosetta/codecs/font/TrueType/Glyf.luau"], -[69933, "src/Rosetta/codecs/font/TrueType/Tables.luau"], -[70435, "src/Rosetta/codecs/image/Bcn/init.luau"], -[70542, "src/Rosetta/codecs/image/Bcn/Decode.luau"], -[71026, "src/Rosetta/codecs/image/Bcn/Encode.luau"], -[71455, "src/Rosetta/codecs/image/Blend.luau"], -[71834, "src/Rosetta/codecs/image/Dct/init.luau"], +[671, "src/Rosetta/init.luau"], +[1555, "src/Rosetta/Registry.luau"], +[3964, "src/Rosetta/Types.luau"], +[5077, "src/Rosetta/archive/7z/init.luau"], +[5462, "src/Rosetta/archive/7z/Header.luau"], +[5989, "src/Rosetta/archive/adf/init.luau"], +[6271, "src/Rosetta/archive/applesingle/init.luau"], +[6457, "src/Rosetta/archive/ar/init.luau"], +[6860, "src/Rosetta/archive/arj/init.luau"], +[7070, "src/Rosetta/archive/binhex/init.luau"], +[7319, "src/Rosetta/archive/br/init.luau"], +[7394, "src/Rosetta/archive/bz2/init.luau"], +[7458, "src/Rosetta/archive/cab/init.luau"], +[7871, "src/Rosetta/archive/cab/Sum.luau"], +[7912, "src/Rosetta/archive/cpio/init.luau"], +[8080, "src/Rosetta/archive/d64/init.luau"], +[8494, "src/Rosetta/archive/fat/init.luau"], +[8616, "src/Rosetta/archive/grp/init.luau"], +[8730, "src/Rosetta/archive/gzip/init.luau"], +[8915, "src/Rosetta/archive/iso/init.luau"], +[8987, "src/Rosetta/archive/lha/init.luau"], +[9412, "src/Rosetta/archive/lz4/init.luau"], +[9756, "src/Rosetta/archive/macbinary/init.luau"], +[9954, "src/Rosetta/archive/mpq/init.luau"], +[10360, "src/Rosetta/archive/mpq/Crypt.luau"], +[10425, "src/Rosetta/archive/pak/init.luau"], +[10559, "src/Rosetta/archive/rpm/init.luau"], +[10883, "src/Rosetta/archive/tar/init.luau"], +[11001, "src/Rosetta/archive/unitypackage/init.luau"], +[11237, "src/Rosetta/archive/uu/init.luau"], +[11507, "src/Rosetta/archive/vpk/init.luau"], +[11818, "src/Rosetta/archive/vswap/init.luau"], +[12088, "src/Rosetta/archive/wad/init.luau"], +[12542, "src/Rosetta/archive/wad/Picture.luau"], +[12644, "src/Rosetta/archive/wad2/init.luau"], +[12926, "src/Rosetta/archive/xz/init.luau"], +[13026, "src/Rosetta/archive/yenc/init.luau"], +[13298, "src/Rosetta/archive/z/init.luau"], +[13394, "src/Rosetta/archive/zip/init.luau"], +[13613, "src/Rosetta/archive/zoo/init.luau"], +[13809, "src/Rosetta/archive/zst/init.luau"], +[13873, "src/Rosetta/audio/aac/init.luau"], +[14086, "src/Rosetta/audio/ac3/init.luau"], +[14233, "src/Rosetta/audio/adpcm/init.luau"], +[14379, "src/Rosetta/audio/adx/init.luau"], +[14611, "src/Rosetta/audio/aiff/init.luau"], +[15003, "src/Rosetta/audio/ape/init.luau"], +[15132, "src/Rosetta/audio/au/init.luau"], +[15294, "src/Rosetta/audio/brstm/init.luau"], +[15586, "src/Rosetta/audio/caf/init.luau"], +[16253, "src/Rosetta/audio/flac/init.luau"], +[16402, "src/Rosetta/audio/flac/Meta.luau"], +[16624, "src/Rosetta/audio/flac/Stream.luau"], +[16994, "src/Rosetta/audio/m4a/init.luau"], +[17337, "src/Rosetta/audio/mp3/init.luau"], +[17598, "src/Rosetta/audio/mp3/Index.luau"], +[17789, "src/Rosetta/audio/mp3/Stream.luau"], +[18016, "src/Rosetta/audio/mp3/Tags.luau"], +[18328, "src/Rosetta/audio/mpc/init.luau"], +[18423, "src/Rosetta/audio/opus/init.luau"], +[18802, "src/Rosetta/audio/opus/Encode.luau"], +[18914, "src/Rosetta/audio/qoa/init.luau"], +[19095, "src/Rosetta/audio/tta/init.luau"], +[19214, "src/Rosetta/audio/vag/init.luau"], +[19438, "src/Rosetta/audio/voc/init.luau"], +[19714, "src/Rosetta/audio/vorbis/init.luau"], +[20169, "src/Rosetta/audio/vorbis/Encode.luau"], +[20982, "src/Rosetta/audio/wav/init.luau"], +[21603, "src/Rosetta/audio/wav/Codecs.luau"], +[21782, "src/Rosetta/audio/wavpack/init.luau"], +[21990, "src/Rosetta/cad/step/init.luau"], +[22372, "src/Rosetta/cad/step/Brep.luau"], +[22607, "src/Rosetta/cad/step/Parse.luau"], +[23164, "src/Rosetta/cad/step/Write.luau"], +[23412, "src/Rosetta/codecs/audio/Aac/init.luau"], +[23820, "src/Rosetta/codecs/audio/Aac/Decode.luau"], +[24796, "src/Rosetta/codecs/audio/Aac/Ps.luau"], +[25386, "src/Rosetta/codecs/audio/Aac/Sbr.luau"], +[26453, "src/Rosetta/codecs/audio/Aac/SbrBits.luau"], +[26572, "src/Rosetta/codecs/audio/Aac/SbrDct.luau"], +[27814, "src/Rosetta/codecs/audio/Aac/SbrHf.luau"], +[28306, "src/Rosetta/codecs/audio/Aac/SbrQmf.luau"], +[28423, "src/Rosetta/codecs/audio/Aac/SbrTables.luau"], +[28836, "src/Rosetta/codecs/audio/Aac/Tables.luau"], +[29172, "src/Rosetta/codecs/audio/Ac3/init.luau"], +[29332, "src/Rosetta/codecs/audio/Ac3/Decode.luau"], +[30217, "src/Rosetta/codecs/audio/Ac3/Tables.luau"], +[30319, "src/Rosetta/codecs/audio/Adpcm/init.luau"], +[31073, "src/Rosetta/codecs/audio/Adpcm/Decoder.luau"], +[31376, "src/Rosetta/codecs/audio/Alac/init.luau"], +[31611, "src/Rosetta/codecs/audio/Alac/Decode.luau"], +[32030, "src/Rosetta/codecs/audio/Alac/Encode.luau"], +[32442, "src/Rosetta/codecs/audio/Ape/init.luau"], +[32658, "src/Rosetta/codecs/audio/Ape/Decode.luau"], +[33419, "src/Rosetta/codecs/audio/ApeTag.luau"], +[33517, "src/Rosetta/codecs/audio/Flac/init.luau"], +[33529, "src/Rosetta/codecs/audio/Flac/Encode.luau"], +[34478, "src/Rosetta/codecs/audio/Flac/Frame.luau"], +[35098, "src/Rosetta/codecs/audio/Hively/init.luau"], +[35295, "src/Rosetta/codecs/audio/Hively/Load.luau"], +[35545, "src/Rosetta/codecs/audio/Hively/Player.luau"], +[36504, "src/Rosetta/codecs/audio/Hively/Tables.luau"], +[36724, "src/Rosetta/codecs/audio/Mdct/init.luau"], +[36944, "src/Rosetta/codecs/audio/Mdct/Fft.luau"], +[37198, "src/Rosetta/codecs/audio/MidiRender.luau"], +[37545, "src/Rosetta/codecs/audio/Mpa/init.luau"], +[37560, "src/Rosetta/codecs/audio/Mpa/Analysis.luau"], +[37619, "src/Rosetta/codecs/audio/Mpa/Core.luau"], +[39277, "src/Rosetta/codecs/audio/Mpa/EncTables.luau"], +[39570, "src/Rosetta/codecs/audio/Mpa/Encode2.luau"], +[39955, "src/Rosetta/codecs/audio/Mpa/Encode3.luau"], +[40596, "src/Rosetta/codecs/audio/Mpa/Header.luau"], +[40737, "src/Rosetta/codecs/audio/Mpa/Tables.luau"], +[40964, "src/Rosetta/codecs/audio/Musepack/init.luau"], +[41310, "src/Rosetta/codecs/audio/Musepack/Decode.luau"], +[42204, "src/Rosetta/codecs/audio/Musepack/Tables.luau"], +[42583, "src/Rosetta/codecs/audio/Opus/init.luau"], +[42598, "src/Rosetta/codecs/audio/Opus/Celt.luau"], +[44470, "src/Rosetta/codecs/audio/Opus/CeltEncoder.luau"], +[45535, "src/Rosetta/codecs/audio/Opus/CeltTables.luau"], +[45596, "src/Rosetta/codecs/audio/Opus/Decoder.luau"], +[46060, "src/Rosetta/codecs/audio/Opus/Mdct.luau"], +[46411, "src/Rosetta/codecs/audio/Opus/Packet.luau"], +[46644, "src/Rosetta/codecs/audio/Opus/Silk.luau"], +[48686, "src/Rosetta/codecs/audio/Opus/SilkTables.luau"], +[49060, "src/Rosetta/codecs/audio/Pcm/init.luau"], +[49324, "src/Rosetta/codecs/audio/Pcm/Convert.luau"], +[49621, "src/Rosetta/codecs/audio/Qoa/init.luau"], +[49903, "src/Rosetta/codecs/audio/Resample/init.luau"], +[50298, "src/Rosetta/codecs/audio/SoundFont/init.luau"], +[50353, "src/Rosetta/codecs/audio/SoundFont/Fallback.luau"], +[50497, "src/Rosetta/codecs/audio/SoundFont/Parse.luau"], +[51011, "src/Rosetta/codecs/audio/SoundFont/Synth.luau"], +[51810, "src/Rosetta/codecs/audio/Stream.luau"], +[51972, "src/Rosetta/codecs/audio/Tracker/init.luau"], +[52455, "src/Rosetta/codecs/audio/Tracker/Load.luau"], +[52734, "src/Rosetta/codecs/audio/Tracker/Mixer.luau"], +[52981, "src/Rosetta/codecs/audio/Tracker/Pcm.luau"], +[53110, "src/Rosetta/codecs/audio/Tracker/Player.luau"], +[55099, "src/Rosetta/codecs/audio/Tracker/Tables.luau"], +[55216, "src/Rosetta/codecs/audio/Tta/init.luau"], +[55334, "src/Rosetta/codecs/audio/Tta/Decode.luau"], +[55586, "src/Rosetta/codecs/audio/Vorbis/init.luau"], +[55600, "src/Rosetta/codecs/audio/Vorbis/Codebook.luau"], +[55984, "src/Rosetta/codecs/audio/Vorbis/Packet.luau"], +[56557, "src/Rosetta/codecs/audio/Vorbis/Setup.luau"], +[56979, "src/Rosetta/codecs/audio/Vorbis/Tables.luau"], +[57019, "src/Rosetta/codecs/audio/VorbisComment.luau"], +[57072, "src/Rosetta/codecs/audio/WavPack/init.luau"], +[57295, "src/Rosetta/codecs/audio/WavPack/Block.luau"], +[58750, "src/Rosetta/codecs/audio/WavPack/Tables.luau"], +[58813, "src/Rosetta/codecs/compress/Brotli/init.luau"], +[58900, "src/Rosetta/codecs/compress/Brotli/Decode.luau"], +[59876, "src/Rosetta/codecs/compress/Brotli/Static.luau"], +[60744, "src/Rosetta/codecs/compress/Bzip2/init.luau"], +[60788, "src/Rosetta/codecs/compress/Bzip2/Decode.luau"], +[61301, "src/Rosetta/codecs/compress/Deflate/init.luau"], +[61627, "src/Rosetta/codecs/compress/Deflate/Compress.luau"], +[62109, "src/Rosetta/codecs/compress/Deflate/Inflate.luau"], +[62557, "src/Rosetta/codecs/compress/Explode.luau"], +[62753, "src/Rosetta/codecs/compress/Lz4.luau"], +[63022, "src/Rosetta/codecs/compress/Lzh/init.luau"], +[63626, "src/Rosetta/codecs/compress/Lzma/init.luau"], +[64166, "src/Rosetta/codecs/compress/Lzma/Crc64.luau"], +[64233, "src/Rosetta/codecs/compress/Lzma/Decode.luau"], +[64706, "src/Rosetta/codecs/compress/Lzma/Filters.luau"], +[64882, "src/Rosetta/codecs/compress/Lzw/init.luau"], +[65150, "src/Rosetta/codecs/compress/Lzx.luau"], +[65584, "src/Rosetta/codecs/compress/PackBits.luau"], +[65674, "src/Rosetta/codecs/compress/Quantum.luau"], +[65911, "src/Rosetta/codecs/compress/UnixCompress.luau"], +[66215, "src/Rosetta/codecs/compress/Xxh32.luau"], +[66284, "src/Rosetta/codecs/compress/Zstd/init.luau"], +[66341, "src/Rosetta/codecs/compress/Zstd/Decode.luau"], +[67325, "src/Rosetta/codecs/compress/Zstd/Xxh64.luau"], +[67477, "src/Rosetta/codecs/entropy/Huffman.luau"], +[67764, "src/Rosetta/codecs/entropy/RangeCoder/init.luau"], +[67775, "src/Rosetta/codecs/entropy/RangeCoder/Decoder.luau"], +[67996, "src/Rosetta/codecs/entropy/RangeCoder/Encoder.luau"], +[68240, "src/Rosetta/codecs/font/Bitmap.luau"], +[68441, "src/Rosetta/codecs/font/Cff/init.luau"], +[69082, "src/Rosetta/codecs/font/GlyphNames.luau"], +[69232, "src/Rosetta/codecs/font/TrueType/init.luau"], +[69546, "src/Rosetta/codecs/font/TrueType/Glyf.luau"], +[69938, "src/Rosetta/codecs/font/TrueType/Tables.luau"], +[70440, "src/Rosetta/codecs/image/Bcn/init.luau"], +[70547, "src/Rosetta/codecs/image/Bcn/Decode.luau"], +[71031, "src/Rosetta/codecs/image/Bcn/Encode.luau"], +[71460, "src/Rosetta/codecs/image/Blend.luau"], +[71839, "src/Rosetta/codecs/image/Dct/init.luau"], [72334, "src/Rosetta/codecs/image/Etc.luau"], [72632, "src/Rosetta/codecs/image/Half.luau"], [72701, "src/Rosetta/codecs/image/Jpeg/init.luau"], diff --git a/compat/luajit.lua b/compat/luajit.lua index cd9745b..1bcf693 100644 --- a/compat/luajit.lua +++ b/compat/luajit.lua @@ -456,8 +456,13 @@ end do -- math.min / math.max are branch-free in a trace; an if / elseif clamp spawned side traces and ran ~3.5x slower. -- NaN stays NaN, as in Luau (maxsd would return lo). + -- Vararg (`...` unused): LuaJIT never starts a root trace at a vararg function but still inlines it into its + -- callers' traces. The plain clamp, called from interpreted code, started root traces that aborted on the return + -- into the caller's loop; enough aborts blacklist it, every trace that reaches a blacklisted function aborts too, and + -- in a long mixed process one codec left every clamp user interpreted (jpeg, webp, tiff 2-10x slower). Not done for + -- the others: a vararg math.sign made Monkey's Audio's sign-heavy filters ~40% slower. local mmin, mmax = math.min, math.max - math.clamp = math.clamp or function(x, lo, hi) + math.clamp = math.clamp or function(x, lo, hi, ...) if lo > hi then error("max must be greater than or equal to min", 2) end if x ~= x then return x end return mmin(mmax(x, lo), hi) diff --git a/src/Rosetta/codecs/image/Dct/init.luau b/src/Rosetta/codecs/image/Dct/init.luau index f8ce068..c661d8a 100644 --- a/src/Rosetta/codecs/image/Dct/init.luau +++ b/src/Rosetta/codecs/image/Dct/init.luau @@ -5,7 +5,7 @@ -- libjpeg's islow (jidctint.c / jfdctint.c), the reduced IDCTs (jidctred.c) and jcdctmgr.c's rounding quantiser, bit-exact -- with libjpeg-turbo. From jpeg-luau 1.0 (same author); IJG code: licenses/libjpeg-turbo-LICENSE.md. local readi16, readu16, writeu16, writeu32, readu8, writei16 = buffer.readi16, buffer.readu16, buffer.writeu16, buffer.writeu32, buffer.readu8, buffer.writei16 -local clamp = math.clamp +local clamp, abs, sign = math.clamp, math.abs, math.sign local Dct = {} @@ -384,18 +384,13 @@ end local fw = table.create(64, 0) -local function quant(coef: buffer, off: number, div: buffer, v: number, i: number) - local qv = readu16(div, i * 2) * 8 - local h = qv // 2 - if v < 0 then - writei16(coef, off + i * 2, -((h - v) // qv)) - else - writei16(coef, off + i * 2, (v + h) // qv) - end +-- (|v| + q * 4) // (q * 8) with v's sign, branch-free (a sign branch here gave LuaJIT side traces it could not compile) +local function quant(coef: buffer, off: number, qv: number, v: number, i: number) + writei16(coef, off + i * 2, (abs(v) + qv / 2) // qv * sign(v)) end --- quantised as jcdctmgr.c: (|v| + q * 4) // (q * 8) with the sign restored -function Dct.fdctQuantize(src: buffer, stride: number, x: number, y: number, w: number, h: number, div: buffer, coef: buffer, off: number) +-- quantised as jcdctmgr.c: (|v| + q * 4) // (q * 8) with the sign restored; div[i + 1] = q * 8 for natural index i +function Dct.fdctQuantize(src: buffer, stride: number, x: number, y: number, w: number, h: number, div: { number }, coef: buffer, off: number) local lastX, lastY = w - 1, h - 1 for r = 0, 7 do local row = math.min(y + r, lastY) * stride @@ -484,14 +479,14 @@ function Dct.fdctQuantize(src: buffer, stride: number, x: number, y: number, w: local o3 = (tmp6 + z2 + z3 + 16384) // 32768 local o1 = (tmp7 + z1 + z4 + 16384) // 32768 local cc = c - 1 - quant(coef, off, div, o0, cc) - quant(coef, off, div, o1, cc + 8) - quant(coef, off, div, o2, cc + 16) - quant(coef, off, div, o3, cc + 24) - quant(coef, off, div, o4, cc + 32) - quant(coef, off, div, o5, cc + 40) - quant(coef, off, div, o6, cc + 48) - quant(coef, off, div, o7, cc + 56) + quant(coef, off, div[c], o0, cc) + quant(coef, off, div[c + 8], o1, cc + 8) + quant(coef, off, div[c + 16], o2, cc + 16) + quant(coef, off, div[c + 24], o3, cc + 24) + quant(coef, off, div[c + 32], o4, cc + 32) + quant(coef, off, div[c + 40], o5, cc + 40) + quant(coef, off, div[c + 48], o6, cc + 48) + quant(coef, off, div[c + 56], o7, cc + 56) end end diff --git a/src/Rosetta/codecs/image/Jpeg/Encode.luau b/src/Rosetta/codecs/image/Jpeg/Encode.luau index c72711d..40d25a8 100644 --- a/src/Rosetta/codecs/image/Jpeg/Encode.luau +++ b/src/Rosetta/codecs/image/Jpeg/Encode.luau @@ -595,11 +595,11 @@ function Encode.run(px: buffer, w: number, h: number, bpp: number, o: Options): local qt = { Tables.quant(Tables.LUMA, o.quality), Tables.quant(Tables.CHROMA, o.quality) } local qdiv = {} for t = 1, 2 do - local b = buffer.create(128) + local d = table.create(64, 0) for i = 1, 64 do - writeu16(b, (i - 1) * 2, qt[t][i]) + d[i] = qt[t][i] * 8 end - qdiv[t] = b + qdiv[t] = d end local comps: { Comp } = {} diff --git a/tests/codecs/dct.luau b/tests/codecs/dct.luau index e5e4ac9..4cf4a85 100644 --- a/tests/codecs/dct.luau +++ b/tests/codecs/dct.luau @@ -71,8 +71,12 @@ do for i = 0, 63 do buffer.writeu16(q, i * 2, 1 + rand(40)) end + local div = table.create(64, 0) -- fdctQuantize's divisors: q * 8 + for i = 1, 64 do + div[i] = buffer.readu16(q, (i - 1) * 2) * 8 + end local coef = buffer.create(128) - Dct.fdctQuantize(src, 8, 0, 0, 8, 8, q, coef, 0) + Dct.fdctQuantize(src, 8, 0, 0, 8, 8, div, coef, 0) for v = 0, 7 do for u = 0, 7 do local s = 0 @@ -88,6 +92,7 @@ do end end t:check(worst <= 0.75, "fdct + quantise within rounding of the float reference: " .. worst) + local div1 = table.create(64, 8) local rt = 0 for _ = 1, 100 do local src = buffer.create(64) @@ -95,7 +100,7 @@ do buffer.writeu8(src, i, rand(256)) end local coef = buffer.create(128) - Dct.fdctQuantize(src, 8, 0, 0, 8, 8, ones, coef, 0) + Dct.fdctQuantize(src, 8, 0, 0, 8, 8, div1, coef, 0) local plane = buffer.create(128) Dct.idctBlock(coef, 0, ones, plane, 0, 8, 2, 128, 255) for i = 0, 63 do @@ -112,8 +117,8 @@ do end end local a, b = buffer.create(128), buffer.create(128) - Dct.fdctQuantize(small, 3, 0, 0, 3, 2, ones, a, 0) - Dct.fdctQuantize(ext, 8, 0, 0, 8, 8, ones, b, 0) + Dct.fdctQuantize(small, 3, 0, 0, 3, 2, div1, a, 0) + Dct.fdctQuantize(ext, 8, 0, 0, 8, 8, div1, b, 0) t:check(buffer.tostring(a) == buffer.tostring(b), "edge replication") end diff --git a/tools/bench.sh b/tools/bench.sh index 920cd8b..d3d4e67 100644 --- a/tools/bench.sh +++ b/tools/bench.sh @@ -2,7 +2,9 @@ # Timings (bash tools/bench.sh [core [filter]]): tools/bench.luau under luau --codegen -O2 and under LuaJIT (the module build, # build/_modules/luajit). "core" runs tools/bench_core.luau (inflate / deflate, checksums, rbxm / rbxmx, json / xml, # F.detect, gltf / obj, the other decompressors) under luau -O2, luau --codegen -O2 and LuaJIT; a filter keeps the lines -# whose label contains it. +# whose label contains it. "mixed" (LuaJIT only) runs tools/bench_image.luau and tools/bench_video.luau each on its own, +# then tools/bench_mixed.luau: core, audio, video and image in one process, marking the lines that run more than 1.3x +# slower there (trace pollution between codecs). cd "$(dirname "$0")/.." || exit 1 LUAU=${LUAU:-$(command -v luau || nix shell nixpkgs#luau -c sh -c 'command -v luau')} LUAJIT=${LUAJIT:-$(command -v luajit || nix shell nixpkgs#luajit -c sh -c 'command -v luajit')} @@ -15,5 +17,15 @@ if [ "$1" = core ]; then "$LUAJIT" -e "$LJPATH" build/_modules/luajit/tools/bench_core.lua "$2" exit 0 fi +if [ "$1" = mixed ]; then + tmp=$(mktemp -d) + for s in image video; do + "$LUAJIT" -e "$LJPATH" build/_modules/luajit/tools/bench_$s.lua > "$tmp/$s" || exit 1 + done + "$LUAJIT" -e "$LJPATH" build/_modules/luajit/tools/bench_mixed.lua "$tmp/image" "$tmp/video" + status=$? + rm -r "$tmp" + exit $status +fi "$LUAU" --codegen -O2 tools/bench.luau "$LUAJIT" -e "$LJPATH" build/_modules/luajit/tools/bench.lua diff --git a/tools/bench_mixed.luau b/tools/bench_mixed.luau new file mode 100644 index 0000000..aebcfb4 --- /dev/null +++ b/tools/bench_mixed.luau @@ -0,0 +1,85 @@ +-- Mixed-workload check (bash tools/bench.sh mixed), LuaJIT only: bench_core, bench_audio, bench_video and bench_image +-- in one process, as an app that decodes many formats runs them, the video and image lines against each bench run +-- alone (the files of its arguments, written by bench.sh). LuaJIT's traces, blacklists and penalties are per process: +-- a shared helper blacklisted by one codec, or a side trace that never compiles, slows every later caller, which the +-- per-codec benches never show. Lines more than 1.3x slower mixed than alone are marked. +local jit = (_G :: any).jit +if jit == nil then + print("bench_mixed: LuaJIT only (bash tools/bench.sh mixed)") + return +end +local G = _G :: any +local loadfile, io = G.loadfile, G.io +local imageAlone, videoAlone = ... + +-- "luajit

L_L0xjQR>0%Ht*bpFL-o@aQucJ_+zMfr} zQPB8q2)i1if{{tl1y0cUVrG_V3`~0%6g2V;#TZruG8|xFc;V=1P~qm9#4Dh|$G{@R zz$la>XduDBa79$X(A1MhAjyV7$ZR_wL;XGmu2+mqhd^^j%#sWY-YP7oSy^8*@yBqA zGP^J^@CR}{XJWd+!f>6J-$;dpDU(4zG2=T4_4Rb|4EFbPH!w3awKQ$7=VMA`)X&H*vk_xsV`93)Af)k+mmz_HA)Y}n zA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0EJB}J9RA6cCxnWi%frkXG^ z*ef!tFfhzuXOd0z?cVVuAO zy7;DVdaaL8su05$cIFNS21BNxa;s7cjUSw>+u!>L?PFy6FFk#|pO85l!#OU72khHl z`UwehurWS)$auwPJ9D_uBPLcwF3wc;?JpyR&NH#{AAiryu>DAkP%RVV^yyCVLZ)m? z9p-Eon5S383mGxRGE83=FSMLppx~%J1Ffj=z_1tHZWN_FXnI!a>kyq6C z(sY5O3H%I(4lJ?Ly;Fpo7;kOwOA!iSO* zrp41WtA$dTelu*JP%RY1$jVS7FI2nzS&h&IMi%D7f~?zj*9qluaO_m#`>w=von^XV zyO04>D8u&TcA-y-pC<+ZxomDlQd?2-M-$N&cR40a5R a46Eds7#TGAe=#hVXWYY}I=v%PUmgHU6B~~J diff --git a/build/Rosetta.rbxm.linemap.json b/build/Rosetta.rbxm.linemap.json index 629bc05..6fa66e8 100644 --- a/build/Rosetta.rbxm.linemap.json +++ b/build/Rosetta.rbxm.linemap.json @@ -1,6 +1,6 @@ { -"Core_1": [[8, "src/Rosetta/init.luau"], [892, "src/Rosetta/Registry.luau"], [3301, "src/Rosetta/Types.luau"], [4414, "src/Rosetta/codecs/audio/Adpcm/init.luau"], [5168, "src/Rosetta/codecs/image/Yuv.luau"], [5473, "src/Rosetta/codecs/model/Rbx/init.luau"], [5710, "src/Rosetta/codecs/video/Video/init.luau"], [6268, "src/Rosetta/containers/AudioWrap.luau"], [6778, "src/Rosetta/containers/Ogg/Mux.luau"], [6967, "src/Rosetta/core/Bytes.luau"], [7494, "src/Rosetta/core/Crc32.luau"], [7645, "src/Rosetta/core/Err.luau"], [7727, "src/Rosetta/core/Input.luau"], [7803, "src/Rosetta/host/init.luau"]], -"Core_2": [[8, "src/Rosetta/ops/ImageOps/init.luau"], [656, "src/Rosetta/ops/ImageOps/Kernels.luau"]], +"Core_1": [[8, "src/Rosetta/init.luau"], [925, "src/Rosetta/Registry.luau"], [3542, "src/Rosetta/Types.luau"], [4655, "src/Rosetta/codecs/audio/Adpcm/init.luau"], [5409, "src/Rosetta/codecs/image/Yuv.luau"], [5714, "src/Rosetta/codecs/model/Rbx/init.luau"], [5951, "src/Rosetta/codecs/video/Video/init.luau"], [6509, "src/Rosetta/containers/AudioWrap.luau"], [7019, "src/Rosetta/containers/Ogg/Mux.luau"], [7208, "src/Rosetta/core/Bytes.luau"], [7735, "src/Rosetta/core/Crc32.luau"], [7886, "src/Rosetta/core/Err.luau"], [7968, "src/Rosetta/core/Input.luau"]], +"Core_2": [[8, "src/Rosetta/host/init.luau"], [53, "src/Rosetta/ops/ImageOps/init.luau"], [701, "src/Rosetta/ops/ImageOps/Kernels.luau"]], "Mpeg2": [[8, "src/Rosetta/codecs/video/Dsp.luau"], [846, "src/Rosetta/codecs/video/Mpeg1/init.luau"], [859, "src/Rosetta/codecs/video/Mpeg2/init.luau"], [1227, "src/Rosetta/codecs/video/Mpeg2/Decoder.luau"], [2754, "src/Rosetta/codecs/video/Mpeg2/Tables.luau"], [2894, "src/Rosetta/codecs/video/Mpeg2/Vlc.luau"]], "H263": [[8, "src/Rosetta/codecs/video/H263/init.luau"], [165, "src/Rosetta/codecs/video/H263/Decoder.luau"], [1023, "src/Rosetta/codecs/video/H263/Tables.luau"]], "H264": [[8, "src/Rosetta/codecs/video/H264/init.luau"], [382, "src/Rosetta/codecs/video/H264/Bitstream.luau"], [657, "src/Rosetta/codecs/video/H264/Cabac.luau"], [1788, "src/Rosetta/codecs/video/H264/Cavlc.luau"], [2556, "src/Rosetta/codecs/video/H264/Deblock.luau"], [2818, "src/Rosetta/codecs/video/H264/Decoder.luau"], [3828, "src/Rosetta/codecs/video/H264/Inter.luau"], [4154, "src/Rosetta/codecs/video/H264/Intra.luau"], [4561, "src/Rosetta/codecs/video/H264/Mb.luau"], [5500, "src/Rosetta/codecs/video/H264/Params.luau"], [5948, "src/Rosetta/codecs/video/H264/Slice.luau"], [6200, "src/Rosetta/codecs/video/H264/Tables.luau"], [6242, "src/Rosetta/codecs/video/H264/Transform.luau"]], @@ -27,6 +27,7 @@ "Hively": [[8, "src/Rosetta/codecs/audio/Hively/init.luau"], [205, "src/Rosetta/codecs/audio/Hively/Load.luau"], [455, "src/Rosetta/codecs/audio/Hively/Player.luau"], [1414, "src/Rosetta/codecs/audio/Hively/Tables.luau"]], "SoundFont": [[8, "src/Rosetta/codecs/audio/SoundFont/init.luau"], [63, "src/Rosetta/codecs/audio/SoundFont/Fallback.luau"], [207, "src/Rosetta/codecs/audio/SoundFont/Parse.luau"], [721, "src/Rosetta/codecs/audio/SoundFont/Synth.luau"]], "Draco": [[8, "src/Rosetta/codecs/model/Draco/init.luau"], [340, "src/Rosetta/codecs/model/Draco/Attributes.luau"], [809, "src/Rosetta/codecs/model/Draco/Connectivity.luau"], [1998, "src/Rosetta/codecs/model/Draco/Int64.luau"], [2147, "src/Rosetta/codecs/model/Draco/KdTree.luau"], [2506, "src/Rosetta/codecs/model/Draco/Predict.luau"], [3468, "src/Rosetta/codecs/model/Draco/Reader.luau"]], +"Root": [[8, "src/Rosetta/Sniffs.luau"]], "archive_1": [[8, "src/Rosetta/archive/7z/init.luau"], [393, "src/Rosetta/archive/7z/Header.luau"], [920, "src/Rosetta/archive/adf/init.luau"], [1202, "src/Rosetta/archive/applesingle/init.luau"], [1388, "src/Rosetta/archive/ar/init.luau"], [1791, "src/Rosetta/archive/arj/init.luau"], [2001, "src/Rosetta/archive/binhex/init.luau"], [2250, "src/Rosetta/archive/br/init.luau"], [2325, "src/Rosetta/archive/bz2/init.luau"], [2389, "src/Rosetta/archive/cab/init.luau"], [2802, "src/Rosetta/archive/cab/Sum.luau"], [2843, "src/Rosetta/archive/cpio/init.luau"], [3011, "src/Rosetta/archive/d64/init.luau"], [3425, "src/Rosetta/archive/fat/init.luau"], [3547, "src/Rosetta/archive/grp/init.luau"], [3661, "src/Rosetta/archive/gzip/init.luau"], [3846, "src/Rosetta/archive/iso/init.luau"], [3918, "src/Rosetta/archive/lha/init.luau"], [4343, "src/Rosetta/archive/lz4/init.luau"], [4687, "src/Rosetta/archive/macbinary/init.luau"], [4885, "src/Rosetta/archive/mpq/init.luau"], [5291, "src/Rosetta/archive/mpq/Crypt.luau"], [5356, "src/Rosetta/archive/pak/init.luau"], [5490, "src/Rosetta/archive/rpm/init.luau"], [5814, "src/Rosetta/archive/tar/init.luau"], [5932, "src/Rosetta/archive/unitypackage/init.luau"], [6168, "src/Rosetta/archive/uu/init.luau"], [6438, "src/Rosetta/archive/vpk/init.luau"], [6749, "src/Rosetta/archive/vswap/init.luau"], [7019, "src/Rosetta/archive/wad/init.luau"], [7473, "src/Rosetta/archive/wad/Picture.luau"], [7575, "src/Rosetta/archive/wad2/init.luau"], [7857, "src/Rosetta/archive/xz/init.luau"]], "archive_2": [[8, "src/Rosetta/archive/yenc/init.luau"], [280, "src/Rosetta/archive/z/init.luau"], [376, "src/Rosetta/archive/zip/init.luau"], [595, "src/Rosetta/archive/zoo/init.luau"], [791, "src/Rosetta/archive/zst/init.luau"]], "audio": [[8, "src/Rosetta/audio/aac/init.luau"], [221, "src/Rosetta/audio/ac3/init.luau"], [368, "src/Rosetta/audio/adpcm/init.luau"], [514, "src/Rosetta/audio/adx/init.luau"], [746, "src/Rosetta/audio/aiff/init.luau"], [1138, "src/Rosetta/audio/ape/init.luau"], [1267, "src/Rosetta/audio/au/init.luau"], [1429, "src/Rosetta/audio/brstm/init.luau"], [1721, "src/Rosetta/audio/caf/init.luau"], [2388, "src/Rosetta/audio/flac/init.luau"], [2537, "src/Rosetta/audio/flac/Meta.luau"], [2759, "src/Rosetta/audio/flac/Stream.luau"], [3129, "src/Rosetta/audio/m4a/init.luau"], [3472, "src/Rosetta/audio/mp3/init.luau"], [3733, "src/Rosetta/audio/mp3/Index.luau"], [3924, "src/Rosetta/audio/mp3/Stream.luau"], [4151, "src/Rosetta/audio/mp3/Tags.luau"], [4463, "src/Rosetta/audio/mpc/init.luau"], [4558, "src/Rosetta/audio/opus/init.luau"], [4937, "src/Rosetta/audio/opus/Encode.luau"], [5049, "src/Rosetta/audio/qoa/init.luau"], [5230, "src/Rosetta/audio/tta/init.luau"], [5349, "src/Rosetta/audio/vag/init.luau"], [5573, "src/Rosetta/audio/voc/init.luau"], [5849, "src/Rosetta/audio/vorbis/init.luau"], [6304, "src/Rosetta/audio/vorbis/Encode.luau"], [7117, "src/Rosetta/audio/wav/init.luau"], [7738, "src/Rosetta/audio/wav/Codecs.luau"], [7917, "src/Rosetta/audio/wavpack/init.luau"]], diff --git a/build/Rosetta.rbxmx b/build/Rosetta.rbxmx index ec96b82..3e4cb66 100644 --- a/build/Rosetta.rbxmx +++ b/build/Rosetta.rbxmx @@ -22,7 +22,7 @@ local __CHUNK = { ["core/Crc32"] = "Core_1", ["core/Err"] = "Core_1", ["core/Input"] = "Core_1", - ["host"] = "Core_1", + ["host"] = "Core_2", ["ops/ImageOps"] = "Core_2", ["ops/ImageOps/Kernels"] = "Core_2", ["codecs/video/Dsp"] = "Mpeg2", @@ -160,6 +160,7 @@ local __CHUNK = { ["codecs/model/Draco/KdTree"] = "Draco", ["codecs/model/Draco/Predict"] = "Draco", ["codecs/model/Draco/Reader"] = "Draco", + ["Sniffs"] = "Root", ["archive/7z"] = "archive_1", ["archive/7z/Header"] = "archive_1", ["archive/adf"] = "archive_1", @@ -680,7 +681,7 @@ return Rosetta --!optimize 2 --!nocheck -- rosetta chunk Core_1 (build/Rosetta.rbxm): GENERATED by tools/bundle.py from src/Rosetta - do not edit. --- 14 modules (5 native: @native); the Rosetta root requires it when one of them is first included. +-- 13 modules (5 native: @native); the Rosetta root requires it when one of them is first included. -- Error lines map back to the sources through Rosetta.rbxm.linemap.json (tools/bundle.py --where). return function(__FILES, __include) __FILES[""] = function() @@ -764,6 +765,56 @@ end local LATE: { [string]: number } = { br = 0.3 } -- archive/br: a trial decode of up to 256 KB +-- detection order: by the cost of a sniff (Registry.sniff: Sniffs.luau, Sniffs.luau reaching a codec, the format +-- module), then registry order; the costly LATE sniffs last +local order: { number }? = nil +local byExt: { [string]: { number } } = {} +local Sniffs: { [string]: (any) -> number }? = nil + +local function sniffOrder(): { number } + local o = order + if o then + return o + end + local list: { number } = {} + for idx, e in Registry do + table.insert(list, idx) + for _, x in e.extensions do + byExt[x] = byExt[x] or {} + table.insert(byExt[x], idx) + end + end + local function rank(idx: number): number + local e = Registry[idx] + return if LATE[e.name] then 3 else e.sniff + end + table.sort(list, function(a: number, b: number): boolean + local ra, rb = rank(a), rank(b) + if ra ~= rb then + return ra < rb + end + return a < b + end) + order = list + return list +end + +local function sniffer(e: Registry.Entry): ((any) -> number)? + if e.sniff < 2 then + local s = Sniffs + if not s then + s = __include("Sniffs") :: any + Sniffs = s + end + local f = (s :: { [string]: (any) -> number })[e.path] + if f then + return f + end + end + local m = module(e) + return if m and type(m.sniff) == "function" then m.sniff else nil +end + local function detect(buf: buffer, name: string?, category: string?, format: string?): (Registry.Entry?, Err.Err?) if format then local e = find(format, category) @@ -773,52 +824,35 @@ local function detect(buf: buffer, name: string?, category: string?, format: str return e, nil end local ext = Input.extension(name) + local list = sniffOrder() + local hits = if ext then byExt[ext] else nil local best: Registry.Entry? = nil local bestScore, bestIdx = 0, 0 - -- sniffs score 0..1 (core/Sniff); the extension's format scoring 1 cannot be beaten. Formats with a costly sniff - -- (LATE: the most they score) run last, and only when they could still win; ties go to registry order. - local late: { number }? = nil - for idx, e in Registry do - if inCategory(e, category) and (e.caps.decode or e.caps.open) then - local cap = LATE[e.name] - if cap then - late = late or {} - table.insert(late :: { number }, idx) - continue - end - local m = module(e) - if m and m.sniff then - local ok, score = pcall(m.sniff, Bytes.reader(buf)) - if ok and type(score) == "number" and score > 0 then - local extHit = ext and table.find(e.extensions, ext) - if extHit then - score += 0.01 -- ties go to the extension - end - if score > bestScore then - best, bestScore, bestIdx = e, score, idx - if extHit and score >= 1.01 then - return e, nil - end - end + -- sniffs score 0..1 (core/Sniff), +0.01 for the extension's formats; the best wins, ties go to registry order. The + -- extension's formats run first, and a sniff runs only while its cap (1, or LATE) could still win. + for pass = 1, 2 do + local ids = if pass == 1 then hits else list + if ids then + for _, idx in ids do + if pass == 2 and bestScore > 1 then + break end - end - end - end - if late then - for _, idx in late do - local e = Registry[idx] - local extHit = ext and table.find(e.extensions, ext) - local cap = LATE[e.name] + (if extHit then 0.01 else 0) - if cap > bestScore or (cap == bestScore and idx < bestIdx) then - local m = module(e) - if m and m.sniff then - local ok, score = pcall(m.sniff, Bytes.reader(buf)) - if ok and type(score) == "number" and score > 0 then - if extHit then - score += 0.01 - end - if score > bestScore or (score == bestScore and idx < bestIdx) then - best, bestScore, bestIdx = e, score, idx + local e = Registry[idx] + local extHit = pass == 1 or (hits ~= nil and table.find(hits, idx) ~= nil) + if (pass == 1 or not extHit) and inCategory(e, category) and (e.caps.decode or e.caps.open) then + local cap = (LATE[e.name] or 1) + (if extHit then 0.01 else 0) + if cap > bestScore or (cap == bestScore and idx < bestIdx) then + local sniff = sniffer(e) + if sniff then + local ok, score = pcall(sniff, Bytes.reader(buf)) + if ok and type(score) == "number" and score > 0 then + if extHit then + score += 0.01 + end + if score > bestScore or (score == bestScore and idx < bestIdx) then + best, bestScore, bestIdx = e, score, idx + end + end end end end @@ -1382,7 +1416,7 @@ function F.detect(src: any, opts: Options?): (string?, Err.Err?) return nil, err end -- a format may name the file's flavour more precisely (video/mkv: "webm" for DocType webm) - local m = module(entry) + local m = if entry.variant then module(entry) else nil if m and type(m.variant) == "function" then local ok, v = pcall(m.variant, Bytes.reader(buf)) if ok and type(v) == "string" then @@ -1572,6 +1606,8 @@ __FILES["Registry"] = function() -- Registry: GENERATED by tools/gen_registry.py from the format folders - do not edit. -- One entry per format: the contract metadata (copied from its init.luau) and load(), which requires the format -- module on first use (a static require, as Roblox needs). Order: category, then name. +-- sniff: where detection finds the format's sniff (tools/sniff_extract.py): 0 Sniffs.luau, 1 Sniffs.luau reaching a +-- codec / container on first call, 2 the format module. variant: the module has variant(r). type Entry = { name: string, category: string, @@ -1580,6 +1616,8 @@ type Entry = { mime: { string }, deps: { string }, caps: { [string]: any }, + sniff: number, + variant: boolean?, load: () -> any, } @@ -1592,6 +1630,7 @@ local list: { Entry } = { mime = { "application/x-navi-animation" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Riff" }, caps = { decode = true, encode = true, alpha = true, animation = true, frames = true }, + sniff = 0, load = function() return __include("image/ani") end, @@ -1604,6 +1643,7 @@ local list: { Entry } = { mime = { "image/x-build-art" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Pixels", "codecs/image/Quantize" }, caps = { decode = true, encode = true, alpha = true, palette = true, frames = true, depths = { 8 } }, + sniff = 0, load = function() return __include("image/art") end, @@ -1616,6 +1656,7 @@ local list: { Entry } = { mime = { "image/x-blp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Jpeg", "codecs/image/Bcn" }, caps = { decode = true, encode = true, alpha = true, variants = { "blp1", "blp2" }, compressions = { "jpeg", "palette", "dxt1", "dxt3", "dxt5", "bgra" } }, + sniff = 0, load = function() return __include("image/blp") end, @@ -1628,6 +1669,7 @@ local list: { Entry } = { mime = { "image/bmp", "image/x-bmp", "image/x-ms-bmp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, depths = { 1, 2, 4, 8, 16, 24, 32 }, rle = true }, + sniff = 0, load = function() return __include("image/bmp") end, @@ -1640,6 +1682,7 @@ local list: { Entry } = { mime = { "image/vnd-ms.dds", "image/x-dds" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/image/Bcn", "codecs/image/Texel", "codecs/image/Texture" }, caps = { decode = true, encode = true, alpha = true, float = true, mipmaps = true, cubemap = true, compressed = { "bc1", "bc2", "bc3", "bc4", "bc5", "bc6h", "bc7" } }, + sniff = 0, load = function() return __include("image/dds") end, @@ -1652,6 +1695,7 @@ local list: { Entry } = { mime = { "image/x-exr", "image/aces" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/image/Half", "codecs/compress/Deflate" }, caps = { decode = true, encode = true, alpha = true, float = true, hdr = true, depths = { 16, 32 }, multipart = true, tiled = true }, + sniff = 0, load = function() return __include("image/exr") end, @@ -1664,6 +1708,7 @@ local list: { Entry } = { mime = { "image/gif" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Lzw", "codecs/image/Quantize", "Types" }, caps = { decode = true, encode = true, animation = true, alpha = true, palette = true, depths = { 1, 2, 4, 8 } }, + sniff = 0, load = function() return __include("image/gif") end, @@ -1676,6 +1721,7 @@ local list: { Entry } = { mime = { "image/vnd.radiance", "image/x-hdr" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = false, float = true, depths = { 32 } }, + sniff = 0, load = function() return __include("image/hdr") end, @@ -1688,6 +1734,7 @@ local list: { Entry } = { mime = { "image/icns", "image/x-icns" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "containers/Chunks" }, caps = { decode = true, encode = true, alpha = true, frames = true, depths = { 1, 24, 32 } }, + sniff = 0, load = function() return __include("image/icns") end, @@ -1700,6 +1747,7 @@ local list: { Entry } = { mime = { "image/vnd.microsoft.icon", "image/x-icon" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, frames = true, depths = { 1, 4, 8, 16, 24, 32 } }, + sniff = 0, load = function() return __include("image/ico") end, @@ -1712,6 +1760,7 @@ local list: { Entry } = { mime = { "image/x-ilbm", "image/x-iff" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks", "codecs/compress/PackBits", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 1, 2, 3, 4, 5, 6, 7, 8, 24, 32 } }, + sniff = 0, load = function() return __include("image/ilbm") end, @@ -1724,6 +1773,7 @@ local list: { Entry } = { mime = { "image/jpeg" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Jpeg" }, caps = { decode = true, encode = true, lossy = true, alpha = false, depths = { 8, 12 }, progressive = true, arithmetic = true }, + sniff = 0, load = function() return __include("image/jpeg") end, @@ -1736,6 +1786,7 @@ local list: { Entry } = { mime = { "image/ktx2", "image/ktx" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/compress/Deflate", "codecs/compress/Zstd", "codecs/image/Texel", "codecs/image/Texture" }, caps = { decode = true, encode = true, alpha = true, float = true, mipmaps = true, cubemap = true, compressed = { "bc1", "bc2", "bc3", "bc4", "bc5", "bc6h", "bc7", "etc1", "etc2", "eac" } }, + sniff = 0, load = function() return __include("image/ktx") end, @@ -1748,6 +1799,7 @@ local list: { Entry } = { mime = { "image/x-quake-lmp" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Pixels", "codecs/image/Miptex" }, caps = { decode = true, encode = true, alpha = true, depths = { 8 }, variants = { "qpic", "palette", "colormap" } }, + sniff = 0, load = function() return __include("image/lmp") end, @@ -1760,6 +1812,7 @@ local list: { Entry } = { mime = { "image/vnd.zbrush.pcx", "image/x-pcx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 1, 2, 4, 8, 24, 32 } }, + sniff = 0, load = function() return __include("image/pcx") end, @@ -1772,6 +1825,7 @@ local list: { Entry } = { mime = { "image/png", "image/apng" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "codecs/compress/Deflate", "Types", "containers/Chunks" }, caps = { decode = true, encode = true, animation = true, alpha = true, depths = { 1, 2, 4, 8, 16 } }, + sniff = 0, load = function() return __include("image/png") end, @@ -1784,6 +1838,7 @@ local list: { Entry } = { mime = { "image/x-portable-anymap", "image/x-portable-bitmap", "image/x-portable-graymap", "image/x-portable-pixmap", "image/x-portable-arbitrarymap", "image/x-portable-floatmap" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = true, depths = { 1, 8, 16, 32 }, float = true }, + sniff = 0, load = function() return __include("image/pnm") end, @@ -1796,6 +1851,7 @@ local list: { Entry } = { mime = { "image/qoi", "image/x-qoi" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = true, depths = { 8 } }, + sniff = 0, load = function() return __include("image/qoi") end, @@ -1808,6 +1864,7 @@ local list: { Entry } = { mime = { "image/sgi", "image/x-rgb" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types" }, caps = { decode = true, encode = true, alpha = true, depths = { 8, 16 } }, + sniff = 0, load = function() return __include("image/sgi") end, @@ -1820,6 +1877,7 @@ local list: { Entry } = { mime = { "image/x-quake-sprite" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Pixels", "codecs/image/Miptex" }, caps = { decode = true, encode = true, alpha = true, animation = true, variants = { "quake", "halflife", "spr32" } }, + sniff = 0, load = function() return __include("image/spr") end, @@ -1832,6 +1890,7 @@ local list: { Entry } = { mime = { "image/x-sun-raster", "image/x-cmu-raster" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 1, 8, 24, 32 } }, + sniff = 0, load = function() return __include("image/sunras") end, @@ -1844,6 +1903,7 @@ local list: { Entry } = { mime = { "image/x-tga", "image/x-targa" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 8, 15, 16, 24, 32 } }, + sniff = 0, load = function() return __include("image/tga") end, @@ -1856,6 +1916,7 @@ local list: { Entry } = { mime = { "image/tiff" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate", "codecs/compress/Lzw", "codecs/compress/PackBits" }, caps = { decode = true, encode = true, alpha = true, pages = true, depths = { 1, 2, 4, 8, 16, 32 }, float = true }, + sniff = 0, load = function() return __include("image/tiff") end, @@ -1868,6 +1929,7 @@ local list: { Entry } = { mime = { "image/x-tim" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 4, 8, 16, 24 } }, + sniff = 0, load = function() return __include("image/tim") end, @@ -1880,6 +1942,7 @@ local list: { Entry } = { mime = { "image/x-vtf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Bcn", "codecs/image/Texel" }, caps = { decode = true, encode = false, alpha = true, animation = true, versions = { "7.0", "7.1", "7.2", "7.3", "7.4", "7.5" } }, + sniff = 0, load = function() return __include("image/vtf") end, @@ -1892,6 +1955,7 @@ local list: { Entry } = { mime = { "image/webp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Vp8", "codecs/image/Vp8L", "containers/Riff" }, caps = { decode = true, encode = true, animation = true, alpha = true, lossy = true, lossless = true, depths = { 8 } }, + sniff = 0, load = function() return __include("image/webp") end, @@ -1904,6 +1968,7 @@ local list: { Entry } = { mime = { "image/x-xbitmap", "image/x-xbm" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types" }, caps = { decode = true, encode = true, depths = { 1 } }, + sniff = 0, load = function() return __include("image/xbm") end, @@ -1916,6 +1981,7 @@ local list: { Entry } = { mime = { "image/x-xpixmap", "image/x-xpm" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 8 } }, + sniff = 0, load = function() return __include("image/xpm") end, @@ -1928,6 +1994,7 @@ local list: { Entry } = { mime = { "audio/aac", "audio/aacp", "audio/x-aac" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Aac", "codecs/audio/Pcm", "codecs/audio/Stream" }, caps = { decode = true, encode = false, codecs = { "aac" }, streaming = true }, + sniff = 1, load = function() return __include("audio/aac") end, @@ -1940,6 +2007,7 @@ local list: { Entry } = { mime = { "audio/ac3", "audio/x-ac3" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/Ac3" }, caps = { decode = true, encode = false, codecs = { "ac3" }, channels = 6, streaming = true, lossy = true }, + sniff = 1, load = function() return __include("audio/ac3") end, @@ -1952,6 +2020,7 @@ local list: { Entry } = { mime = { "audio/x-adpcm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm", "codecs/audio/Adpcm/Decoder" }, caps = { decode = true, encode = true, streaming = true, lossy = true, headerless = true, codecs = { "ima", "ima_wav", "ms", "ima_qt", "psx" } }, + sniff = 0, load = function() return __include("audio/adpcm") end, @@ -1964,6 +2033,7 @@ local list: { Entry } = { mime = { "audio/x-adx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm", "codecs/audio/Adpcm/Decoder" }, caps = { decode = true, encode = true, streaming = true, lossy = true, loops = true, channels = 8 }, + sniff = 0, load = function() return __include("audio/adx") end, @@ -1976,6 +2046,7 @@ local list: { Entry } = { mime = { "audio/aiff", "audio/x-aiff" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm/Decoder", "containers/Chunks" }, caps = { decode = true, encode = true, streaming = true, depths = { 8, 16, 24, 32 }, float = true, lossy = false }, + sniff = 0, load = function() return __include("audio/aiff") end, @@ -1988,6 +2059,7 @@ local list: { Entry } = { mime = { "audio/ape", "audio/x-ape", "audio/x-monkeys-audio" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/ApeTag", "codecs/audio/Ape" }, caps = { decode = true, encode = false, streaming = true, seek = true, lossless = true, float = true, depths = { 8, 16, 24, 32 } }, + sniff = 0, load = function() return __include("audio/ape") end, @@ -2000,6 +2072,7 @@ local list: { Entry } = { mime = { "audio/basic", "audio/x-au" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm" }, caps = { decode = true, encode = true, streaming = true, depths = { 8, 16, 24, 32 }, float = true, lossy = false }, + sniff = 0, load = function() return __include("audio/au") end, @@ -2012,6 +2085,8 @@ local list: { Entry } = { mime = { "audio/x-brstm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm/Decoder" }, caps = { decode = true, encode = false, streaming = true, lossy = true, loops = true, containers = { "RSTM", "CSTM", "FSTM" } }, + sniff = 0, + variant = true, load = function() return __include("audio/brstm") end, @@ -2024,6 +2099,7 @@ local list: { Entry } = { mime = { "audio/x-caf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Aac", "codecs/audio/Adpcm/Decoder", "codecs/audio/Alac", "codecs/audio/Pcm", "codecs/audio/Stream", "containers/Chunks" }, caps = { decode = true, encode = true, codecs = { "pcm", "alac", "aac", "ulaw", "alaw" }, encodeCodecs = { "pcm", "alac" }, tags = true, streaming = true }, + sniff = 0, load = function() return __include("audio/caf") end, @@ -2036,6 +2112,7 @@ local list: { Entry } = { mime = { "audio/flac", "audio/x-flac" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ogg", "codecs/audio/Pcm", "codecs/audio/VorbisComment", "codecs/audio/Flac/Frame", "codecs/audio/Flac/Encode" }, caps = { decode = true, encode = true, streaming = true, depths = { 4, 8, 12, 16, 20, 24, 32 }, ogg = true, seek = true }, + sniff = 0, load = function() return __include("audio/flac") end, @@ -2048,6 +2125,7 @@ local list: { Entry } = { mime = { "audio/mp4", "audio/x-m4a", "audio/m4a" }, deps = { "core/Err", "core/Bytes", "Types", "containers/IsoBmff", "codecs/audio/Aac", "codecs/audio/Alac", "codecs/audio/Pcm", "codecs/audio/Stream" }, caps = { decode = true, encode = true, codecs = { "aac", "alac" }, encodeCodecs = { "alac" }, tags = true, streaming = true }, + sniff = 1, load = function() return __include("audio/m4a") end, @@ -2060,6 +2138,7 @@ local list: { Entry } = { mime = { "audio/mpeg", "audio/mp3", "audio/mpa" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Resample", "codecs/audio/Mpa/Header", "codecs/audio/Mpa/Core", "codecs/audio/Mpa/Encode3", "codecs/audio/Mpa/Encode2" }, caps = { decode = true, encode = true, streaming = true, seek = true, layers = { 1, 2, 3 }, encodeLayers = { 2, 3 }, channels = 2 }, + sniff = 1, load = function() return __include("audio/mp3") end, @@ -2072,6 +2151,7 @@ local list: { Entry } = { mime = { "audio/x-musepack", "audio/musepack" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/ApeTag", "codecs/audio/Musepack" }, caps = { decode = true, encode = false, codecs = { "musepack" }, versions = { 7, 8 }, streaming = true, lossy = true }, + sniff = 1, load = function() return __include("audio/mpc") end, @@ -2084,6 +2164,7 @@ local list: { Entry } = { mime = { "audio/opus", "audio/ogg" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ogg", "codecs/entropy/RangeCoder/Decoder", "codecs/audio/Pcm", "codecs/audio/Resample", "codecs/audio/VorbisComment", "codecs/audio/Opus/CeltEncoder", "codecs/audio/Opus/Decoder", "codecs/audio/Opus/Packet", "codecs/audio/Opus/Celt", "codecs/audio/Opus/Silk" }, caps = { decode = true, encode = true, streaming = true, seek = true, lossy = true, channels = 255, rates = { 48000 }, encodeModes = { "celt" }, encodeChannels = 2 }, + sniff = 0, load = function() return __include("audio/opus") end, @@ -2096,6 +2177,7 @@ local list: { Entry } = { mime = { "audio/qoa" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/Qoa" }, caps = { decode = true, encode = true, streaming = true, lossy = true, seek = true, channels = 8 }, + sniff = 0, load = function() return __include("audio/qoa") end, @@ -2108,6 +2190,7 @@ local list: { Entry } = { mime = { "audio/x-tta", "audio/tta" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/ApeTag", "codecs/audio/Tta" }, caps = { decode = true, encode = false, streaming = true, seek = true, lossless = true, depths = { 8, 16, 24 } }, + sniff = 0, load = function() return __include("audio/tta") end, @@ -2120,6 +2203,7 @@ local list: { Entry } = { mime = { "audio/x-vag" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm", "codecs/audio/Adpcm/Decoder" }, caps = { decode = true, encode = true, streaming = true, lossy = true, loops = true, channels = 2 }, + sniff = 0, load = function() return __include("audio/vag") end, @@ -2132,6 +2216,7 @@ local list: { Entry } = { mime = { "audio/x-voc" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm" }, caps = { decode = true, encode = true, streaming = true, depths = { 8, 16 }, lossy = false }, + sniff = 0, load = function() return __include("audio/voc") end, @@ -2144,6 +2229,7 @@ local list: { Entry } = { mime = { "audio/ogg", "audio/vorbis" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ogg", "codecs/audio/Mdct", "codecs/audio/Pcm", "codecs/audio/VorbisComment", "codecs/audio/Vorbis/Tables", "codecs/audio/Vorbis/Setup", "codecs/audio/Vorbis/Packet" }, caps = { decode = true, encode = true, streaming = true, seek = true, lossy = true, channels = 255 }, + sniff = 0, load = function() return __include("audio/vorbis") end, @@ -2156,6 +2242,7 @@ local list: { Entry } = { mime = { "audio/wav", "audio/x-wav", "audio/wave", "audio/vnd.wave" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Riff", "codecs/audio/Pcm", "codecs/audio/Adpcm" }, caps = { decode = true, encode = true, streaming = true, depths = { 8, 16, 24, 32 }, float = true, rf64 = true }, + sniff = 1, load = function() return __include("audio/wav") end, @@ -2168,6 +2255,7 @@ local list: { Entry } = { mime = { "audio/x-wavpack", "audio/wavpack" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/ApeTag", "codecs/audio/WavPack" }, caps = { decode = true, encode = false, streaming = true, seek = true, lossless = true, hybrid = true, float = true, depths = { 8, 12, 16, 20, 24, 32 } }, + sniff = 0, load = function() return __include("audio/wavpack") end, @@ -2180,6 +2268,7 @@ local list: { Entry } = { mime = { "video/x-msvideo", "video/avi" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Avi", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, video = { "mjpeg", "mpeg1", "mpeg2", "rawvideo" }, audio = true, odml = true }, + sniff = 0, load = function() return __include("video/avi") end, @@ -2192,6 +2281,7 @@ local list: { Entry } = { mime = { "video/x-fli", "video/fli", "video/x-flc" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video" }, caps = { decode = true, encode = false, streaming = true, video = { "flic" }, depths = { 8, 15, 16, 24 } }, + sniff = 0, load = function() return __include("video/fli") end, @@ -2204,6 +2294,7 @@ local list: { Entry } = { mime = { "video/x-flv", "video/flv" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source", "codecs/video/H263", "codecs/video/H264", "codecs/audio/Aac" }, caps = { decode = true, encode = true, streaming = true, remux = true, video = { "flv1", "h264" }, audio = true, metadata = true }, + sniff = 0, load = function() return __include("video/flv") end, @@ -2216,6 +2307,7 @@ local list: { Entry } = { mime = { "video/h264" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source", "codecs/video/H264" }, caps = { decode = true, encode = true, streaming = true, video = { "h264" }, depths = { 8 } }, + sniff = 0, load = function() return __include("video/h264") end, @@ -2228,6 +2320,8 @@ local list: { Entry } = { mime = { "video/x-matroska", "video/webm", "audio/x-matroska", "audio/webm" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ebml", "containers/Demux", "containers/Avi", "containers/IsoBmff/QtPalette", "codecs/compress/Deflate", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, remux = true, video = { "vp8", "mjpeg", "mpeg1", "mpeg2", "theora", "rawvideo" }, audio = true, subtitles = true }, + sniff = 0, + variant = true, load = function() return __include("video/mkv") end, @@ -2240,6 +2334,7 @@ local list: { Entry } = { mime = { "video/mp4", "video/quicktime", "video/3gpp" }, deps = { "core/Err", "core/Bytes", "Types", "containers/IsoBmff", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, remux = true, video = { "mjpeg", "mpeg1", "mpeg2", "h264" }, audio = true, fragments = true }, + sniff = 1, load = function() return __include("video/mp4") end, @@ -2252,6 +2347,7 @@ local list: { Entry } = { mime = { "video/mpeg" }, deps = { "core/Err", "core/Bytes", "Types", "containers/MpegPs", "containers/MpegEs", "containers/Demux", "codecs/video/Video" }, caps = { decode = true, encode = false, streaming = true, video = { "mpeg1", "mpeg2" }, audio = true }, + sniff = 0, load = function() return __include("video/mpegps") end, @@ -2264,6 +2360,7 @@ local list: { Entry } = { mime = { "video/mp2t" }, deps = { "core/Err", "core/Bytes", "Types", "containers/MpegTs", "containers/MpegEs", "containers/Demux", "codecs/video/Video" }, caps = { decode = true, encode = false, streaming = true, video = { "mpeg1", "mpeg2", "h264" }, audio = true }, + sniff = 0, load = function() return __include("video/mpegts") end, @@ -2276,6 +2373,7 @@ local list: { Entry } = { mime = { "video/ogg" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ogg", "containers/Demux", "containers/AudioWrap", "codecs/video/Theora", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, remux = true, video = { "theora" }, audio = true }, + sniff = 0, load = function() return __include("video/ogv") end, @@ -2288,6 +2386,7 @@ local list: { Entry } = { mime = { "video/vnd.radgamettools.smacker" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video", "codecs/audio/Stream", "codecs/video/Legacy/Smacker" }, caps = { decode = true, encode = false, streaming = true, video = { "smackvid" }, audio = { "smackaudio", "pcm_u8", "pcm_s16le" } }, + sniff = 0, load = function() return __include("video/smk") end, @@ -2300,6 +2399,7 @@ local list: { Entry } = { mime = { "video/x-yuv4mpeg" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, video = { "rawvideo" }, depths = { 8, 10, 12, 16 } }, + sniff = 0, load = function() return __include("video/y4m") end, @@ -2312,6 +2412,7 @@ local list: { Entry } = { mime = { "application/x-3ds", "image/x-3ds" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Mat4", "codecs/model/MeshFlatten", "codecs/model/Sampler" }, caps = { decode = true, encode = true, materials = true, textures = true, animation = true, cameras = true, lights = true, instancing = true }, + sniff = 0, load = function() return __include("model/3ds") end, @@ -2324,6 +2425,7 @@ local list: { Entry } = { mime = { "model/3mf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Xml", "containers/Zip" }, caps = { decode = true, encode = true, materials = true, vertexColors = true, textures = true, units = true }, + sniff = 0, load = function() return __include("model/3mf") end, @@ -2336,6 +2438,7 @@ local list: { Entry } = { mime = { "model/x-ase", "text/plain" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Text", "codecs/model/Mat4" }, caps = { decode = true, encode = true, text = true, materials = true, cameras = true, lights = true, vertexColors = true }, + sniff = 1, load = function() return __include("model/ase") end, @@ -2348,6 +2451,7 @@ local list: { Entry } = { mime = { "model/x-b3d" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks", "codecs/model/Mat4" }, caps = { decode = true, encode = false, materials = true, textures = true, skins = true, animation = true, colors = true }, + sniff = 0, load = function() return __include("model/b3d") end, @@ -2360,6 +2464,7 @@ local list: { Entry } = { mime = { "application/x-blender" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Blend", "codecs/compress/Deflate", "codecs/compress/Zstd", "codecs/model/Mat4", "codecs/model/Rig", "codecs/model/Polygon" }, caps = { decode = true, encode = false, materials = true, textures = true, animation = true, skins = true, morphTargets = true, cameras = true, lights = true, polygons = true, compressed = true }, + sniff = 1, load = function() return __include("model/blend") end, @@ -2372,6 +2477,7 @@ local list: { Entry } = { mime = { "model/x-bsp" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Pixels", "codecs/image/Miptex", "codecs/model/Patch" }, caps = { decode = true, encode = false, variants = { "quake", "bsp2", "2psb", "halflife", "quake2", "quake3" }, lightmaps = true, collision = true, visibility = true }, + sniff = 0, load = function() return __include("model/bsp") end, @@ -2384,6 +2490,7 @@ local list: { Entry } = { mime = { "application/x-build-map" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Polygon" }, caps = { decode = true, encode = true, sprites = true, slopes = true }, + sniff = 0, load = function() return __include("model/buildmap") end, @@ -2396,6 +2503,7 @@ local list: { Entry } = { mime = { "text/x-doom3-map" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/Brush", "codecs/model/Patch", "codecs/model/Mat4", "codecs/text/Lexer" }, caps = { decode = true, encode = false, patches = true, variants = { "doom3", "quake4" } }, + sniff = 0, load = function() return __include("model/d3map") end, @@ -2408,6 +2516,7 @@ local list: { Entry } = { mime = { "model/vnd.collada+xml", "model/vnd.collada+zip" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Xml", "core/Base64", "containers/Zip", "codecs/model/Mat4" }, caps = { decode = true, encode = true, materials = true, polygons = true, skins = true, morphTargets = true, animation = true, cameras = true, lights = true, zae = true }, + sniff = 0, load = function() return __include("model/dae") end, @@ -2420,6 +2529,7 @@ local list: { Entry } = { mime = { "application/vnd.autodesk.fbx", "model/fbx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate", "core/Base64", "codecs/model/Mat4" }, caps = { decode = true, encode = true, binary = true, ascii = true, materials = true, animation = true, skins = true, morphTargets = true, cameras = true, lights = true, polygons = true }, + sniff = 2, load = function() return __include("model/fbx") end, @@ -2432,6 +2542,7 @@ local list: { Entry } = { mime = { "model/gltf+json", "model/gltf-binary" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Json", "core/Base64", "core/Sniff", "codecs/model/Draco" }, caps = { decode = true, encode = true, binary = true, materials = true, animation = true, skins = true, morphTargets = true, cameras = true, lights = true, draco = true }, + sniff = 0, load = function() return __include("model/gltf") end, @@ -2444,6 +2555,7 @@ local list: { Entry } = { mime = { "application/x-godot-scene" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/GodotVariant", "codecs/model/Mat4" }, caps = { decode = true, encode = true, text = true, materials = true, cameras = true, lights = true, instances = true }, + sniff = 0, load = function() return __include("model/godot") end, @@ -2456,6 +2568,7 @@ local list: { Entry } = { mime = { "model/x-iqm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Mat4", "codecs/model/Rig", "codecs/model/Sampler" }, caps = { decode = true, encode = true, materials = true, skins = true, animation = true, vertexColors = true }, + sniff = 0, load = function() return __include("model/iqm") end, @@ -2468,6 +2581,7 @@ local list: { Entry } = { mime = { "application/x-ldraw", "application/x-multi-part-ldraw" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types" }, caps = { decode = true, encode = false, materials = true, lines = true, instancing = true }, + sniff = 0, load = function() return __include("model/ldraw") end, @@ -2480,6 +2594,7 @@ local list: { Entry } = { mime = { "image/x-lwo", "model/x-lwo" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks" }, caps = { decode = true, encode = false, materials = true, polygons = true, vertexColors = true, morphTargets = true }, + sniff = 0, load = function() return __include("model/lwo") end, @@ -2492,6 +2607,7 @@ local list: { Entry } = { mime = { "text/x-quake-map" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Miptex", "codecs/model/Brush", "codecs/model/Patch" }, caps = { decode = true, encode = true, variants = { "quake", "valve220", "quake2", "quake3" }, patches = true }, + sniff = 0, load = function() return __include("model/map") end, @@ -2504,6 +2620,7 @@ local list: { Entry } = { mime = { "application/x-minecraft-region" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate", "codecs/text/Nbt", "codecs/model/Minecraft", "codecs/compress/Lz4" }, caps = { decode = true, encode = false, voxels = true, blocks = true }, + sniff = 0, load = function() return __include("model/mca") end, @@ -2516,6 +2633,7 @@ local list: { Entry } = { mime = { "model/x-md2" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/Rig" }, caps = { decode = true, encode = false, morph = true, animation = true }, + sniff = 0, load = function() return __include("model/md2") end, @@ -2528,6 +2646,7 @@ local list: { Entry } = { mime = { "model/x-md3" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/Mat4", "codecs/model/Rig" }, caps = { decode = true, encode = false, morph = true, animation = true, tags = true }, + sniff = 0, load = function() return __include("model/md3") end, @@ -2540,6 +2659,7 @@ local list: { Entry } = { mime = { "model/x-md5mesh", "model/x-md5anim" }, deps = { "core/Err", "core/Bytes", "core/Input", "core/Sniff", "Types", "codecs/model/Rig" }, caps = { decode = true, encode = false, skins = true, animation = true }, + sniff = 0, load = function() return __include("model/md5") end, @@ -2552,6 +2672,7 @@ local list: { Entry } = { mime = { "model/x-mdl" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Pixels", "codecs/model/Mat4", "codecs/model/Rig", "codecs/model/SourceAnim" }, caps = { decode = true, encode = false, variants = { "quake", "halflife" }, morph = true, skins = true, animation = true }, + sniff = 0, load = function() return __include("model/mdl") end, @@ -2564,6 +2685,7 @@ local list: { Entry } = { mime = { "application/x-ms3d" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Mat4", "codecs/model/MeshFlatten" }, caps = { decode = true, encode = true, materials = true, skins = true, animation = true }, + sniff = 1, load = function() return __include("model/ms3d") end, @@ -2576,6 +2698,7 @@ local list: { Entry } = { mime = { "model/obj" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, materials = true, polygons = true, vertexColors = true }, + sniff = 0, load = function() return __include("model/obj") end, @@ -2588,6 +2711,7 @@ local list: { Entry } = { mime = { "model/off", "text/plain" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/MeshFlatten" }, caps = { decode = true, encode = true, polygons = true, points = true, colors = true, binary = false }, + sniff = 0, load = function() return __include("model/off") end, @@ -2600,6 +2724,7 @@ local list: { Entry } = { mime = { "model/ply", "application/ply" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/MeshFlatten" }, caps = { decode = true, encode = true, ascii = true, binary = true, polygons = true, points = true, colors = true }, + sniff = 0, load = function() return __include("model/ply") end, @@ -2612,6 +2737,7 @@ local list: { Entry } = { mime = { "model/x-pmx", "model/x-pmd" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Text" }, caps = { decode = true, encode = false, materials = true, skins = true, morphTargets = true, pmd = true }, + sniff = 0, load = function() return __include("model/pmx") end, @@ -2624,6 +2750,7 @@ local list: { Entry } = { mime = { "model/x-doom3-proc" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/Lexer" }, caps = { decode = true, encode = false, portals = true }, + sniff = 0, load = function() return __include("model/proc") end, @@ -2636,6 +2763,7 @@ local list: { Entry } = { mime = { "model/x-qubicle" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, voxels = true, truecolor = true }, + sniff = 0, load = function() return __include("model/qb") end, @@ -2648,6 +2776,8 @@ local list: { Entry } = { mime = { "application/x-roblox-rbxm", "application/x-roblox-rbxl" }, deps = { "core/Err", "core/Bytes", "core/Md5", "codecs/compress/Lz4", "codecs/compress/Zstd", "codecs/model/Rbx", "codecs/model/Rbx/Binary" }, caps = { decode = true, encode = true, tree = true, compression = { "none", "lz4", "zstd" } }, + sniff = 0, + variant = true, load = function() return __include("model/rbxm") end, @@ -2660,6 +2790,8 @@ local list: { Entry } = { mime = { "application/x-roblox-rbxmx", "application/x-roblox-rbxlx" }, deps = { "core/Err", "core/Bytes", "core/Base64", "core/Md5", "codecs/text/Xml", "codecs/model/Rbx" }, caps = { decode = true, encode = true, tree = true }, + sniff = 0, + variant = true, load = function() return __include("model/rbxmx") end, @@ -2672,6 +2804,7 @@ local list: { Entry } = { mime = { "application/x-roblox-mesh" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Mat4", "codecs/model/MeshFlatten", "codecs/model/Draco" }, caps = { decode = true, encode = true, skinning = true, lods = true, versions = { "1.00", "1.01", "2.00", "3.00", "3.01", "4.00", "4.01", "5.00", "6.00", "7.00" } }, + sniff = 0, load = function() return __include("model/robloxmesh") end, @@ -2684,6 +2817,8 @@ local list: { Entry } = { mime = { "application/x-minecraft-schematic" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Nbt", "codecs/model/Minecraft" }, caps = { decode = true, encode = true, voxels = true, blocks = true, variants = { "schem", "schematic", "litematic" } }, + sniff = 1, + variant = true, load = function() return __include("model/schematic") end, @@ -2696,6 +2831,7 @@ local list: { Entry } = { mime = { "model/x-smd", "text/plain" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/Mat4", "codecs/model/MeshFlatten", "codecs/model/Rig" }, caps = { decode = true, encode = true, skins = true, animation = true }, + sniff = 0, load = function() return __include("model/smd") end, @@ -2708,6 +2844,7 @@ local list: { Entry } = { mime = { "model/x-source-mdl" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Half", "codecs/model/Mat4", "codecs/model/Rig", "codecs/model/SourceAnim", "codecs/text/KeyValues" }, caps = { decode = true, encode = false, skins = true, morph = true, animation = true, lods = true }, + sniff = 0, load = function() return __include("model/sourcemdl") end, @@ -2720,6 +2857,7 @@ local list: { Entry } = { mime = { "model/stl", "application/sla" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/MeshFlatten" }, caps = { decode = true, encode = true, ascii = true, binary = true, colors = true, indexed = false }, + sniff = 0, load = function() return __include("model/stl") end, @@ -2732,6 +2870,7 @@ local list: { Entry } = { mime = { "text/x-unreal-t3d" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/Text", "codecs/model/Brush" }, caps = { decode = true, encode = false, text = true, brushes = true, actors = true }, + sniff = 0, load = function() return __include("model/t3d") end, @@ -2744,6 +2883,7 @@ local list: { Entry } = { mime = { "text/x-udmf" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/DoomMap" }, caps = { decode = true, encode = false, maps = true }, + sniff = 0, load = function() return __include("model/udmf") end, @@ -2756,6 +2896,7 @@ local list: { Entry } = { mime = { "model/vnd.usda", "model/vnd.usdz+zip" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Zip", "codecs/model/Mat4" }, caps = { decode = true, encode = true, materials = true, animation = true, cameras = true, lights = true, polygons = true, vertexColors = true, usdz = "read", usdc = false }, + sniff = 0, load = function() return __include("model/usda") end, @@ -2768,6 +2909,7 @@ local list: { Entry } = { mime = { "model/x-vbsp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Lzma", "codecs/text/KeyValues", "codecs/model/Mat4", "codecs/model/Displacement", "containers/Zip", "containers/Archive" }, caps = { decode = true, encode = false, versions = { 19, 20, 21 }, displacements = true, staticProps = true, pak = true }, + sniff = 0, load = function() return __include("model/vbsp") end, @@ -2780,6 +2922,7 @@ local list: { Entry } = { mime = { "model/x-vmf" }, deps = { "core/Err", "core/Bytes", "core/Input", "core/Sniff", "Types", "codecs/text/KeyValues", "codecs/model/Brush", "codecs/model/Displacement", "codecs/model/Mat4" }, caps = { decode = true, encode = true, displacements = true, roundTrip = true }, + sniff = 0, load = function() return __include("model/vmf") end, @@ -2792,6 +2935,7 @@ local list: { Entry } = { mime = { "model/x-vox" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, voxels = true, sceneGraph = true, materials = true }, + sniff = 0, load = function() return __include("model/vox") end, @@ -2804,6 +2948,7 @@ local list: { Entry } = { mime = { "model/vrml", "x-world/x-vrml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Vrml" }, caps = { decode = true, encode = true, materials = true, polygons = true, animation = true, cameras = true, lights = true, lines = true, points = true }, + sniff = 0, load = function() return __include("model/vrml") end, @@ -2816,6 +2961,7 @@ local list: { Entry } = { mime = { "model/x-directx", "text/x-directx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate", "codecs/model/Mat4", "codecs/model/Rig" }, caps = { decode = true, encode = false, text = true, binary = true, compressed = true, materials = true, skins = true, animation = true, polygons = true, vertexColors = true }, + sniff = 0, load = function() return __include("model/x") end, @@ -2828,6 +2974,7 @@ local list: { Entry } = { mime = { "model/x3d+xml", "model/x3d-vrml", "model/x3d+fastinfoset" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Vrml" }, caps = { decode = true, encode = true, materials = true, polygons = true, animation = true, cameras = true, lights = true, lines = true, points = true, xml = true, classic = true }, + sniff = 0, load = function() return __include("model/x3d") end, @@ -2840,6 +2987,7 @@ local list: { Entry } = { mime = { "model/step", "application/step", "application/p21" }, deps = { "core/Err", "core/Bytes", "Types", "core/Sniff" }, caps = { decode = true, encode = true, complexEntities = true, sections = true, brep = "plugin", tessellate = "plugin" }, + sniff = 0, load = function() return __include("cad/step") end, @@ -2852,6 +3000,7 @@ local list: { Entry } = { mime = { "application/x-font-bdf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/font/Bitmap" }, caps = { decode = true, encode = true, bitmap = true }, + sniff = 0, load = function() return __include("font/bdf") end, @@ -2864,6 +3013,7 @@ local list: { Entry } = { mime = { "application/x-bmfont" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, bitmap = true, variants = { "text", "xml", "binary" }, extraFiles = true }, + sniff = 0, load = function() return __include("font/bmfont") end, @@ -2876,6 +3026,7 @@ local list: { Entry } = { mime = { "application/vnd.ms-fontobject" }, deps = { "core/Err", "core/Bytes", "codecs/text/Text", "codecs/font/TrueType" }, caps = { decode = true, encode = true, variants = { "1.0", "2.1", "2.2" } }, + sniff = 0, load = function() return __include("font/eot") end, @@ -2888,6 +3039,7 @@ local list: { Entry } = { mime = { "application/x-font-fnt" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Text", "codecs/font/Bitmap" }, caps = { decode = true, encode = false, bitmap = true, variants = { "fnt2", "fnt3", "ne", "pe" } }, + sniff = 0, load = function() return __include("font/fon") end, @@ -2900,6 +3052,7 @@ local list: { Entry } = { mime = { "application/x-hershey-font" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Raster" }, caps = { decode = true, encode = false, strokes = true }, + sniff = 0, load = function() return __include("font/hershey") end, @@ -2912,6 +3065,7 @@ local list: { Entry } = { mime = { "application/x-font-pcf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/font/Bitmap" }, caps = { decode = true, encode = false, bitmap = true }, + sniff = 0, load = function() return __include("font/pcf") end, @@ -2924,6 +3078,7 @@ local list: { Entry } = { mime = { "application/x-font-linux-psf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/font/Bitmap" }, caps = { decode = true, encode = true, bitmap = true, variants = { "psf1", "psf2" } }, + sniff = 0, load = function() return __include("font/psf") end, @@ -2936,6 +3091,7 @@ local list: { Entry } = { mime = { "font/ttf", "font/otf", "font/collection" }, deps = { "core/Err", "core/Bytes", "codecs/font/TrueType" }, caps = { decode = true, encode = false, outlines = { "truetype", "cff" }, collection = true, kerning = true }, + sniff = 0, load = function() return __include("font/ttf") end, @@ -2948,6 +3104,7 @@ local list: { Entry } = { mime = { "application/x-font-type1" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Raster", "codecs/font/GlyphNames" }, caps = { decode = true, encode = false, outlines = { "type1" }, variants = { "pfb", "pfa" } }, + sniff = 0, load = function() return __include("font/type1") end, @@ -2960,6 +3117,7 @@ local list: { Entry } = { mime = { "font/woff" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Deflate", "codecs/font/TrueType" }, caps = { decode = true, encode = false, outlines = { "truetype", "cff" } }, + sniff = 0, load = function() return __include("font/woff") end, @@ -2972,6 +3130,7 @@ local list: { Entry } = { mime = { "font/woff2" }, deps = { "core/Err", "core/Bytes", "codecs/font/TrueType", "codecs/compress/Brotli" }, caps = { decode = true, encode = false, outlines = { "truetype", "cff" }, transforms = { "glyf", "loca", "hmtx" } }, + sniff = 0, load = function() return __include("font/woff2") end, @@ -2984,6 +3143,7 @@ local list: { Entry } = { mime = { "application/x-7z-compressed" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "Types", "codecs/compress/Lzma", "codecs/compress/Deflate", "codecs/compress/Bzip2", "codecs/compress/Zstd", "containers/Archive", "codecs/text/Text" }, caps = { decode = true, encode = false, methods = { "copy", "lzma", "lzma2", "deflate", "bcj", "delta" }, encrypted = false }, + sniff = 0, load = function() return __include("archive/7z") end, @@ -2996,6 +3156,7 @@ local list: { Entry } = { mime = { "application/x-amiga-disk-format" }, deps = { "core/Err", "core/Bytes", "containers/Archive" }, caps = { decode = true, encode = false, variants = { "ofs", "ffs" } }, + sniff = 0, load = function() return __include("archive/adf") end, @@ -3008,6 +3169,7 @@ local list: { Entry } = { mime = { "application/applefile", "multipart/appledouble" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/MacFile" }, caps = { decode = true, encode = true, forks = true, variants = { "applesingle", "appledouble" } }, + sniff = 0, load = function() return __include("archive/applesingle") end, @@ -3020,6 +3182,7 @@ local list: { Entry } = { mime = { "application/x-archive", "application/vnd.debian.binary-package" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Deflate", "codecs/compress/Lzma", "codecs/compress/Zstd", "codecs/compress/Bzip2", "containers/Archive", "containers/Tar" }, caps = { decode = true, encode = true, variants = { "gnu", "bsd" }, deb = true }, + sniff = 0, load = function() return __include("archive/ar") end, @@ -3032,6 +3195,7 @@ local list: { Entry } = { mime = { "application/x-arj" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "codecs/compress/Lzh", "containers/Archive" }, caps = { decode = true, encode = false, methods = { "store", "arj1", "arj2", "arj3", "arj4" } }, + sniff = 0, load = function() return __include("archive/arj") end, @@ -3044,6 +3208,7 @@ local list: { Entry } = { mime = { "application/mac-binhex40" }, deps = { "core/Err", "core/Bytes", "core/Crc16", "containers/Archive", "containers/MacFile" }, caps = { decode = true, encode = true, forks = true }, + sniff = 0, load = function() return __include("archive/binhex") end, @@ -3056,6 +3221,7 @@ local list: { Entry } = { mime = { "application/x-brotli" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Brotli", "containers/Archive" }, caps = { decode = true, encode = false, stream = true }, + sniff = 1, load = function() return __include("archive/br") end, @@ -3068,6 +3234,7 @@ local list: { Entry } = { mime = { "application/x-bzip2" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "codecs/compress/Bzip2" }, caps = { decode = true, encode = false, stream = true }, + sniff = 0, load = function() return __include("archive/bz2") end, @@ -3080,6 +3247,7 @@ local list: { Entry } = { mime = { "application/vnd.ms-cab-compressed" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Deflate", "codecs/compress/Lzx", "codecs/compress/Quantum", "containers/Archive" }, caps = { decode = true, encode = true, methods = { "store", "mszip", "lzx", "quantum" } }, + sniff = 0, load = function() return __include("archive/cab") end, @@ -3092,6 +3260,7 @@ local list: { Entry } = { mime = { "application/x-cpio" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/Cpio" }, caps = { decode = true, encode = true, variants = { "newc", "crc", "odc", "bin" } }, + sniff = 0, load = function() return __include("archive/cpio") end, @@ -3104,6 +3273,7 @@ local list: { Entry } = { mime = { "application/x-d64" }, deps = { "core/Err", "core/Bytes", "containers/Archive" }, caps = { decode = true, encode = true, variants = { "d64", "d71", "d81" } }, + sniff = 0, load = function() return __include("archive/d64") end, @@ -3116,6 +3286,7 @@ local list: { Entry } = { mime = { "application/x-fat-image" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/Fat" }, caps = { decode = true, encode = true, variants = { "fat12", "fat16", "fat32" } }, + sniff = 1, load = function() return __include("archive/fat") end, @@ -3128,6 +3299,7 @@ local list: { Entry } = { mime = { "application/x-build-grp" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "containers/Archive" }, caps = { decode = true, encode = true }, + sniff = 0, load = function() return __include("archive/grp") end, @@ -3140,6 +3312,7 @@ local list: { Entry } = { mime = { "application/gzip" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "codecs/compress/Deflate", "containers/Archive", "containers/Tar" }, caps = { decode = true, encode = true, stream = true }, + sniff = 0, load = function() return __include("archive/gzip") end, @@ -3152,6 +3325,7 @@ local list: { Entry } = { mime = { "application/x-iso9660-image" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/Iso9660" }, caps = { decode = true, encode = false, extensions = { "joliet", "rockridge", "eltorito" } }, + sniff = 0, load = function() return __include("archive/iso") end, @@ -3164,6 +3338,7 @@ local list: { Entry } = { mime = { "application/x-lzh-compressed" }, deps = { "core/Err", "core/Bytes", "core/Crc16", "codecs/compress/Lzh", "containers/Archive" }, caps = { decode = true, encode = true, methods = { "lh0", "lh1", "lh4", "lh5", "lh6", "lh7", "lhx", "lzs", "lz5", "lz4", "lhd" } }, + sniff = 0, load = function() return __include("archive/lha") end, @@ -3176,6 +3351,7 @@ local list: { Entry } = { mime = { "application/x-lz4" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Lz4", "codecs/compress/Xxh32", "containers/Archive" }, caps = { decode = true, encode = true, stream = true, legacy = true }, + sniff = 0, load = function() return __include("archive/lz4") end, @@ -3188,6 +3364,7 @@ local list: { Entry } = { mime = { "application/x-macbinary" }, deps = { "core/Err", "core/Bytes", "core/Crc16", "containers/Archive", "containers/MacFile" }, caps = { decode = true, encode = true, forks = true, variants = { "I", "II", "III" } }, + sniff = 0, load = function() return __include("archive/macbinary") end, @@ -3200,6 +3377,7 @@ local list: { Entry } = { mime = { "application/x-mpq" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "codecs/compress/Deflate", "codecs/compress/Bzip2", "codecs/compress/Lzma", "codecs/compress/Explode" }, caps = { decode = true, encode = false, versions = { 1, 2, 3, 4 }, methods = { "zlib", "implode", "bzip2", "lzma", "sparse" }, encryption = true }, + sniff = 0, load = function() return __include("archive/mpq") end, @@ -3212,6 +3390,7 @@ local list: { Entry } = { mime = { "application/x-pak" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "containers/Archive" }, caps = { decode = true, encode = true, variants = { "quake", "sin" } }, + sniff = 0, load = function() return __include("archive/pak") end, @@ -3224,6 +3403,7 @@ local list: { Entry } = { mime = { "application/x-rpm" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Deflate", "codecs/compress/Lzma", "codecs/compress/Zstd", "codecs/compress/Bzip2", "containers/Archive", "containers/Cpio" }, caps = { decode = true, encode = false, compressors = { "gzip", "bzip2", "xz", "lzma", "zstd" } }, + sniff = 0, load = function() return __include("archive/rpm") end, @@ -3236,6 +3416,7 @@ local list: { Entry } = { mime = { "application/x-tar" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/Tar" }, caps = { decode = true, encode = true, variants = { "ustar", "pax", "gnu" } }, + sniff = 1, load = function() return __include("archive/tar") end, @@ -3248,6 +3429,7 @@ local list: { Entry } = { mime = { "application/x-unitypackage" }, deps = { "core/Err", "core/Bytes", "core/Md5", "codecs/compress/Deflate", "containers/Archive", "containers/Tar" }, caps = { decode = true, encode = true }, + sniff = 1, load = function() return __include("archive/unitypackage") end, @@ -3260,6 +3442,7 @@ local list: { Entry } = { mime = { "text/x-uuencode" }, deps = { "core/Err", "core/Bytes", "core/Base64", "containers/Archive" }, caps = { decode = true, encode = true, variants = { "uu", "xx", "base64" } }, + sniff = 0, load = function() return __include("archive/uu") end, @@ -3272,6 +3455,7 @@ local list: { Entry } = { mime = { "application/x-vpk" }, deps = { "core/Err", "core/Bytes", "core/Input", "core/Crc32", "core/Md5", "containers/Archive" }, caps = { decode = true, encode = true, versions = { 1, 2 }, multipart = true }, + sniff = 0, load = function() return __include("archive/vpk") end, @@ -3284,6 +3468,7 @@ local list: { Entry } = { mime = { "application/x-wolf3d-vswap" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Archive", "codecs/image/Pixels" }, caps = { decode = true, encode = false, images = true, sounds = true }, + sniff = 0, load = function() return __include("archive/vswap") end, @@ -3296,6 +3481,7 @@ local list: { Entry } = { mime = { "application/x-doom" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Archive", "codecs/image/Pixels", "codecs/model/DoomMap" }, caps = { decode = true, encode = true, images = true, maps = true, variants = { "iwad", "pwad" } }, + sniff = 0, load = function() return __include("archive/wad") end, @@ -3308,6 +3494,7 @@ local list: { Entry } = { mime = { "application/x-quake-wad" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "containers/Archive", "codecs/image/Pixels", "codecs/image/Miptex" }, caps = { decode = true, encode = true, images = true, variants = { "wad2", "wad3" } }, + sniff = 0, load = function() return __include("archive/wad2") end, @@ -3320,6 +3507,7 @@ local list: { Entry } = { mime = { "application/x-xz", "application/x-lzma" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Lzma", "containers/Archive" }, caps = { decode = true, encode = false, stream = true, filters = { "lzma2", "lzma", "delta", "x86", "powerpc", "arm", "armthumb", "sparc", "arm64" } }, + sniff = 0, load = function() return __include("archive/xz") end, @@ -3332,6 +3520,7 @@ local list: { Entry } = { mime = { "application/x-yenc" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "containers/Archive" }, caps = { decode = true, encode = true, multipart = true }, + sniff = 0, load = function() return __include("archive/yenc") end, @@ -3344,6 +3533,7 @@ local list: { Entry } = { mime = { "application/x-compress" }, deps = { "core/Err", "core/Bytes", "codecs/compress/UnixCompress", "containers/Archive" }, caps = { decode = true, encode = true, stream = true, bits = { 9, 16 } }, + sniff = 0, load = function() return __include("archive/z") end, @@ -3356,6 +3546,7 @@ local list: { Entry } = { mime = { "application/zip", "application/x-zip-compressed" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Zip" }, caps = { decode = true, encode = true, methods = { "store", "deflate" }, zip64 = true }, + sniff = 0, load = function() return __include("archive/zip") end, @@ -3368,6 +3559,7 @@ local list: { Entry } = { mime = { "application/x-zoo" }, deps = { "core/Err", "core/Bytes", "core/Crc16", "codecs/compress/Lzw", "codecs/compress/Lzh", "containers/Archive" }, caps = { decode = true, encode = false, methods = { "store", "lzw", "lzh" } }, + sniff = 0, load = function() return __include("archive/zoo") end, @@ -3380,6 +3572,7 @@ local list: { Entry } = { mime = { "application/zstd" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Zstd", "containers/Archive" }, caps = { decode = true, encode = false, stream = true }, + sniff = 1, load = function() return __include("archive/zst") end, @@ -3392,6 +3585,7 @@ local list: { Entry } = { mime = { "application/cbor", "application/cbor-seq" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, binary = true, ordered = true, tags = true }, + sniff = 0, load = function() return __include("data/cbor") end, @@ -3404,6 +3598,7 @@ local list: { Entry } = { mime = { "text/csv", "text/tab-separated-values" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Json", "core/Sniff" }, caps = { decode = true, encode = true, header = true }, + sniff = 0, load = function() return __include("data/csv") end, @@ -3416,6 +3611,7 @@ local list: { Entry } = { mime = { "text/plain" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Json", "core/Sniff" }, caps = { decode = true, encode = true, ordered = true }, + sniff = 0, load = function() return __include("data/ini") end, @@ -3428,6 +3624,7 @@ local list: { Entry } = { mime = { "application/json", "application/x-ndjson" }, deps = { "core/Err", "core/Bytes", "codecs/text/Json", "core/Sniff" }, caps = { decode = true, encode = true, ordered = true, streaming = true }, + sniff = 0, load = function() return __include("data/json") end, @@ -3440,6 +3637,7 @@ local list: { Entry } = { mime = { "application/msgpack", "application/x-msgpack" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, binary = true, ordered = true }, + sniff = 0, load = function() return __include("data/msgpack") end, @@ -3452,6 +3650,7 @@ local list: { Entry } = { mime = { "application/x-minecraft-nbt" }, deps = { "core/Err", "core/Bytes", "codecs/text/Nbt" }, caps = { decode = true, encode = true, binary = true, ordered = true, typed = true }, + sniff = 1, load = function() return __include("data/nbt") end, @@ -3464,6 +3663,7 @@ local list: { Entry } = { mime = { "application/x-plist", "application/x-bplist" }, deps = { "core/Err", "core/Bytes", "Types", "core/Base64", "codecs/text/Xml", "codecs/text/Json" }, caps = { decode = true, encode = true, binary = "read", ordered = true }, + sniff = 0, load = function() return __include("data/plist") end, @@ -3476,6 +3676,7 @@ local list: { Entry } = { mime = { "text/x-quake3-shader" }, deps = { "core/Err", "core/Bytes" }, caps = { decode = true, encode = true }, + sniff = 0, load = function() return __include("data/q3shader") end, @@ -3488,6 +3689,7 @@ local list: { Entry } = { mime = { "text/x-quake3-skin" }, deps = { "core/Err", "core/Bytes" }, caps = { decode = true, encode = true }, + sniff = 0, load = function() return __include("data/q3skin") end, @@ -3500,6 +3702,7 @@ local list: { Entry } = { mime = { "text/x-minecraft-snbt" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "codecs/text/Nbt" }, caps = { decode = true, encode = true, ordered = true, typed = true }, + sniff = 0, load = function() return __include("data/snbt") end, @@ -3512,6 +3715,7 @@ local list: { Entry } = { mime = { "application/toml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Json", "codecs/text/Text" }, caps = { decode = true, encode = true, ordered = true, dates = true }, + sniff = 0, load = function() return __include("data/toml") end, @@ -3524,6 +3728,7 @@ local list: { Entry } = { mime = { "application/x-godot-resource" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/GodotVariant" }, caps = { decode = true, encode = true, ordered = true }, + sniff = 0, load = function() return __include("data/tres") end, @@ -3536,6 +3741,7 @@ local list: { Entry } = { mime = { "text/x-vdf" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "codecs/text/KeyValues" }, caps = { decode = true, encode = true, ordered = true, binary = true }, + sniff = 1, load = function() return __include("data/vdf") end, @@ -3548,6 +3754,7 @@ local list: { Entry } = { mime = { "application/xml", "text/xml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Xml", "core/Sniff" }, caps = { decode = true, encode = true, namespaces = true, streaming = true }, + sniff = 0, load = function() return __include("data/xml") end, @@ -3560,6 +3767,7 @@ local list: { Entry } = { mime = { "application/yaml", "application/x-yaml", "text/yaml" }, deps = { "core/Err", "core/Bytes", "Types", "core/Base64", "codecs/text/Text" }, caps = { decode = true, encode = true, ordered = true, multiDocument = true, anchors = true }, + sniff = 0, load = function() return __include("data/yaml") end, @@ -3572,6 +3780,7 @@ local list: { Entry } = { mime = { "application/x-wolf3d-gamemaps" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types" }, caps = { decode = true, encode = false, tilemap = true }, + sniff = 0, load = function() return __include("vector/gamemaps") end, @@ -3584,6 +3793,7 @@ local list: { Entry } = { mime = { "application/x-ldtk+json" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/Json" }, caps = { decode = true, encode = true, levels = true, worlds = true, intGrid = true, entities = true }, + sniff = 0, load = function() return __include("vector/ldtk") end, @@ -3596,6 +3806,7 @@ local list: { Entry } = { mime = { "application/x-ogmo+json" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "core/Base64", "Types", "codecs/text/Json" }, caps = { decode = true, encode = true, projects = true, entities = true, decals = true }, + sniff = 0, load = function() return __include("vector/ogmo") end, @@ -3608,6 +3819,7 @@ local list: { Entry } = { mime = { "image/svg+xml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Xml", "codecs/image/Raster", "codecs/image/Blend", "core/Sniff" }, caps = { decode = true, encode = true, rasterize = true, text = false }, + sniff = 0, load = function() return __include("vector/svg") end, @@ -3620,6 +3832,7 @@ local list: { Entry } = { mime = { "application/x-tiled-tmx", "application/x-tiled-tmj" }, deps = { "core/Err", "core/Bytes", "core/Base64", "Types", "codecs/text/Xml", "codecs/text/Json", "codecs/compress/Deflate", "core/Sniff" }, caps = { decode = true, encode = true, tilesets = true, infinite = true }, + sniff = 0, load = function() return __include("vector/tiled") end, @@ -3632,6 +3845,7 @@ local list: { Entry } = { mime = { "image/x-aseprite" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate" }, caps = { decode = true, encode = true, layers = true, groups = true, animation = true, depths = { 8, 16, 32 } }, + sniff = 0, load = function() return __include("layered/aseprite") end, @@ -3644,6 +3858,7 @@ local list: { Entry } = { mime = { "image/openraster" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Zip", "codecs/text/Xml", "codecs/image/Blend" }, caps = { decode = true, encode = true, layers = true, groups = true, depths = { 8 } }, + sniff = 0, load = function() return __include("layered/ora") end, @@ -3656,6 +3871,7 @@ local list: { Entry } = { mime = { "image/vnd.adobe.photoshop" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Blend", "codecs/compress/Deflate", "codecs/compress/PackBits", "codecs/text/Text" }, caps = { decode = true, encode = true, layers = true, groups = true, depths = { 1, 8, 16, 32 } }, + sniff = 0, load = function() return __include("layered/psd") end, @@ -3668,6 +3884,7 @@ local list: { Entry } = { mime = { "text/x-ssa", "text/x-ass" }, deps = { "core/Err", "core/Bytes", "Types", "core/Sniff" }, caps = { decode = true, encode = true, styles = true }, + sniff = 0, load = function() return __include("subtitle/ass") end, @@ -3680,6 +3897,7 @@ local list: { Entry } = { mime = { "application/x-subrip", "text/srt" }, deps = { "core/Err", "core/Bytes", "Types", "core/Sniff" }, caps = { decode = true, encode = true, styles = false }, + sniff = 0, load = function() return __include("subtitle/srt") end, @@ -3692,6 +3910,7 @@ local list: { Entry } = { mime = { "text/vtt" }, deps = { "core/Err", "core/Bytes", "Types", "core/Sniff" }, caps = { decode = true, encode = true, styles = true }, + sniff = 0, load = function() return __include("subtitle/vtt") end, @@ -3704,6 +3923,7 @@ local list: { Entry } = { mime = { "audio/x-669" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 8, 8 } }, + sniff = 0, load = function() return __include("music/669") end, @@ -3716,6 +3936,7 @@ local list: { Entry } = { mime = { "audio/x-ahx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Hively" }, caps = { decode = true, encode = false, render = true, channels = { 4, 4 }, subsongs = true }, + sniff = 0, load = function() return __include("music/ahx") end, @@ -3728,6 +3949,7 @@ local list: { Entry } = { mime = { "audio/x-far" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 16, 16 } }, + sniff = 0, load = function() return __include("music/far") end, @@ -3740,6 +3962,7 @@ local list: { Entry } = { mime = { "audio/x-hmp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/MidiRender" }, caps = { decode = true, encode = false, render = true, hmi = true }, + sniff = 0, load = function() return __include("music/hmp") end, @@ -3752,6 +3975,7 @@ local list: { Entry } = { mime = { "audio/x-hvl" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Hively" }, caps = { decode = true, encode = false, render = true, channels = { 4, 16 }, subsongs = true }, + sniff = 0, load = function() return __include("music/hvl") end, @@ -3764,6 +3988,7 @@ local list: { Entry } = { mime = { "audio/it", "audio/x-it" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker" }, caps = { decode = true, encode = false, render = true, channels = { 1, 64 }, compressedSamples = true }, + sniff = 0, load = function() return __include("music/it") end, @@ -3776,6 +4001,7 @@ local list: { Entry } = { mime = { "audio/x-med" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 1, 64 } }, + sniff = 0, load = function() return __include("music/med") end, @@ -3788,6 +4014,7 @@ local list: { Entry } = { mime = { "audio/midi", "audio/x-midi" }, deps = { "core/Err", "core/Bytes", "codecs/audio/MidiRender", "Types" }, caps = { decode = true, encode = true, formats = { 0, 1, 2 }, render = true, streaming = true, rmid = true }, + sniff = 0, load = function() return __include("music/midi") end, @@ -3800,6 +4027,7 @@ local list: { Entry } = { mime = { "audio/x-mod", "audio/mod" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker" }, caps = { decode = true, encode = true, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return __include("music/mod") end, @@ -3812,6 +4040,7 @@ local list: { Entry } = { mime = { "audio/x-mtm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return __include("music/mtm") end, @@ -3824,6 +4053,7 @@ local list: { Entry } = { mime = { "audio/x-mus" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/MidiRender" }, caps = { decode = true, encode = false, render = true }, + sniff = 0, load = function() return __include("music/mus") end, @@ -3836,6 +4066,7 @@ local list: { Entry } = { mime = { "audio/x-okt" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 4, 8 } }, + sniff = 0, load = function() return __include("music/okt") end, @@ -3848,6 +4079,7 @@ local list: { Entry } = { mime = { "audio/x-ptm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return __include("music/ptm") end, @@ -3860,6 +4092,7 @@ local list: { Entry } = { mime = { "audio/s3m", "audio/x-s3m" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker" }, caps = { decode = true, encode = false, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return __include("music/s3m") end, @@ -3872,6 +4105,7 @@ local list: { Entry } = { mime = { "audio/x-soundfont" }, deps = { "core/Err", "core/Bytes", "codecs/audio/SoundFont" }, caps = { decode = true, encode = false, sm24 = true, sf3 = false }, + sniff = 1, load = function() return __include("music/sf2") end, @@ -3884,6 +4118,7 @@ local list: { Entry } = { mime = { "audio/x-stm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 4, 4 } }, + sniff = 0, load = function() return __include("music/stm") end, @@ -3896,6 +4131,7 @@ local list: { Entry } = { mime = { "audio/x-ult" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return __include("music/ult") end, @@ -3908,6 +4144,7 @@ local list: { Entry } = { mime = { "audio/x-umx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker" }, caps = { decode = true, encode = false, render = true, container = true }, + sniff = 0, load = function() return __include("music/umx") end, @@ -3920,6 +4157,7 @@ local list: { Entry } = { mime = { "audio/xm", "audio/x-xm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Adpcm" }, caps = { decode = true, encode = true, render = true, channels = { 1, 64 } }, + sniff = 0, load = function() return __include("music/xm") end, @@ -3932,6 +4170,7 @@ local list: { Entry } = { mime = { "audio/x-xmidi" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks", "codecs/audio/MidiRender" }, caps = { decode = true, encode = false, render = true, songs = true }, + sniff = 0, load = function() return __include("music/xmi") end, @@ -3944,6 +4183,7 @@ local list: { Entry } = { mime = { "audio/x-mpegurl", "audio/mpegurl", "application/vnd.apple.mpegurl", "application/x-mpegurl" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Url", "codecs/text/Text", "core/Sniff" }, caps = { decode = true, encode = true, hls = true }, + sniff = 0, load = function() return __include("playlist/m3u") end, @@ -3956,6 +4196,7 @@ local list: { Entry } = { mime = { "audio/x-scpls", "audio/scpls" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Url", "codecs/text/Text", "core/Sniff" }, caps = { decode = true, encode = true }, + sniff = 1, load = function() return __include("playlist/pls") end, @@ -3968,6 +4209,7 @@ local list: { Entry } = { mime = { "application/xspf+xml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Url", "codecs/text/Xml" }, caps = { decode = true, encode = true }, + sniff = 0, load = function() return __include("playlist/xspf") end, @@ -8478,6 +8720,19 @@ end return Input end +end + + + + + + Core_2 + --!optimize 2 +--!nocheck +-- rosetta chunk Core_2 (build/Rosetta.rbxm): GENERATED by tools/bundle.py from src/Rosetta - do not edit. +-- 3 modules (1 native: @native); the Rosetta root requires it when one of them is first included. +-- Error lines map back to the sources through Rosetta.rbxm.linemap.json (tools/bundle.py --where). +return function(__FILES, __include) __FILES["host"] = function() -- host: the runtime adapter, detected once at load time. Roblox (no file system; toEditableImage), LÖVE @@ -8523,19 +8778,6 @@ end local _ = Err return host end -end - - - - - - Core_2 - --!optimize 2 ---!nocheck --- rosetta chunk Core_2 (build/Rosetta.rbxm): GENERATED by tools/bundle.py from src/Rosetta - do not edit. --- 2 modules (1 native: @native); the Rosetta root requires it when one of them is first included. --- Error lines map back to the sources through Rosetta.rbxm.linemap.json (tools/bundle.py --where). -return function(__FILES, __include) __FILES["ops/ImageOps"] = function() -- ops/ImageOps: editing on the standard Image: conversion, crop, resize, flips, rotation, compositing, pixel access, @@ -74680,6 +74922,3405 @@ end + + Root + --!optimize 2 +--!nocheck +-- rosetta chunk Root (build/Rosetta.rbxm): GENERATED by tools/bundle.py from src/Rosetta - do not edit. +-- 1 modules (0 native: @native); the Rosetta root requires it when one of them is first included. +-- Error lines map back to the sources through Rosetta.rbxm.linemap.json (tools/bundle.py --where). +return function(__FILES, __include) +__FILES["Sniffs"] = function() + + +-- Sniffs: GENERATED by tools/gen_registry.py from the format folders - do not edit. +-- Each format's sniff (format path -> sniff(r)), copied from its init.luau with the top-level locals and types it +-- reaches (tools/sniff_extract.py), so detection requires no format module. Requires outside core/ are proxies that +-- require on first use. Formats whose sniff needs their module (Registry sniff = 2) are not here. +local S: { [string]: (any) -> number } = {} + +local function lazy(load: () -> any): any + local proxy = {} + return setmetatable(proxy, { + __index = function(_, k: any): any + local m = load() + setmetatable(proxy, { __index = m }) + return m[k] + end, + }) +end + +do -- image/ani +local Bytes = __include("core/Bytes") +S["image/ani"] = function(r: Bytes.Reader): number + return if r:peek(4) == "RIFF" and r:peek(4, 8) == "ACON" then 1 else 0 +end +end + +do -- image/art +local Bytes = __include("core/Bytes") +local readu8, readu16, readu32, readi16 = buffer.readu8, buffer.readu16, buffer.readu32, buffer.readi16 +local function header(b: buffer, o: number, limit: number): (number?, number?, number?, number?, boolean?) + local p = o + local prefixed = false + if limit - p >= 8 and buffer.readstring(b, p, 8) == "BUILDART" then + p += 8 + prefixed = true + end + if limit - p < 16 or readu32(b, p) ~= 1 then + return nil, nil, nil, nil, nil + end + local first, last = readu32(b, p + 8), readu32(b, p + 12) + if last < first or last - first >= 65536 then + return nil, nil, nil, nil, nil + end + return p + 16, first, last, readu32(b, p + 4), prefixed +end +S["image/art"] = function(r: Bytes.Reader): number + local at, first, last = header(r.buf, r.base, r.limit) + if not at or not first or not last then + return 0 + end + local n = last - first + 1 + local p = at :: number + if r.limit - p < n * 8 then + return 0 + end + local total = 0 + for i = 0, n - 1 do + local w, h = readi16(r.buf, p + i * 2), readi16(r.buf, p + n * 2 + i * 2) + if w < 0 or h < 0 then + return 0 + end + total += w * h + end + local size = p + n * 8 + total - r.base + local have = r.limit - r.base + return if size == have then 0.9 elseif size < have and have - size < 4096 then 0.5 else 0 +end +end + +do -- image/blp +local Bytes = __include("core/Bytes") +S["image/blp"] = function(r: Bytes.Reader): number + local m = r:peek(4) + return if m == "BLP1" or m == "BLP2" then 1 elseif m == "BLP0" then 0.8 else 0 +end +end + +do -- image/bmp +local Bytes = __include("core/Bytes") +S["image/bmp"] = function(r: Bytes.Reader): number + if r:peek(2) ~= "BM" then + return 0 + end + local n = r:peekU8(14) + math.max(r:peekU8(15), 0) * 256 + if r:peekU8(16) == 0 and r:peekU8(17) == 0 and (n == 12 or n == 16 or n == 40 or n == 52 or n == 56 or n == 64 or n == 108 or n == 124) then + return 0.9 + end + return 0.2 +end +end + +do -- image/dds +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +local MAGIC = "DDS " +S["image/dds"] = function(r: Bytes.Reader): number + return math.max(Sniff.magic(r, MAGIC .. "\124\0\0\0"), Sniff.magic(r, MAGIC, 0, 0.6)) +end +end + +do -- image/exr +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +local MAGIC = "\118\47\49\1" +S["image/exr"] = function(r: Bytes.Reader): number + return Sniff.magic(r, MAGIC) +end +end + +do -- image/gif +local Bytes = __include("core/Bytes") +S["image/gif"] = function(r: Bytes.Reader): number + local s = r:peek(6) + return if s == "GIF89a" or s == "GIF87a" then 1 else 0 +end +end + +do -- image/hdr +local Bytes = __include("core/Bytes") +S["image/hdr"] = function(r: Bytes.Reader): number + local s = r:peek(10) + if s == "#?RADIANCE" then + return 1 + end + if string.sub(s, 1, 6) == "#?RGBE" then + return 1 + end + if string.sub(s, 1, 2) == "#?" and string.match(s, "^#%?%u") then + return 0.5 + end + return 0 +end +end + +do -- image/icns +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["image/icns"] = function(r: Bytes.Reader): number + return Sniff.magic(r, "icns") +end +end + +do -- image/ico +local Bytes = __include("core/Bytes") +local readu8 = buffer.readu8 +S["image/ico"] = function(r: Bytes.Reader): number + if r:remaining() < 22 then + return 0 + end + local b, o = r.buf, r.pos + local typ = buffer.readu16(b, o + 2) + local count = buffer.readu16(b, o + 4) + if buffer.readu16(b, o) ~= 0 or (typ ~= 1 and typ ~= 2) or count == 0 then + return 0 + end + -- the first entry: reserved byte 0, a size and offset inside the file + local size, off = buffer.readu32(b, o + 14), buffer.readu32(b, o + 18) + if readu8(b, o + 9) ~= 0 or size == 0 or off < 6 + count * 16 then + return 0 + end + return 0.8 +end +end + +do -- image/ilbm +local Bytes = __include("core/Bytes") +S["image/ilbm"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "FORM" then + return 0 + end + local t = r:peek(4, 8) + return if t == "ILBM" or t == "PBM " then 1 else 0 +end +end + +do -- image/jpeg +local Bytes = __include("core/Bytes") +S["image/jpeg"] = function(r: Bytes.Reader): number + local s = r:peek(3) + return if s == "\255\216\255" then 1 else 0 +end +end + +do -- image/ktx +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +local ID1 = "\171KTX 11\187\r\n\26\n" +local ID2 = "\171KTX 20\187\r\n\26\n" +S["image/ktx"] = function(r: Bytes.Reader): number + return math.max(Sniff.magic(r, ID2), Sniff.magic(r, ID1)) +end +end + +do -- image/lmp +local Bytes = __include("core/Bytes") +local function kindOf(r: Bytes.Reader): string? + local n = r:remaining() + if n == 768 then + return "palette" + elseif n == 16385 or n == 16384 then + return "colormap" + end + if n < 9 then + return nil + end + local w, h = buffer.readu32(r.buf, r.pos), buffer.readu32(r.buf, r.pos + 4) + if w > 0 and h > 0 and w <= 4096 and h <= 4096 and 8 + w * h == n then + return "qpic" + end + return nil +end +S["image/lmp"] = function(r: Bytes.Reader): number + local k = kindOf(r) + return if k == "qpic" then 0.3 elseif k then 0.05 else 0 +end +end + +do -- image/pcx +local Bytes = __include("core/Bytes") +S["image/pcx"] = function(r: Bytes.Reader): number + if r:size() < 128 then + return 0 + end + local m, v, e, bpp = r:peekU8(0), r:peekU8(1), r:peekU8(2), r:peekU8(3) + if m ~= 10 or (v ~= 0 and v ~= 2 and v ~= 3 and v ~= 4 and v ~= 5) or e > 1 then + return 0 + end + return if bpp == 1 or bpp == 2 or bpp == 4 or bpp == 8 then 0.8 else 0 +end +end + +do -- image/png +local Bytes = __include("core/Bytes") +local SIGNATURE = "\137PNG\r\n\26\n" +S["image/png"] = function(r: Bytes.Reader): number + return if r:peek(8) == SIGNATURE then 1 else 0 +end +end + +do -- image/pnm +local Bytes = __include("core/Bytes") +S["image/pnm"] = function(r: Bytes.Reader): number + if r:remaining() < 3 then + return 0 + end + local a, b, c = r:peekU8(0), r:peekU8(1), r:peekU8(2) + if a ~= 80 then -- 'P' + return 0 + end + local ws = c == 32 or (c >= 9 and c <= 13) + if b >= 49 and b <= 55 and ws then -- P1..P7 + return 0.9 + end + if (b == 70 or b == 102) and ws then -- PF / Pf + return 0.9 + end + return 0 +end +end + +do -- image/qoi +local Bytes = __include("core/Bytes") +S["image/qoi"] = function(r: Bytes.Reader): number + return if r:peek(4) == "qoif" then 1 else 0 +end +end + +do -- image/sgi +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["image/sgi"] = function(r: Bytes.Reader): number + if Sniff.magic(r, "\1\218") == 0 or r:size() < 512 then + return 0 + end + local st, bpc = r:peekU8(2), r:peekU8(3) + return if st <= 1 and (bpc == 1 or bpc == 2) then 1 else 0 +end +end + +do -- image/spr +local Bytes = __include("core/Bytes") +S["image/spr"] = function(r: Bytes.Reader): number + if r:remaining() < 36 or r:peek(4) ~= "IDSP" then + return 0 + end + local v = buffer.readi32(r.buf, r.pos + 4) + return if v == 1 or v == 2 or v == 32 then 1 else 0.3 +end +end + +do -- image/sunras +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +local MAGIC = "\89\166\106\149" +S["image/sunras"] = function(r: Bytes.Reader): number + return Sniff.magic(r, MAGIC) +end +end + +do -- image/tga +local Bytes = __include("core/Bytes") +local TYPES = { [1] = true, [2] = true, [3] = true, [9] = true, [10] = true, [11] = true } +local FOOTER = "TRUEVISION-XFILE.\0" +local readu8 = buffer.readu8 +type Header = { + idLen: number, + cmapType: number, + imageType: number, + cmapFirst: number, + cmapLen: number, + cmapBits: number, + width: number, + height: number, + depth: number, + desc: number, +} +local function header(r: Bytes.Reader): Header? + if r.limit - r.base < 18 then + return nil + end + local b, o = r.buf, r.base + local function u16(q: number): number + return readu8(b, o + q) + readu8(b, o + q + 1) * 256 + end + local h: Header = { + idLen = readu8(b, o), + cmapType = readu8(b, o + 1), + imageType = readu8(b, o + 2), + cmapFirst = u16(3), + cmapLen = u16(5), + cmapBits = readu8(b, o + 7), + width = u16(12), + height = u16(14), + depth = readu8(b, o + 16), + desc = readu8(b, o + 17), + } + return h +end +local function implausible(h: Header): string? + local t = h.imageType + if not TYPES[t] then + return "image type " .. t + end + if h.cmapType > 1 then + return "colour map type " .. h.cmapType + end + local mapped = t == 1 or t == 9 + if mapped and (h.cmapType ~= 1 or (h.depth ~= 8 and h.depth ~= 16)) then + return "colour-mapped image without a colour map" + end + if h.cmapType == 1 and h.cmapLen > 0 and h.cmapBits ~= 15 and h.cmapBits ~= 16 and h.cmapBits ~= 24 and h.cmapBits ~= 32 then + return "colour map entry size " .. h.cmapBits + end + if (t == 2 or t == 10) and h.depth ~= 15 and h.depth ~= 16 and h.depth ~= 24 and h.depth ~= 32 then + return "pixel depth " .. h.depth + end + if (t == 3 or t == 11) and h.depth ~= 8 and h.depth ~= 16 then + return "grey pixel depth " .. h.depth + end + if h.width == 0 or h.height == 0 then + return "zero size" + end + if h.desc >= 64 then + return "interleaving / reserved descriptor bits" + end + return nil +end +S["image/tga"] = function(r: Bytes.Reader): number + local h = header(r) + if not h or implausible(h) then + return 0 + end + local n = r.limit - r.base + if n >= 44 and buffer.readstring(r.buf, r.limit - 18, 18) == FOOTER then + return 0.9 + end + return 0.2 +end +end + +do -- image/tiff +local Bytes = __include("core/Bytes") +S["image/tiff"] = function(r: Bytes.Reader): number + local s = r:peek(4) + if s == "II*\0" or s == "MM\0*" or s == "II+\0" or s == "MM\0+" then + return 1 + end + return 0 +end +end + +do -- image/tim +local Bytes = __include("core/Bytes") +S["image/tim"] = function(r: Bytes.Reader): number + if r:remaining() < 20 or r:peek(4) ~= "\16\0\0\0" then + return 0 + end + local flags = r:peekU8(4) + if flags > 0x0F or (flags % 8) > 3 or r:peek(3, 5) ~= "\0\0\0" then + return 0 + end + return 0.8 +end +end + +do -- image/vtf +local Bytes = __include("core/Bytes") +S["image/vtf"] = function(r: Bytes.Reader): number + return if r:peek(4) == "VTF\0" and r:peekU8(4) == 7 then 1 else 0 +end +end + +do -- image/webp +local Bytes = __include("core/Bytes") +S["image/webp"] = function(r: Bytes.Reader): number + if r:peek(4) == "RIFF" and r:peek(4, 8) == "WEBP" then + return 1 + end + return 0 +end +end + +do -- image/xbm +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["image/xbm"] = function(r: Bytes.Reader): number + local s = Sniff.text(r, 256, true) + if string.match(s, "^#define%s+[%w_]*_?width%s+%d+") or string.match(s, "^/%*.-%*/%s*#define%s+[%w_]*width%s+%d+") then + return 0.9 + end + return 0 +end +end + +do -- image/xpm +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["image/xpm"] = function(r: Bytes.Reader): number + local s = Sniff.text(r, 64, true) + if string.sub(s, 1, 9) == "/* XPM */" or string.sub(s, 1, 6) == "! XPM2" then + return 1 + end + return 0 +end +end + +do -- audio/aac +local Bytes = __include("core/Bytes") +local Aac = lazy(function() + return __include("codecs/audio/Aac") +end) +local readu8 = buffer.readu8 +local function id3Size(b: buffer, p: number, limit: number): number + if p + 10 > limit or buffer.readstring(b, p, 3) ~= "ID3" then + return 0 + end + local s = 0 + for i = 6, 9 do + s = s * 128 + bit32.band(readu8(b, p + i), 127) + end + local footer = if bit32.band(readu8(b, p + 5), 0x10) ~= 0 then 10 else 0 + return 10 + s + footer +end +S["audio/aac"] = function(r: Bytes.Reader): number + local b, p, limit = r.buf, r.pos, r.limit + p += id3Size(b, p, limit) + local h = Aac.adts(b, p, limit) + if not h then + return 0 + end + local h2 = Aac.adts(b, p + h.frameSize, limit) + if h2 and h2.sfIndex == h.sfIndex and h2.channelConfig == h.channelConfig then + return 0.9 + end + return if p + h.frameSize >= limit then 0.7 else 0.4 +end +end + +do -- audio/ac3 +local Bytes = __include("core/Bytes") +local Ac3 = lazy(function() + return __include("codecs/audio/Ac3") +end) +S["audio/ac3"] = function(r: Bytes.Reader): number + local b, p, limit = r.buf, r.pos, r.limit + local h = Ac3.header(b, p, limit) + if not h then + return 0 + end + local h2 = Ac3.header(b, p + h.frameSize, limit) + if h2 and h2.sampleRate == h.sampleRate then + return 0.9 + end + return if p + h.frameSize >= limit then 0.6 else 0.3 +end +end + +do -- audio/adpcm +local Bytes = __include("core/Bytes") +S["audio/adpcm"] = function(_r: Bytes.Reader): number + return 0 +end +end + +do -- audio/adx +local Bytes = __include("core/Bytes") +S["audio/adx"] = function(r: Bytes.Reader): number + if r:peekU8(0) ~= 0x80 or r:peekU8(1) ~= 0 then + return 0 + end + local off = r:peekU8(2) * 256 + r:peekU8(3) + return if r:peek(6, off - 2) == "(c)CRI" then 1 else 0 +end +end + +do -- audio/aiff +local Bytes = __include("core/Bytes") +S["audio/aiff"] = function(r: Bytes.Reader): number + if r:remaining() < 12 or r:peek(4) ~= "FORM" then + return 0 + end + local form = buffer.readstring(r.buf, r.pos + 8, 4) + return if form == "AIFF" or form == "AIFC" then 1 else 0 +end +end + +do -- audio/ape +local Bytes = __include("core/Bytes") +S["audio/ape"] = function(r: Bytes.Reader): number + local head = r:peek(4) + if head == "MAC " or head == "MACF" then -- MACF: float samples + return 1 + end + if string.sub(head, 1, 3) == "ID3" then + local sz = 0 + for i = 6, 9 do + local v = r:peekU8(i) + if v < 0 then + return 0 + end + sz = sz * 128 + bit32.band(v, 127) + end + local footer = bit32.band(math.max(r:peekU8(5), 0), 0x10) ~= 0 + local id = r:peek(4, 10 + sz + (if footer then 10 else 0)) + return if id == "MAC " or id == "MACF" then 1 else 0 + end + return 0 +end +end + +do -- audio/au +local Bytes = __include("core/Bytes") +S["audio/au"] = function(r: Bytes.Reader): number + return if r:peek(4) == ".snd" then 1 else 0 +end +end + +do -- audio/brstm +local Bytes = __include("core/Bytes") +S["audio/brstm"] = function(r: Bytes.Reader): number + local m = r:peek(4) + if m ~= "RSTM" and m ~= "CSTM" and m ~= "FSTM" then + return 0 + end + local bom = r:peek(2, 4) + return if bom == "\254\255" or bom == "\255\254" then 1 else 0 +end +end + +do -- audio/caf +local Bytes = __include("core/Bytes") +S["audio/caf"] = function(r: Bytes.Reader): number + local h = r:peek(8) + if #h == 8 and string.sub(h, 1, 4) == "caff" and string.byte(h, 5) == 0 and string.byte(h, 6) == 1 then + return 1 + end + return 0 +end +end + +do -- audio/flac +local Bytes = __include("core/Bytes") +S["audio/flac"] = function(r: Bytes.Reader): number + local head = r:peek(4) + if head == "fLaC" then + return 1 + end + if head == "OggS" then + -- the first page's packet: 0x7F "FLAC" (the Ogg FLAC mapping) + local nseg = r:peekU8(26) + if nseg > 0 and r:peek(5, 27 + nseg) == "\127FLAC" then + return 1 + end + return 0 + end + if string.sub(head, 1, 3) == "ID3" then + -- an ID3v2 tag, then fLaC (mp3 files start with ID3 too) + local sz = 0 + for i = 6, 9 do + local v = r:peekU8(i) + if v < 0 then + return 0 + end + sz = sz * 128 + bit32.band(v, 127) + end + local footer = bit32.band(math.max(r:peekU8(5), 0), 0x10) ~= 0 + return if r:peek(4, 10 + sz + (if footer then 10 else 0)) == "fLaC" then 1 else 0 + end + return 0 +end +end + +do -- audio/m4a +local Bytes = __include("core/Bytes") +local IsoBmff = lazy(function() + return __include("containers/IsoBmff") +end) +local AUDIO_BRANDS: { [string]: number } = { ["M4A "] = 1, ["M4B "] = 1, ["M4P "] = 1, ["M4V "] = 0.3 } +S["audio/m4a"] = function(r: Bytes.Reader): number + local brand = IsoBmff.sniff(r) + if brand == nil then + return 0 + end + if AUDIO_BRANDS[brand] then + return AUDIO_BRANDS[brand] + end + if brand == "avif" or brand == "avis" or brand == "heic" or brand == "heix" or brand == "mif1" or brand == "msf1" or brand == "crx " then + return 0 + end + return 0.4 -- an MP4 / MOV that may hold audio; a video format claims it more strongly +end +end + +do -- audio/mp3 +local Bytes = __include("core/Bytes") +local Header = lazy(function() + return __include("codecs/audio/Mpa/Header") +end) +local Tags = lazy(function() + return __include("audio/mp3/Tags") +end) +S["audio/mp3"] = function(r: Bytes.Reader): number + local b, p, lim = r.buf, r.pos, r.limit + local id3 = false + for _ = 1, 4 do -- (ffmpeg writes a tag even when the input had one: tags can follow each other) + local n = if p + 3 <= lim and buffer.readstring(b, p, 3) == "ID3" then Tags.id3v2Size(b, p, lim) else 0 + if n <= 0 then + break + end + id3 = true + p += n + end + if p + 4 > lim or not Header.valid(b, p) then + return if id3 then 0.5 else 0 + end + local fb = Header.frameBytes(b, p, 0) + if fb > 0 then + fb += Header.padding(b, p) + if p + fb + 4 <= lim and Header.compare(b, p, p + fb) then + return 0.9 + end + if p + fb == lim then + return 0.6 + end + end + return if id3 then 0.7 else 0.25 +end +end + +do -- audio/mpc +local Bytes = __include("core/Bytes") +local Musepack = lazy(function() + return __include("codecs/audio/Musepack") +end) +local function id3v2(b: buffer, p: number, limit: number): number + if p + 10 > limit or buffer.readstring(b, p, 3) ~= "ID3" then + return 0 + end + local n = 10 + for i = 6, 9 do + n += bit32.band(buffer.readu8(b, p + i), 127) * 128 ^ (9 - i) + end + return n + (if bit32.band(buffer.readu8(b, p + 5), 0x10) ~= 0 then 10 else 0) +end +S["audio/mpc"] = function(r: Bytes.Reader): number + local b, p, limit = r.buf, r.pos, r.limit + p += id3v2(b, p, limit) + local v = Musepack.magic(b, p, limit) + if v == 8 then + return 1 + end + return if v == 7 then 0.9 else 0 +end +end + +do -- audio/opus +local Bytes = __include("core/Bytes") +S["audio/opus"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "OggS" then + return 0 + end + local nseg = r:peekU8(26) + if nseg < 1 then + return 0 + end + return if r:peek(8, 27 + nseg) == "OpusHead" then 1 else 0 +end +end + +do -- audio/qoa +local Bytes = __include("core/Bytes") +S["audio/qoa"] = function(r: Bytes.Reader): number + return if r:peek(4) == "qoaf" then 1 else 0 +end +end + +do -- audio/tta +local Bytes = __include("core/Bytes") +local function id3Size(r: Bytes.Reader): number + if r:peek(3) ~= "ID3" then + return 0 + end + local sz = 0 + for i = 6, 9 do + local v = r:peekU8(i) + if v < 0 then + return 0 + end + sz = sz * 128 + bit32.band(v, 127) + end + local footer = bit32.band(math.max(r:peekU8(5), 0), 0x10) ~= 0 + return 10 + sz + (if footer then 10 else 0) +end +S["audio/tta"] = function(r: Bytes.Reader): number + return if r:peek(4, id3Size(r)) == "TTA1" then 1 else 0 +end +end + +do -- audio/vag +local Bytes = __include("core/Bytes") +S["audio/vag"] = function(r: Bytes.Reader): number + local m = r:peek(4) + return if m == "VAGp" or m == "VAGi" or m == "KVAG" then 1 else 0 +end +end + +do -- audio/voc +local Bytes = __include("core/Bytes") +local MAGIC = "Creative Voice File\26" +S["audio/voc"] = function(r: Bytes.Reader): number + return if r:peek(20) == MAGIC then 1 else 0 +end +end + +do -- audio/vorbis +local Bytes = __include("core/Bytes") +S["audio/vorbis"] = function(r: Bytes.Reader): number + if r:remaining() < 35 or r:peek(4) ~= "OggS" then + return 0 + end + local b, p = r.buf, r.pos + local nseg = buffer.readu8(b, p + 26) + local d = p + 27 + nseg + if d + 7 > r.limit then + return 0 + end + return if buffer.readu8(b, d) == 1 and buffer.readstring(b, d + 1, 6) == "vorbis" then 1 else 0 +end +end + +do -- audio/wav +local Bytes = __include("core/Bytes") +local Riff = lazy(function() + return __include("containers/Riff") +end) +S["audio/wav"] = function(r: Bytes.Reader): number + return if Riff.sniff(r) == "WAVE" then 1 else 0 +end +end + +do -- audio/wavpack +local Bytes = __include("core/Bytes") +S["audio/wavpack"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "wvpk" then + return 0 + end + local v = r:peekU8(9) + return if v == 4 then 1 else 0.5 +end +end + +do -- video/avi +local Bytes = __include("core/Bytes") +S["video/avi"] = function(r: Bytes.Reader): number + if r:peek(4) == "RIFF" and r:peek(4, 8) == "AVI " then + return 1 + end + return 0 +end +end + +do -- video/fli +local Bytes = __include("core/Bytes") +local FLI, FLC, DTA = 0xAF11, 0xAF12, 0xAF44 +S["video/fli"] = function(r: Bytes.Reader): number + local s = r:peek(18) + if #s < 18 then + return 0 + end + local magic = string.byte(s, 5) + string.byte(s, 6) * 256 + if magic ~= FLI and magic ~= FLC and magic ~= DTA then + return 0 + end + local w = string.byte(s, 9) + string.byte(s, 10) * 256 + local h = string.byte(s, 11) + string.byte(s, 12) * 256 + if w > 4096 or h > 4096 then + return 0 + end + return 0.9 +end +end + +do -- video/flv +local Bytes = __include("core/Bytes") +S["video/flv"] = function(r: Bytes.Reader): number + if r:remaining() >= 9 and r:peek(3) == "FLV" then + return if r:peekU8(3) == 1 then 1 else 0.6 + end + return 0 +end +end + +do -- video/h264 +local Bytes = __include("core/Bytes") +S["video/h264"] = function(r: Bytes.Reader): number + local s = r:peek(5) + if not s or #s < 4 then + return 0 + end + local hdr + if string.byte(s, 1) == 0 and string.byte(s, 2) == 0 and string.byte(s, 3) == 1 then + hdr = string.byte(s, 4) + elseif #s >= 5 and string.byte(s, 1) == 0 and string.byte(s, 2) == 0 and string.byte(s, 3) == 0 and string.byte(s, 4) == 1 then + hdr = string.byte(s, 5) + else + return 0 + end + if hdr >= 128 then + return 0 + end + local t = hdr % 32 + if t == 7 then + return 0.8 + elseif t == 9 or t == 6 or t == 8 then + return 0.5 + elseif t == 5 then + return 0.4 + end + return 0 +end +end + +do -- video/mkv +local Bytes = __include("core/Bytes") +S["video/mkv"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "\26\69\223\163" then + return 0 + end + local head = r:peek(math.min(64, r:remaining())) + if string.find(head, "webm", 1, true) or string.find(head, "matroska", 1, true) then + return 1 + end + return 0.5 +end +end + +do -- video/mp4 +local Bytes = __include("core/Bytes") +local IsoBmff = lazy(function() + return __include("containers/IsoBmff") +end) +local IMAGE_BRANDS = { avif = true, avis = true, heic = true, heix = true, mif1 = true, msf1 = true, ["crx "] = true } +local AUDIO_BRANDS = { ["M4A "] = true, ["M4B "] = true, ["M4P "] = true } +S["video/mp4"] = function(r: Bytes.Reader): number + local brand = IsoBmff.sniff(r) + if brand == nil or IMAGE_BRANDS[brand] then + return 0 + end + if AUDIO_BRANDS[brand] then + return 0.2 + end + if brand == "M4V " then + return 0.9 + end + return if brand == "" then 0.6 else 0.8 +end +end + +do -- video/mpegps +local Bytes = __include("core/Bytes") +S["video/mpegps"] = function(r: Bytes.Reader): number + if r:peek(4) == "\0\0\1\186" then + return 0.9 + end + if r:peek(4) == "\0\0\1\179" then + return 0.5 -- an MPEG-1 / 2 video elementary stream (sequence header) + end + return 0 +end +end + +do -- video/mpegts +local Bytes = __include("core/Bytes") +local SIZES = { 188, 192 } +local function packetSize(r: Bytes.Reader): (number, number) + local n = r:remaining() + local head = r:peek(2048 + 2 * 192) + local lim = math.min(n, 2048) + local start = 0 + while start < lim do + local f = string.find(head, "G", start + 1, true) -- 0x47 + if not f or f > lim then + break + end + start = f - 1 + for _, size in SIZES do + local hits, need = 0, math.min(3, (n - start - 1) // size + 1) + for k = 0, 2 do + local at = start + k * size + if at < n and string.byte(head, at + 1) == 0x47 then + hits += 1 + end + end + if hits >= need and (need >= 2 or start == 0) then + if size == 192 and start >= 4 then + return 192, start - 4 + elseif size == 188 then + return 188, start + end + end + end + start += 1 + end + return 0, 0 +end +S["video/mpegts"] = function(r: Bytes.Reader): number + local s, off = packetSize(r) + if s == 0 then + return 0 + end + if off > 0 then + return 0.6 + end + return if r:remaining() >= 3 * s then 0.9 else 0.5 +end +end + +do -- video/ogv +local Bytes = __include("core/Bytes") +S["video/ogv"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "OggS" then + return 0 + end + local b, p, lim = r.buf, r.pos, r.limit + for _ = 1, 8 do + if p + 27 > lim or buffer.readstring(b, p, 4) ~= "OggS" or buffer.readu8(b, p + 5) % 4 < 2 then + return 0 + end + local nseg = buffer.readu8(b, p + 26) + local d = p + 27 + nseg + if d + 7 <= lim and buffer.readu8(b, d) == 0x80 and buffer.readstring(b, d + 1, 6) == "theora" then + return 1 + end + if d > lim then + return 0 + end + local size = 0 + for i = 0, nseg - 1 do + size += buffer.readu8(b, p + 27 + i) + end + p = d + size + end + return 0 +end +end + +do -- video/smk +local Bytes = __include("core/Bytes") +S["video/smk"] = function(r: Bytes.Reader): number + local s = r:peek(4) + if s ~= "SMK2" and s ~= "SMK4" then + return 0 + end + return 1 +end +end + +do -- video/y4m +local Bytes = __include("core/Bytes") +local MAGIC = "YUV4MPEG2 " +S["video/y4m"] = function(r: Bytes.Reader): number + return if r:peek(10) == MAGIC then 1 else 0 +end +end + +do -- model/3ds +local Bytes = __include("core/Bytes") +S["model/3ds"] = function(r: Bytes.Reader): number + local h = r:peek(8) + if #h < 8 or string.byte(h, 1) ~= 0x4D or string.byte(h, 2) ~= 0x4D then + return 0 + end + local b1, b2, b3, b4, c1, c2 = string.byte(h, 3, 8) + local size = b1 + b2 * 256 + b3 * 65536 + b4 * 16777216 + local child = c1 + c2 * 256 + if size < 16 or not (child == 0x0002 or child == 0x3D3D or child == 0xB000) then + return 0 + end + return if size == r.limit - r.pos then 0.95 else 0.7 +end +end + +do -- model/3mf +local Bytes = __include("core/Bytes") +S["model/3mf"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "PK\3\4" then + return 0 + end + local n = r:size() + local tail = buffer.readstring(r.buf, r.base + math.max(0, n - 65536), math.min(n, 65536)) + if string.find(tail, "3D/[^/]*%.model") or string.find(tail, "3dmodel.model", 1, true) then + return 0.95 + end + local head = r:peek(256) + if string.find(head, "3D/", 1, true) then + return 0.7 + end + return 0 +end +end + +do -- model/ase +local Bytes = __include("core/Bytes") +local Text = lazy(function() + return __include("codecs/text/Text") +end) +local MAGIC = "*3DSMAX_ASCIIEXPORT" +local function utf16(r: Bytes.Reader): (boolean?, boolean) + local h = r:peek(2) + if h == "\255\254" then + return true, false + elseif h == "\254\255" then + return true, true + elseif #h == 2 and string.byte(h, 2) == 0 and string.byte(h, 1) == 42 then + return true, false + elseif #h == 2 and string.byte(h, 1) == 0 and string.byte(h, 2) == 42 then + return true, true + end + return nil, false +end +local function text(r: Bytes.Reader, n: number?): string + local wide, be = utf16(r) + local len = r.limit - r.pos + if n then + len = math.min(len, n) + end + if wide then + local skip = if r:peek(2) == "\255\254" or r:peek(2) == "\254\255" then 2 else 0 + return Text.utf16(r.buf, r.pos + skip, len - skip, be) + end + return Text.toUtf8(buffer.readstring(r.buf, r.pos, len)) +end +S["model/ase"] = function(r: Bytes.Reader): number + local h = string.match(text(r, 256), "^%s*(%*[%w_]+)") + if h == MAGIC then + return 1 + end + return 0 +end +end + +do -- model/b3d +local Bytes = __include("core/Bytes") +S["model/b3d"] = function(r: Bytes.Reader): number + if r:peek(4) == "BB3D" then + return if r:peek(4, 8) ~= "" then 1 else 0.8 + end + return 0 +end +end + +do -- model/blend +local Bytes = __include("core/Bytes") +local Deflate = lazy(function() + return __include("codecs/compress/Deflate") +end) +local Zstd = lazy(function() + return __include("codecs/compress/Zstd") +end) +S["model/blend"] = function(r: Bytes.Reader): number + local head = r:peek(7) + if head == "BLENDER" then + return 1 + end + local n = r.limit - r.base + if string.sub(head, 1, 3) == "\31\139\8" then + local inner = Deflate.peek(r.buf, r.base, n, 7) + return if inner and buffer.tostring(inner) == "BLENDER" then 1 else 0 + end + if string.sub(head, 1, 4) == Zstd.MAGIC then + if n > 4 * 2 ^ 20 then + return 0.5 + end + local out = Zstd.decompress(r.buf, r.base, n, { verify = false }) + return if out and buffer.len(out) >= 7 and buffer.readstring(out, 0, 7) == "BLENDER" then 1 else 0 + end + return 0 +end +end + +do -- model/bsp +local Bytes = __include("core/Bytes") +S["model/bsp"] = function(r: Bytes.Reader): number + if r:remaining() < 64 then + return 0 + end + local m = r:peek(4) + local v = buffer.readi32(r.buf, r.pos + (if m == "IBSP" then 4 else 0)) + if m == "BSP2" or m == "2PSB" then + v = 29 + end + if m == "IBSP" then + return if v == 38 or v == 46 or v == 47 then 1 else 0.3 + end + if v == 29 or v == 30 then + local size = r:remaining() + for i = 0, 14 do + local o, n = buffer.readi32(r.buf, r.pos + 4 + i * 8), buffer.readi32(r.buf, r.pos + 8 + i * 8) + if o < 0 or n < 0 or o + n > size then + return 0 + end + end + return 0.6 + end + return 0 +end +end + +do -- model/buildmap +local Bytes = __include("core/Bytes") +local SECTOR_SIZE, WALL_SIZE, SPRITE_SIZE = 40, 32, 44 +local HEADER = 22 -- version, posx, posy, posz, ang, cursectnum, then u16 numsectors at 20 +local readu16 = buffer.readu16 +local function layout(b: buffer, o: number, limit: number): (number?, number?, number?, number?) + if limit - o < HEADER then + return nil, nil, nil, nil + end + local ns = readu16(b, o + 20) + local p = o + HEADER + ns * SECTOR_SIZE + if p + 2 > limit then + return nil, nil, nil, nil + end + local nw = readu16(b, p) + p += 2 + nw * WALL_SIZE + if p + 2 > limit then + return nil, nil, nil, nil + end + local nsp = readu16(b, p) + p += 2 + nsp * SPRITE_SIZE + return ns, nw, nsp, p +end +S["model/buildmap"] = function(r: Bytes.Reader): number + local b, o, limit = r.buf, r.base, r.limit + if limit - o < HEADER then + return 0 + end + local v = buffer.readu32(b, o) + if v ~= 7 and v ~= 8 and v ~= 9 then + return 0 + end + local ns, _, _, stop = layout(b, o, limit) + if not ns or not stop or stop > limit then + return 0 + end + return if stop == limit then 0.9 else 0.5 +end +end + +do -- model/d3map +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/d3map"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 512, true) + for _ = 1, 16 do + local rest = string.match(head, "^//[^\n]*\n%s*(.*)$") + if not rest then + break + end + head = rest + end + return if string.match(head, "^Version%s+[123]%s") then 1 else 0 +end +end + +do -- model/dae +local Bytes = __include("core/Bytes") +S["model/dae"] = function(r: Bytes.Reader): number + local head = r:peek(2048) + if string.sub(head, 1, 4) == "PK\3\4" then + local nlen = string.byte(head, 27) or 0 + local name = string.lower(string.sub(head, 31, 30 + nlen)) + if string.find(name, "%.dae$") or name == "manifest.xml" then + return 0.95 + end + return 0 + end + -- UTF-16 files: drop the zero bytes + if string.find(string.sub(head, 1, 4), "\0", 1, true) then + head = string.gsub(head, "%z", "") + end + if string.find(head, "<COLLADA", 1, true) then + return 1 + end + return 0 +end +end + +do -- model/gltf +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["model/gltf"] = function(r: Bytes.Reader): number + if r:peek(4) == "glTF" then + return 1 + end + local head = r:peek(1024) + local s = Sniff.dropBom(head) + if string.find(s, "^%s*{") and string.find(s, "\"asset\"", 1, true) then + return 0.9 + end + if string.find(s, "^%s*{") and (string.find(s, "\"accessors\"", 1, true) or string.find(s, "\"bufferViews\"", 1, true)) then + return 0.6 + end + return 0 +end +end + +do -- model/godot +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/godot"] = function(r: Bytes.Reader): number + local h = Sniff.text(r, 256) + if string.match(h, "^%s*%[gd_scene[%s%]]") then + return 1 + end + return 0 +end +end + +do -- model/iqm +local Bytes = __include("core/Bytes") +local MAGIC = "INTERQUAKEMODEL\0" +S["model/iqm"] = function(r: Bytes.Reader): number + return if r:peek(16) == MAGIC then 1 else 0 +end +end + +do -- model/ldraw +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/ldraw"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 2048, true) + if string.find(head, "^0%s+FILE%s") then + return 0.9 + end + if string.find(head, "\n%s*1%s+%S+" .. string.rep("%s+[-+%deE.]+", 12) .. "%s+[^\n]+%.[dDlL][aAdD][tTrR]%s*\r?\n") then + return 0.8 + end + if string.find(head, "^0[ \t]+%a") and string.find(head, "\n%s*[1-5]%s+%S+%s+[-+%d.]+%s+[-+%d.]+%s+[-+%d.]+%s+[-+%d.]+%s+[-+%d.]+%s+[-+%d.]") then + return 0.4 + end + return 0 +end +end + +do -- model/lwo +local Bytes = __include("core/Bytes") +local VERSIONS = { LWO2 = true, LWOB = true, LXOB = true } +S["model/lwo"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "FORM" then + return 0 + end + local v = r:peek(4, 8) + return if VERSIONS[v] then 1 elseif v == "LWO3" then 0.8 else 0 +end +end + +do -- model/map +local Bytes = __include("core/Bytes") +S["model/map"] = function(r: Bytes.Reader): number + local head = r:peek(math.min(r:remaining(), 4096)) + if #head < 2 or string.find(head, "[%z\1-\8\14-\31]") then + return 0 + end + if string.sub(head, 1, 3) == "\239\187\191" then + head = string.sub(head, 4) + end + local s = head + local game = false + while true do + local c = string.match(s, "^%s*//[^\n]*\n?()") + if not c then + break + end + if string.match(s, "^%s*//%s*Game:") then + game = true + end + s = string.sub(s, c :: number) + end + local body = string.match(s, '^%s*{%s*"[^"\n]*"%s*"') or string.match(s, "^%s*{%s*{%s*[%(bp]") + if not body then + return if game and string.match(s, "^%s*{") then 0.6 else 0 + end + return if game or string.find(head, '"classname"', 1, true) then 0.9 else 0.6 +end +end + +do -- model/mca +local Bytes = __include("core/Bytes") +local COMPRESSION = { [1] = "gzip", [2] = "zlib", [3] = "none", [4] = "lz4", [127] = "custom" } +S["model/mca"] = function(r: Bytes.Reader): number + local n = r.limit - r.base + if n < 8192 then + return 0 + end + local sectors = (n + 4095) // 4096 + local used, b = 0, r.buf + for i = 0, 1023 do + local e = bit32.byteswap(buffer.readu32(b, r.base + i * 4)) + if e ~= 0 then + local off, cnt = e // 256, e % 256 + if off < 2 or cnt == 0 or off + cnt > sectors then + return 0 + end + used += 1 + if used == 1 then + local p = r.base + off * 4096 + if p + 5 > r.limit then + return 0 + end + local c = buffer.readu8(b, p + 4) % 128 + if COMPRESSION[c] == nil then + return 0 + end + end + end + end + return if used > 0 then 0.8 else 0.2 +end +end + +do -- model/md2 +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/md2"] = function(r: Bytes.Reader): number + if r:remaining() < 68 then + return 0 + end + return if Sniff.magic(r, "IDP2") == 1 and r:peekU8(4) == 8 then 1 else 0 +end +end + +do -- model/md3 +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/md3"] = function(r: Bytes.Reader): number + if r:remaining() < 108 then + return 0 + end + return if Sniff.magic(r, "IDP3") == 1 and r:peekU8(4) == 15 then 1 else 0 +end +end + +do -- model/md5 +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/md5"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 512, true) + head = string.gsub(head, "^//[^\n]*\n%s*", "") + return if string.match(head, "^MD5Version%s+%d+") then 1 else 0 +end +end + +do -- model/mdl +local Bytes = __include("core/Bytes") +S["model/mdl"] = function(r: Bytes.Reader): number + local m = r:peek(4) + local v = r:peekU8(4) + if (m == "IDPO" and v == 6) or (m == "IDST" and v == 10) then + return 1 + end + return 0 +end +end + +do -- model/ms3d +local Bytes = __include("core/Bytes") +local Read = lazy(function() + return __include("model/ms3d/Read") +end) +S["model/ms3d"] = function(r: Bytes.Reader): number + local h = r:peek(14) + if string.sub(h, 1, 10) ~= Read.MAGIC then + return 0 + end + local v = string.byte(h, 11) + return if v == 3 or v == 4 then 1 else 0.6 +end +end + +do -- model/obj +local Bytes = __include("core/Bytes") +S["model/obj"] = function(r: Bytes.Reader): number + local head = r:peek(512) + if string.find(head, "\0", 1, true) then + return 0 + end + if string.find(head, "^%s*v%s+[%-%d%.]") or string.find(head, "\n%s*v%s+[%-%d%.]") then + return 0.6 + end + if string.find(head, "^#") and (string.find(head, "\nmtllib ") or string.find(head, "\no ") or string.find(head, "\ng ")) then + return 0.4 + end + return 0 +end +end + +do -- model/off +local Bytes = __include("core/Bytes") +S["model/off"] = function(r: Bytes.Reader): number + local head = r:peek(512) + for _ = 1, 16 do + local rest = string.match(head, "^%s*#[^\n]*\n(.*)$") + if not rest then + break + end + head = rest + end + local kw = string.match(head, "^%s*(%w+)") + if kw and string.match(kw, "^S?T?C?N?4?n?OFF$") then + return 0.9 + end + return 0 +end +end + +do -- model/ply +local Bytes = __include("core/Bytes") +S["model/ply"] = function(r: Bytes.Reader): number + local h = r:peek(4) + return if h == "ply\n" or h == "ply\r" then 1 else 0 +end +end + +do -- model/pmx +local Bytes = __include("core/Bytes") +S["model/pmx"] = function(r: Bytes.Reader): number + local head = r:peek(8) + if string.sub(head, 1, 4) == "PMX " then + return 1 + end + if string.sub(head, 1, 7) == "Pmd\0\0\128\63" then + return 1 + end + return 0 +end +end + +do -- model/proc +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/proc"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 64, true) + if string.match(head, "^mapProcFile%d%d%d") then + return 1 + end + if string.match(head, '^"?PROC"?%s+"?%d') then + return 0.9 + end + return 0 +end +end + +do -- model/qb +local Bytes = __include("core/Bytes") +S["model/qb"] = function(r: Bytes.Reader): number + if r:remaining() < 24 or r:peek(4) ~= "\1\1\0\0" then + return 0 + end + local b, p = r.buf, r.pos + local fmt, z, comp, mask = buffer.readu32(b, p + 4), buffer.readu32(b, p + 8), buffer.readu32(b, p + 12), buffer.readu32(b, p + 16) + if fmt > 1 or z > 1 or comp > 1 or mask > 1 then + return 0 + end + return 0.9 +end +end + +do -- model/rbxm +local Bytes = __include("core/Bytes") +local MAGIC = "<roblox!\137\255\13\10\26\10" +S["model/rbxm"] = function(r: Bytes.Reader): number + return if r:peek(14) == MAGIC then 1 else 0 +end +end + +do -- model/rbxmx +local Bytes = __include("core/Bytes") +local find, format, match, gmatch = string.find, string.format, string.match, string.gmatch +S["model/rbxmx"] = function(r: Bytes.Reader): number + local head = r:peek(256) + head = string.gsub(head, "^\239\187\191", "") + head = string.gsub(head, "^%s*<%?xml[^>]*%?>", "") + if match(head, "^%s*<roblox[%s>]") then + return if find(head, "version=", 1, true) then 1 else 0.8 + end + return 0 +end +end + +do -- model/robloxmesh +local Bytes = __include("core/Bytes") +S["model/robloxmesh"] = function(r: Bytes.Reader): number + return if string.match(r:peek(13), "^version [1-7]%.%d%d[\r\n]") then 1 else 0 +end +end + +do -- model/schematic +local Bytes = __include("core/Bytes") +local Nbt = lazy(function() + return __include("codecs/text/Nbt") +end) +local LITEMATIC_HINTS = { "Regions", "EnclosingSize", "RegionCount", "TotalVolume", "MinecraftDataVersion" } +local SPONGE_HINTS = { "BlockData", "PaletteMax" } -- v1 / v2 fields (some writers leave the root unnamed) +local function hinted(head: string, hints: { string }): boolean + for _, h in hints do + if string.find(head, string.char(0, #h) .. h, 1, true) then + return true + end + end + return false +end +S["model/schematic"] = function(r: Bytes.Reader): number + local p = Nbt.peek(r.buf, r.base, r.limit - r.base) + if not p or p.rootType ~= "compound" or p.endian ~= "big" then + return 0 + end + if p.name == "Schematic" or (p.firstName == "Schematic" and p.firstType == "compound") then + return 1 + end + local head = buffer.tostring(p.head) + return if hinted(head, LITEMATIC_HINTS) or hinted(head, SPONGE_HINTS) then 1 else 0 +end +end + +do -- model/smd +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/smd"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 256, true) + head = string.gsub(head, "^//[^\n]*\n%s*", "") + if string.match(head, "^version%s+1%s") and string.find(head, "nodes", 1, true) then + return 0.9 + end + return 0 +end +end + +do -- model/sourcemdl +local Bytes = __include("core/Bytes") +S["model/sourcemdl"] = function(r: Bytes.Reader): number + if r.limit - r.base < 8 or r:peek(4) ~= "IDST" then + return 0 + end + local v = buffer.readi32(r.buf, r.base + 4) + return if v >= 44 and v <= 49 then 1 else 0 +end +end + +do -- model/stl +local Bytes = __include("core/Bytes") +local function lower5(s: string): boolean + return string.lower(s) == "solid" +end +S["model/stl"] = function(r: Bytes.Reader): number + local size = r:remaining() + if size >= 84 then + local c = r:peek(4, 80) + local n = string.byte(c, 1) + string.byte(c, 2) * 256 + string.byte(c, 3) * 65536 + string.byte(c, 4) * 16777216 + if 84 + 50 * n == size then + return 0.9 + end + end + local head = r:peek(512) + local s = string.match(head, "^%s*(%a+)") + if s and lower5(s) then + local l = string.lower(head) + return if string.find(l, "facet", 1, true) or string.find(l, "endsolid", 1, true) then 0.9 else 0.5 + end + return 0 +end +end + +do -- model/t3d +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/t3d"] = function(r: Bytes.Reader): number + local h = Sniff.text(r, 512) + local first = string.match(h, "^%s*(Begin%s+%a+)") + if first == nil then + return 0 + end + local kind = string.lower(string.match(first, "%a+$") or "") + if kind == "map" or kind == "actor" or kind == "level" or kind == "brush" or kind == "polylist" then + return 0.9 + end + return 0.3 +end +end + +do -- model/udmf +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/udmf"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 1024, true) + for _ = 1, 32 do + local rest = string.match(head, "^//[^\n]*\n%s*(.*)$") or string.match(head, "^/%*.-%*/%s*(.*)$") + if not rest then + break + end + head = rest + end + if string.match(head, "^[Nn][Aa][Mm][Ee][Ss][Pp][Aa][Cc][Ee]%s*=%s*\"") then + return 0.9 + end + return 0 +end +end + +do -- model/usda +local Bytes = __include("core/Bytes") +local function isUsdz(r: Bytes.Reader): boolean + if r:peek(4) ~= "PK\3\4" then + return false + end + local lo, hi = r:peekU8(26), r:peekU8(27) + if lo < 0 or hi < 0 then + return false + end + local nameLen = lo + hi * 256 + local name = string.lower(r:peek(30 + nameLen)) + name = string.sub(name, 31) + return string.find(name, "%.usd[ac]?$") ~= nil +end +S["model/usda"] = function(r: Bytes.Reader): number + local head = r:peek(8) + if string.sub(head, 1, 5) == "#usda" or string.sub(head, 1, 8) == "\239\187\191#usda" then + return 1 + end + if head == "PXR-USDC" then + return 0.9 -- USDC magic, so the error says it is unsupported + end + if isUsdz(r) then + return 0.95 + end + return 0 +end +end + +do -- model/vbsp +local Bytes = __include("core/Bytes") +local HEADER = 8 + 64 * 16 + 4 +S["model/vbsp"] = function(r: Bytes.Reader): number + if r:remaining() < HEADER or r:peek(4) ~= "VBSP" then + return 0 + end + local v = buffer.readi32(r.buf, r.pos + 4) + return if v >= 19 and v <= 21 then 1 else 0.5 +end +end + +do -- model/vmf +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/vmf"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 512, true) + if string.find(head, "%z") then + return 0 + end + if string.match(head, "^versioninfo%s*{") or string.match(head, '^"versioninfo"%s*{') then + return 0.9 + end + if string.match(head, "^world%s*{") or string.match(head, "^visgroups%s*{") then + return 0.6 + end + return 0 +end +end + +do -- model/vox +local Bytes = __include("core/Bytes") +S["model/vox"] = function(r: Bytes.Reader): number + return if r:peek(4) == "VOX " and r:peek(4, 8) == "MAIN" then 1 elseif r:peek(4) == "VOX " then 0.8 else 0 +end +end + +do -- model/vrml +local Bytes = __include("core/Bytes") +S["model/vrml"] = function(r: Bytes.Reader): number + local head = r:peek(16) + if string.sub(head, 1, 3) == "\239\187\191" then + head = string.sub(head, 4) + end + return if string.sub(head, 1, 10) == "#VRML V2.0" then 1 elseif string.sub(head, 1, 6) == "#VRML " then 0.6 else 0 +end +end + +do -- model/x +local Bytes = __include("core/Bytes") +local ENCODINGS = { ["txt "] = "text", ["bin "] = "binary", tzip = "text", bzip = "binary" } +S["model/x"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "xof " then + return 0 + end + return if ENCODINGS[r:peek(4, 8)] then 1 else 0.5 +end +end + +do -- model/x3d +local Bytes = __include("core/Bytes") +S["model/x3d"] = function(r: Bytes.Reader): number + local head = r:peek(1024) + if string.sub(head, 1, 3) == "\239\187\191" then + head = string.sub(head, 4) + end + if string.sub(head, 1, 5) == "#X3D " then + return 1 + end + if string.sub(head, 1, 4) == "\224\0\0\1" and string.find(head, "x3d", 1, true) then + return 0.9 + end + if string.find(head, "<X3D[%s>]") or string.find(head, "<!DOCTYPE X3D", 1, true) then + return 1 + end + return 0 +end +end + +do -- cad/step +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["cad/step"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 256) + head = string.gsub(head, "^%s*/%*.-%*/", "") + if string.find(head, "^%s*ISO%-10303%-21%s*;") then + return 1 + end + return 0 +end +end + +do -- font/bdf +local Bytes = __include("core/Bytes") +S["font/bdf"] = function(r: Bytes.Reader): number + local head = r:peek(32) + return if string.match(head, "^STARTFONT%s+2%.%d") then 1 else 0 +end +end + +do -- font/bmfont +local Bytes = __include("core/Bytes") +S["font/bmfont"] = function(r: Bytes.Reader): number + local head = r:peek(64) + if string.sub(head, 1, 4) == "BMF\3" then + return 1 + end + if string.match(head, "^info%s+face=") or string.match(head, "^info%s+") and string.find(head, "size=", 1, true) then + return 0.9 + end + if string.find(head, "<font>", 1, true) or (string.find(head, "<?xml", 1, true) and string.find(r:peek(512), "<font>", 1, true)) then + return if string.find(r:peek(512), "<info", 1, true) then 0.9 else 0.3 + end + return 0 +end +end + +do -- font/eot +local Bytes = __include("core/Bytes") +local MAGIC = 0x504C +S["font/eot"] = function(r: Bytes.Reader): number + local h = r:peek(36) + if #h < 36 then + return 0 + end + local ver = string.sub(h, 9, 12) + local magic = string.byte(h, 35) + string.byte(h, 36) * 256 + if magic == MAGIC and (ver == "\0\0\1\0" or ver == "\1\0\2\0" or ver == "\2\0\2\0") then + return 1 + end + return 0 +end +end + +do -- font/fon +local Bytes = __include("core/Bytes") +local function isFnt(h: string): boolean + if #h < 4 then + return false + end + local ver = string.byte(h, 1) + string.byte(h, 2) * 256 + return ver == 0x200 or ver == 0x300 +end +S["font/fon"] = function(r: Bytes.Reader): number + local h = r:peek(64) + if string.sub(h, 1, 2) == "MZ" and #h >= 64 then + local lfanew = string.byte(h, 61) + string.byte(h, 62) * 256 + string.byte(h, 63) * 65536 + local sig = r:peek(2, lfanew) + return if sig == "NE" then 0.6 elseif sig == "PE" then 0.2 else 0 + end + if isFnt(h) and #h >= 6 then + local size = string.byte(h, 3) + string.byte(h, 4) * 256 + string.byte(h, 5) * 65536 + string.byte(h, 6) * 16777216 + return if size == r:size() then 0.9 elseif size <= r:size() and size > 118 then 0.3 else 0 + end + return 0 +end +end + +do -- font/hershey +local Bytes = __include("core/Bytes") +local function header(line: string): (number?, number?) + if #line < 10 then + return nil, nil + end + local id = tonumber((string.gsub(string.sub(line, 1, 5), "^%s+", ""))) + local n = tonumber((string.gsub(string.sub(line, 6, 8), "^%s+", ""))) + if not id or not n or n < 1 or string.find(string.sub(line, 1, 8), "[^%d ]") then + return nil, nil + end + return id, n +end +S["font/hershey"] = function(r: Bytes.Reader): number + local head = r:peek(256) + local line = string.match(head, "^([^\r\n]*)") + local id, n = header(line or "") + if not id or not n then + return 0 + end + local body = string.sub(line :: string, 9) + if string.find(body, "[^ -~]") then + return 0 + end + return if #body == math.min(2 * n, 64) or #body == 2 * n then 0.7 else 0.3 +end +end + +do -- font/pcf +local Bytes = __include("core/Bytes") +S["font/pcf"] = function(r: Bytes.Reader): number + return if r:peek(4) == "\1fcp" then 1 else 0 +end +end + +do -- font/psf +local Bytes = __include("core/Bytes") +S["font/psf"] = function(r: Bytes.Reader): number + local h = r:peek(4) + if h == "\114\181\74\134" then + return 1 + end + if string.sub(h, 1, 2) == "\54\4" and #h >= 4 and string.byte(h, 3) <= 7 and string.byte(h, 4) > 0 then + return 0.9 + end + return 0 +end +end + +do -- font/ttf +local Bytes = __include("core/Bytes") +S["font/ttf"] = function(r: Bytes.Reader): number + local m = r:peek(4) + if m == "\0\1\0\0" or m == "OTTO" or m == "ttcf" or m == "true" then + return 0.9 + end + return 0 +end +end + +do -- font/type1 +local Bytes = __include("core/Bytes") +S["font/type1"] = function(r: Bytes.Reader): number + local h = r:peek(64) + if string.sub(h, 1, 2) == "\128\1" then + h = string.sub(h, 7) + end + if string.sub(h, 1, 14) == "%!PS-AdobeFont" or string.sub(h, 1, 10) == "%!FontType" then + return 1 + end + return 0 +end +end + +do -- font/woff +local Bytes = __include("core/Bytes") +S["font/woff"] = function(r: Bytes.Reader): number + return if r:peek(4) == "wOFF" then 1 else 0 +end +end + +do -- font/woff2 +local Bytes = __include("core/Bytes") +S["font/woff2"] = function(r: Bytes.Reader): number + return if r:peek(4) == "wOF2" then 1 else 0 +end +end + +do -- archive/7z +local Bytes = __include("core/Bytes") +local MAGIC = "7z\188\175\39\28" +S["archive/7z"] = function(r: Bytes.Reader): number + return if r:peek(6) == MAGIC then 1 else 0 +end +end + +do -- archive/adf +local Bytes = __include("core/Bytes") +local BS = 512 +S["archive/adf"] = function(r: Bytes.Reader): number + local n = r:size() + if n < 4 * BS or n % BS ~= 0 then + return 0 + end + local h = r:peek(4) + if string.sub(h, 1, 3) ~= "DOS" or string.byte(h, 4) > 5 then + return 0 + end + return if n == 901120 or n == 1802240 then 0.95 else 0.6 +end +end + +do -- archive/applesingle +local Bytes = __include("core/Bytes") +S["archive/applesingle"] = function(r: Bytes.Reader): number + local h = r:peek(8) + if #h < 8 then + return 0 + end + local magic = string.sub(h, 1, 4) + local ver = string.sub(h, 5, 8) + if (magic == "\0\5\22\0" or magic == "\0\5\22\7") and (ver == "\0\1\0\0" or ver == "\0\2\0\0") then + return 1 + end + return 0 +end +end + +do -- archive/ar +local Bytes = __include("core/Bytes") +local MAGIC = "!<arch>\n" +S["archive/ar"] = function(r: Bytes.Reader): number + if r:peek(8) == MAGIC then + return if r:peek(13, 68) == "debian-binary" then 1 else 0.9 + end + return if r:peek(8) == "!<thin>\n" then 0.5 else 0 +end +end + +do -- archive/arj +local Bytes = __include("core/Bytes") +S["archive/arj"] = function(r: Bytes.Reader): number + local h = r:peek(4) + if #h == 4 and string.byte(h, 1) == 0x60 and string.byte(h, 2) == 0xEA then + local size = string.byte(h, 3) + string.byte(h, 4) * 256 + return if size > 0 and size <= 2600 then 0.9 else 0 + end + return 0 +end +end + +do -- archive/binhex +local Bytes = __include("core/Bytes") +local BANNER = "(This file must be converted with BinHex" +S["archive/binhex"] = function(r: Bytes.Reader): number + local head = r:peek(2048) + local at = string.find(head, BANNER, 1, true) + if not at then + return 0 + end + return if at == 1 then 1 else 0.8 +end +end + +do -- archive/br +local Err = __include("core/Err") +local Bytes = __include("core/Bytes") +local Brotli = lazy(function() + return __include("codecs/compress/Brotli") +end) +local SNIFF_WHOLE = 262144 -- streams up to this size are decoded whole by sniff +local SNIFF_PREFIX = 65536 +S["archive/br"] = function(r: Bytes.Reader): number + local n = r:remaining() + if n == 0 then + return 0 + end + if n <= SNIFF_WHOLE then + local out, consumed = Brotli.decompress(r.buf, r.pos, n, { maxBytes = 2 ^ 26 }) + if out and consumed == r.limit then + return if buffer.len(out) > 0 then 0.3 else 0.05 + end + return 0 + end + local _, err = Brotli.decompress(r.buf, r.pos, SNIFF_PREFIX, { maxBytes = 2 ^ 22 }) + if err and (err.code == Err.TRUNCATED or err.code == Err.LIMIT) then + return 0.05 + end + return 0 +end +end + +do -- archive/bz2 +local Bytes = __include("core/Bytes") +S["archive/bz2"] = function(r: Bytes.Reader): number + local h = r:peek(10) + if #h < 10 or string.sub(h, 1, 3) ~= "BZh" then + return 0 + end + local lv = string.byte(h, 4) + if lv < 0x31 or lv > 0x39 then + return 0 + end + local magic = string.sub(h, 5, 10) + if magic == "\x31\x41\x59\x26\x53\x59" or magic == "\x17\x72\x45\x38\x50\x90" then + return 1 + end + return 0 +end +end + +do -- archive/cab +local Bytes = __include("core/Bytes") +S["archive/cab"] = function(r: Bytes.Reader): number + if r:peek(8) == "MSCF\0\0\0\0" then + return 1 + end + return 0 +end +end + +do -- archive/cpio +local Bytes = __include("core/Bytes") +S["archive/cpio"] = function(r: Bytes.Reader): number + local m = r:peek(6) + if m == "070701" or m == "070702" or m == "070707" then + return 1 + end + local b2 = r:peek(2) + if (b2 == "\199\113" or b2 == "\113\199") and r:remaining() >= 26 then + return 0.5 + end + return 0 +end +end + +do -- archive/d64 +local Bytes = __include("core/Bytes") +type Geometry = { kind: string, tracks: number, offsets: { number }, spt: { number }, dirTrack: number, total: number } +local function geometry(kind: string, tracks: number): Geometry + local offsets, spt = {}, {} + local o = 0 + for t = 1, tracks do + local n + if kind == "d81" then + n = 40 + else + local s = if kind == "d71" and t > 35 then t - 35 else t + n = if s <= 17 then 21 elseif s <= 24 then 19 elseif s <= 30 then 18 else 17 + end + offsets[t], spt[t] = o, n + o += n * 256 + end + return { kind = kind, tracks = tracks, offsets = offsets, spt = spt, dirTrack = if kind == "d81" then 40 else 18, total = o } +end +local function detect(len: number): Geometry? + for _, g in { { "d64", 35 }, { "d64", 40 }, { "d64", 42 }, { "d71", 70 }, { "d81", 80 } } :: { { any } } do + local geo = geometry(g[1] :: string, g[2] :: number) + local sectors = geo.total // 256 + if len == geo.total or (g[1] ~= "d81" and len == geo.total + sectors) then + return geo + end + end + return nil +end +S["archive/d64"] = function(r: Bytes.Reader): number + local geo = detect(r:size()) + if not geo then + return 0 + end + -- the BAM / header sector: dir track link and DOS version byte + local h = r:sub(geo.offsets[geo.dirTrack], 256) + local t, s, v = h:u8(), h:u8(), h:u8() + if geo.kind == "d81" then + return if t == 40 and s == 3 and v == 0x44 then 0.9 else 0.3 + end + return if t == 18 and s == 1 and (v == 0x41 or v == 0) then 0.9 else 0.3 +end +end + +do -- archive/fat +local Bytes = __include("core/Bytes") +local Fat = lazy(function() + return __include("containers/Fat") +end) +S["archive/fat"] = function(r: Bytes.Reader): number + if r:remaining() < 512 then + return 0 + end + local v = Fat.open(r.buf, r.base + r.pos, r.limit - r.base - r.pos) + if not v then + return 0 + end + return if v.partition then 0.6 else 0.8 +end +end + +do -- archive/grp +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +local MAGIC = "KenSilverman" +S["archive/grp"] = function(r: Bytes.Reader): number + return Sniff.magic(r, MAGIC) +end +end + +do -- archive/gzip +local Bytes = __include("core/Bytes") +S["archive/gzip"] = function(r: Bytes.Reader): number + return if r:peek(3) == "\31\139\8" then 1 else 0 +end +end + +do -- archive/iso +local Bytes = __include("core/Bytes") +S["archive/iso"] = function(r: Bytes.Reader): number + return if r:peek(5, 16 * 2048 + 1) == "CD001" then 1 else 0 +end +end + +do -- archive/lha +local Bytes = __include("core/Bytes") +local METHODS: { [string]: boolean } = { + ["-lh0-"] = true, ["-lz4-"] = true, ["-lhd-"] = true, ["-lh1-"] = true, ["-lh4-"] = true, ["-lh5-"] = true, + ["-lh6-"] = true, ["-lh7-"] = true, ["-lhx-"] = true, ["-lzs-"] = true, ["-lz5-"] = true, ["-lh2-"] = true, + ["-lh3-"] = true, ["-pm0-"] = true, ["-pm1-"] = true, ["-pm2-"] = true, ["-lk7-"] = true, +} +local function isHeader(s: string): boolean + if #s < 22 then + return false + end + local m = string.sub(s, 3, 7) + local level = string.byte(s, 21) + return METHODS[m] == true and level <= 3 +end +S["archive/lha"] = function(r: Bytes.Reader): number + if isHeader(r:peek(22)) then + return 0.95 + end + return 0 +end +end + +do -- archive/lz4 +local Bytes = __include("core/Bytes") +S["archive/lz4"] = function(r: Bytes.Reader): number + local m = r:peek(4) + if m == "\4\34\77\24" then + return 1 + elseif m == "\2\33\76\24" then + return 0.9 + elseif #m == 4 and string.byte(m, 1) >= 0x50 and string.byte(m, 1) <= 0x5F and string.sub(m, 2) == "\42\77\24" then + -- a skippable frame (zstd shares the magic): an LZ4 frame after it + local h = r:peek(4, 4) + if #h == 4 then + local n = string.byte(h, 1) + string.byte(h, 2) * 256 + string.byte(h, 3) * 65536 + string.byte(h, 4) * 16777216 + if r:peek(4, 8 + n) == "\4\34\77\24" then + return 1 + end + end + end + return 0 +end +end + +do -- archive/macbinary +local Bytes = __include("core/Bytes") +local Crc16 = __include("core/Crc16") +local function version(b: buffer, o: number, len: number): string? + if len < 128 then + return nil + end + local u8 = function(i: number): number + return buffer.readu8(b, o + i) + end + if u8(0) ~= 0 or u8(74) ~= 0 then + return nil + end + local nameLen = u8(1) + if nameLen < 1 or nameLen > 63 then + return nil + end + local function be32(i: number): number + return u8(i) * 16777216 + u8(i + 1) * 65536 + u8(i + 2) * 256 + u8(i + 3) + end + local dlen, rlen = be32(83), be32(87) + if dlen > 0x7FFFFFFF or rlen > 0x7FFFFFFF then + return nil + end + local crc = u8(124) * 256 + u8(125) + if crc == Crc16.ccitt(b, o, 124) and (crc ~= 0 or u8(122) >= 129) then + return if buffer.readstring(b, o + 102, 4) == "mBIN" then "III" else "II" + end + if buffer.readstring(b, o + 102, 4) == "mBIN" then + return nil -- III with a bad CRC + end + -- MacBinary I: byte 82 zero, bytes 99..125 zero, the forks within the file + if u8(82) ~= 0 then + return nil + end + for i = 99, 125 do + if u8(i) ~= 0 then + return nil + end + end + local need = 128 + math.ceil(dlen / 128) * 128 + rlen + return if need <= len + 127 then "I" else nil +end +S["archive/macbinary"] = function(r: Bytes.Reader): number + local n = math.min(r:remaining(), 128) + if n < 128 then + return 0 + end + local v = version(r.buf, r.base + r.pos, r.limit - r.base - r.pos) + return if v == "III" then 0.95 elseif v == "II" then 0.8 elseif v == "I" then 0.3 else 0 +end +end + +do -- archive/mpq +local Bytes = __include("core/Bytes") +S["archive/mpq"] = function(r: Bytes.Reader): number + local m = r:peek(4) + if m == "MPQ\x1A" or m == "MPQ\x1B" then + return 1 + end + -- a prefixed archive (an installer stub): the header on a 512-byte boundary in the first 64 KB + for at = 512, math.min(65536, r:remaining() - 32), 512 do + if r:peek(4, at) == "MPQ\x1A" then + return 0.6 + end + end + return 0 +end +end + +do -- archive/pak +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["archive/pak"] = function(r: Bytes.Reader): number + if r:remaining() < 12 then + return 0 + end + return math.max(Sniff.magic(r, "PACK", 0, 0.9), Sniff.magic(r, "SPAK", 0, 0.9)) +end +end + +do -- archive/rpm +local Bytes = __include("core/Bytes") +local LEAD_MAGIC = "\237\171\238\219" +S["archive/rpm"] = function(r: Bytes.Reader): number + return if r:peek(4) == LEAD_MAGIC then 1 else 0 +end +end + +do -- archive/tar +local Bytes = __include("core/Bytes") +local Tar = lazy(function() + return __include("containers/Tar") +end) +S["archive/tar"] = function(r: Bytes.Reader): number + if r:remaining() < 512 then + return 0 + end + if not Tar.valid(r.buf, r.pos) then + return 0 + end + return if r:peek(5, 257) == "ustar" then 0.95 else 0.6 +end +end + +do -- archive/unitypackage +local Bytes = __include("core/Bytes") +local Deflate = lazy(function() + return __include("codecs/compress/Deflate") +end) +local Tar = lazy(function() + return __include("containers/Tar") +end) +local function guidOf(name: string): (string?, string?) + local n = string.gsub(name, "^%./", "") + local guid, rest = string.match(n, "^(%x+)/?(.*)$") + if guid and #guid == 32 then + return string.lower(guid), rest + end + return nil, nil +end +S["archive/unitypackage"] = function(r: Bytes.Reader): number + if r:peek(3) ~= "\31\139\8" then + return 0 + end + local head = Deflate.peek(r.buf, r.pos, r.limit - r.pos, 512) + if not head or buffer.len(head) < 512 or not Tar.valid(head, 0) then + return 0 + end + local z = 0 + while z < 100 and buffer.readu8(head, z) ~= 0 do + z += 1 + end + return if guidOf(buffer.readstring(head, 0, z)) then 1 else 0 -- ties with archive/gzip go to the extension +end +end + +do -- archive/uu +local Bytes = __include("core/Bytes") +S["archive/uu"] = function(r: Bytes.Reader): number + local head = r:peek(4096) + if string.match(head, "^begin%-base64 [0-7]+ [^\r\n]") or string.match(head, "^begin [0-7]+ [^\r\n]") then + return 0.9 + end + if string.match(head, "\nbegin%-base64 [0-7]+ [^\r\n]") or string.match(head, "\nbegin [0-7][0-7][0-7]+ [^\r\n]") then + return 0.5 + end + return 0 +end +end + +do -- archive/vpk +local Bytes = __include("core/Bytes") +S["archive/vpk"] = function(r: Bytes.Reader): number + if r:remaining() < 12 or r:peek(4) ~= "\x34\x12\xAA\x55" then + return 0 + end + local v = r:peekU8(4) + return if v == 1 or v == 2 then 1 else 0.5 +end +end + +do -- archive/vswap +local Bytes = __include("core/Bytes") +local readu8, readu16, readi16, writeu32 = buffer.readu8, buffer.readu16, buffer.readi16, buffer.writeu32 +local function header(r: Bytes.Reader): (number?, number, number) + if r:remaining() < 6 then + return nil, 0, 0 + end + local n, ss, so = readu16(r.buf, r.base), readu16(r.buf, r.base + 2), readu16(r.buf, r.base + 4) + if n == 0 or ss > so or so > n or 6 + n * 6 > r:remaining() then + return nil, 0, 0 + end + return n, ss, so +end +S["archive/vswap"] = function(r: Bytes.Reader): number + local n = header(r) + if not n then + return 0 + end + local size = r.limit - r.base + local b = r.buf + local last = 6 + n * 6 + local nonzero = 0 + for i = 0, n - 1 do + local o = buffer.readu32(b, r.base + 6 + i * 4) + local l = readu16(b, r.base + 6 + n * 4 + i * 2) + if o ~= 0 then + if o < last or o + l > size then + return 0 + end + last = o + nonzero += 1 + end + end + return if nonzero > 0 then 0.6 else 0 +end +end + +do -- archive/wad +local Bytes = __include("core/Bytes") +S["archive/wad"] = function(r: Bytes.Reader): number + if r:remaining() < 12 then + return 0 + end + local m = r:peek(4) + if m ~= "IWAD" and m ~= "PWAD" then + return 0 + end + return 0.9 +end +end + +do -- archive/wad2 +local Bytes = __include("core/Bytes") +S["archive/wad2"] = function(r: Bytes.Reader): number + if r:remaining() < 12 then + return 0 + end + local m = r:peek(4) + return if m == "WAD2" or m == "WAD3" then 0.9 else 0 +end +end + +do -- archive/xz +local Bytes = __include("core/Bytes") +local XZ_MAGIC = "\253" .. "7zXZ\0" +local function aloneScore(r: Bytes.Reader): number + local h = r:peek(14) + if #h < 14 then + return 0 + end + local d = string.byte(h, 1) + if d >= 225 or string.byte(h, 14) ~= 0 then + return 0 + end + local dict = string.byte(h, 2) + string.byte(h, 3) * 256 + string.byte(h, 4) * 65536 + string.byte(h, 5) * 16777216 + local okDict = false + for n = 12, 31 do + if dict == 2 ^ n or (n < 31 and dict == 2 ^ n + 2 ^ (n - 1)) then + okDict = true + break + end + end + if not okDict then + return 0 + end + local s = string.sub(h, 6, 13) + if s ~= string.rep("\255", 8) and (string.byte(h, 11) ~= 0 or string.byte(h, 12) ~= 0 or string.byte(h, 13) ~= 0) then + return 0 + end + return if d == 0x5D then 0.4 else 0.2 +end +S["archive/xz"] = function(r: Bytes.Reader): number + if r:peek(6) == XZ_MAGIC then + return 1 + end + return aloneScore(r) +end +end + +do -- archive/yenc +local Bytes = __include("core/Bytes") +S["archive/yenc"] = function(r: Bytes.Reader): number + local head = r:peek(4096) + if string.match(head, "^=ybegin ") then + return 0.95 + end + return if string.find(head, "\n=ybegin [^\n]*name=") then 0.6 else 0 +end +end + +do -- archive/z +local Bytes = __include("core/Bytes") +S["archive/z"] = function(r: Bytes.Reader): number + if r:peek(2) ~= "\31\157" then + return 0 + end + local f = r:peekU8(2) + return if f >= 0 and bit32.band(f, 0x60) == 0 and bit32.band(f, 0x1F) >= 9 and bit32.band(f, 0x1F) <= 16 then 1 else 0.3 +end +end + +do -- archive/zip +local Bytes = __include("core/Bytes") +S["archive/zip"] = function(r: Bytes.Reader): number + local s = r:peek(4) + -- ZIP-based formats (docx, jar, 3mf, ...) score higher in their own sniff + if s == "PK\3\4" or s == "PK\5\6" then + return 0.6 + end + if string.sub(s, 1, 2) == "MZ" then + return 0 -- a self-extractor opens with Zip.decode / opts.format = "zip" + end + return 0 +end +end + +do -- archive/zoo +local Bytes = __include("core/Bytes") +local TAG = 0xFDC4A7DC +S["archive/zoo"] = function(r: Bytes.Reader): number + local h = r:peek(24) + if #h < 24 then + return 0 + end + local tag = string.byte(h, 21) + string.byte(h, 22) * 256 + string.byte(h, 23) * 65536 + string.byte(h, 24) * 16777216 + if tag ~= TAG then + return 0 + end + return if string.sub(h, 1, 4) == "ZOO " then 1 else 0.8 +end +end + +do -- archive/zst +local Bytes = __include("core/Bytes") +local Zstd = lazy(function() + return __include("codecs/compress/Zstd") +end) +S["archive/zst"] = function(r: Bytes.Reader): number + local m = r:peek(4) + if m == Zstd.MAGIC then + return 1 + end + -- a skippable frame (0x184D2A50 .. 0x184D2A5F) is usually followed by a zstd frame + if #m == 4 and string.sub(m, 2, 4) == "\42\77\24" and bit32.band(string.byte(m, 1), 0xF0) == 0x50 then + return 0.5 + end + return 0 +end +end + +do -- data/cbor +local Bytes = __include("core/Bytes") +S["data/cbor"] = function(r: Bytes.Reader): number + return if r:peek(3) == "\217\217\247" then 1 else 0 +end +end + +do -- data/csv +local Bytes = __include("core/Bytes") +local find, sub, byte, gsub = string.find, string.sub, string.byte, string.gsub +S["data/csv"] = function(r: Bytes.Reader): number + local head = r:peek(1024) + if find(head, "%z") then + return 0 + end + local l1, l2 = string.match(head, "^([^\r\n]*)\r?\n([^\r\n]*)") + if not l1 or l1 == "" then + return 0 + end + for _, d in { ",", "\t", ";" } do + local _, c1 = gsub(l1, d, "") + local _, c2 = gsub(l2 :: string, d, "") + if c1 > 0 and c1 == c2 then + return 0.15 + end + end + return 0 +end +end + +do -- data/ini +local Bytes = __include("core/Bytes") +S["data/ini"] = function(r: Bytes.Reader): number + local head = r:peek(512) + if string.find(head, "%z") then + return 0 + end + local first = string.match(head, "^[%s]*([^\r\n]*)") + while first and string.match(first, "^[;#]") do + head = string.match(head, "^[^\n]*\n(.*)$") or "" + first = string.match(head, "^[%s]*([^\r\n]*)") + end + if first and string.match(first, "^%[[^%]]+%]%s*$") then + return 0.2 + end + return 0 +end +end + +do -- data/json +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["data/json"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 64) + local first = string.match(head, "^[ \t\r\n]*(.)") + if first == "{" then + local nxt = string.match(head, "^[^{]*{[ \t\r\n]*(.)") + return if nxt == nil or nxt == '"' or nxt == "}" then 0.6 else 0.1 + elseif first == "[" then + -- past any nested '[': a JSON value must start (TOML / INI "[section]" and "[[table]]" do not) + local nxt = string.match(head, "^[ \t\r\n]*[%[ \t\r\n]*(.)") + if nxt == nil or string.find('{"-0123456789tfn]', nxt, 1, true) then + return 0.3 + end + return 0 + end + return 0 +end +end + +do -- data/msgpack +local Bytes = __include("core/Bytes") +S["data/msgpack"] = function(_r: Bytes.Reader): number + return 0 -- no magic: by extension or opts.format only +end +end + +do -- data/nbt +local Bytes = __include("core/Bytes") +local Nbt = lazy(function() + return __include("codecs/text/Nbt") +end) +S["data/nbt"] = function(r: Bytes.Reader): number + local p = Nbt.peek(r.buf, r.base, r.limit - r.base) + if not p or p.rootType ~= "compound" then + return 0 + end + if p.compression ~= "none" then + return if p.firstType then 1 else 0.5 -- gzip wrapped NBT: ties with archive/gzip go to the extension + end + return if p.firstType and p.firstName then 0.6 else 0.2 +end +end + +do -- data/plist +local Bytes = __include("core/Bytes") +S["data/plist"] = function(r: Bytes.Reader): number + local head = r:peek(256) + if string.sub(head, 1, 6) == "bplist" then + return 1 + end + if string.find(head, "<!DOCTYPE plist", 1, true) or string.find(head, "<plist", 1, true) then + return 0.9 + end + return 0 +end +end + +do -- data/q3shader +local Bytes = __include("core/Bytes") +local KEYWORDS = { "surfaceparm", "map", "clampmap", "animmap", "blendfunc", "rgbgen", "alphagen", "tcgen", "tcmod", + "cull", "deformvertexes", "qer_editorimage", "nopicmip", "nomipmaps", "skyparms", "q3map_", "depthwrite", "alphafunc" } +S["data/q3shader"] = function(r: Bytes.Reader): number + local head = r:peek(math.min(r:remaining(), 2048)) + if #head < 4 or string.find(head, "[%z\1-\8\14-\31]") then + return 0 + end + local s = string.gsub(string.gsub(head, "/%*.-%*/", " "), "//[^\n]*", "") + if not string.match(s, "^%s*[^%s{}\"]+%s*{") then + return 0 + end + local lower = string.lower(s) + for _, k in KEYWORDS do + if string.find(lower, "%f[%w_]" .. k) then + return 0.7 + end + end + return 0.2 +end +end + +do -- data/q3skin +local Bytes = __include("core/Bytes") +S["data/q3skin"] = function(r: Bytes.Reader): number + local head = r:peek(math.min(r:remaining(), 1024)) + if #head < 3 or string.find(head, "[%z\1-\8\14-\31]") then + return 0 + end + local lines, good, paths = 0, 0, 0 + for line in string.gmatch(head, "[^\r\n]+") do + if not string.match(line, "^%s*$") then + lines += 1 + local surface, shader = string.match(line, "^%s*([%w_%-]+)%s*,%s*([^,%s]*)%s*$") + if surface and shader == "" and string.sub(string.lower(surface), 1, 4) == "tag_" then + good += 1 + elseif shader and string.find(shader, "/", 1, true) then + good += 1 + paths += 1 + end + end + end + return if lines > 0 and good == lines and paths > 0 then 0.5 else 0 +end +end + +do -- data/snbt +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["data/snbt"] = function(r: Bytes.Reader): number + -- SNBT has what JSON never has: unquoted keys, typed numbers (1b, 2.5f), [I; arrays, single-quoted strings + local head = Sniff.text(r, 512, true) + local first = string.sub(head, 1, 1) + if first ~= "{" and first ~= "[" then + return 0 + end + if string.find(head, "[{,]%s*[%a_][%w_%-%.%+]*%s*:") or string.find(head, "%d[bBsSlLfFdD]%s*[,}%]]") + or string.find(head, "%[[BIL]%s*;") or string.find(head, "[:,%[]%s*'") + then + return 0.7 + end + return 0 +end +end + +do -- data/toml +local Bytes = __include("core/Bytes") +S["data/toml"] = function(r: Bytes.Reader): number + local head = r:peek(512) + if string.find(head, "%z") then + return 0 + end + for line in string.gmatch(head, "[^\n]+") do + local l = string.match(line, "^[ \t]*(.-)[ \t\r]*$") :: string + if l ~= "" and string.sub(l, 1, 1) ~= "#" then + if string.match(l, "^%[%[?[%w_%-%.\"' ]+%]%]?$") or string.match(l, "^[%w_%-%.\"']+[ \t]*=[ \t]*[\"'%[{%dtf%+%-in]") then + return 0.2 + end + return 0 + end + end + return 0 +end +end + +do -- data/tres +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["data/tres"] = function(r: Bytes.Reader): number + local h = Sniff.text(r, 256) + if string.match(h, "^%s*%[gd_resource[%s%]]") then + return 1 + end + return 0 +end +end + +do -- data/vdf +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +local KeyValues = lazy(function() + return __include("codecs/text/KeyValues") +end) +S["data/vdf"] = function(r: Bytes.Reader): number + local n = r:remaining() + if KeyValues.isBinary(r.buf, r.pos, n) then + return 0.3 + end + local head = Sniff.text(r, 256, true) + if string.find(head, "%z") then + return 0 + end + head = string.gsub(head, "^//[^\n]*\n%s*", "") + if string.match(head, '^"[^"\n]+"%s*{') or string.match(head, '^"[^"\n]+"%s*%[[^%]\n]*%]%s*{') then + return 0.6 + end + if string.match(head, "^#base%s") or string.match(head, "^#include%s") then + return 0.5 + end + if string.match(head, '^[%w_]+%s*\n%s*{%s*\n%s*"') then + return 0.3 + end + return 0 +end +end + +do -- data/xml +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["data/xml"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 64) + if string.match(head, "^<%?xml[ \t\r\n]") or string.sub(head, 1, 4) == "\255\254<\0" or string.sub(head, 1, 4) == "\254\255\0<" then + return 0.5 + end + if string.match(head, "^[ \t\r\n]*<[%a!]") then + return 0.3 + end + return 0 +end +end + +do -- data/yaml +local Bytes = __include("core/Bytes") +S["data/yaml"] = function(r: Bytes.Reader): number + local head = r:peek(256) + if string.find(head, "%z") then + return 0 + end + if string.match(head, "^%%YAML ") then + return 0.9 + end + if string.match(head, "^%-%-%-[ \r\n]") then + return 0.5 + end + local line = string.match(head, "^[ \t\r\n]*([^\r\n]*)") + if line and (string.match(line, "^[%w_%-\"']+[%w_%- \"']*:[ ]") or string.match(line, "^[%w_%-]+:$") or string.match(line, "^%- ")) then + return 0.2 + end + return 0 +end +end + +do -- vector/gamemaps +local Bytes = __include("core/Bytes") +local MAGIC = "TED5v1.0" +S["vector/gamemaps"] = function(r: Bytes.Reader): number + if r:peek(8) == MAGIC then + return 1 + end + -- MAPHEAD: the RLEW tag 0xABCD, then 100 offsets (0 / -1 when absent) + if r:remaining() >= 402 and r:remaining() <= 1024 and buffer.readu16(r.buf, r.base) == 0xABCD then + local first = buffer.readi32(r.buf, r.base + 2) + if first > 0 then + return 0.7 + end + end + return 0 +end +end + +do -- vector/ldtk +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["vector/ldtk"] = function(r: Bytes.Reader): number + local h = Sniff.text(r, 1024) + if not string.match(h, "^%s*{") then + return 0 + end + if string.find(h, "\"fileType\"%s*:%s*\"LDtk Project JSON\"") then + return 1 + end + if string.find(h, "\"jsonVersion\"", 1, true) and string.find(h, "\"worldLayout\"", 1, true) then + return 0.8 + end + return 0 +end +end + +do -- vector/ogmo +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["vector/ogmo"] = function(r: Bytes.Reader): number + local h = Sniff.text(r, 2048) + if not string.match(h, "^%s*{") or not string.find(h, "\"ogmoVersion\"", 1, true) then + return 0 + end + if string.find(h, "\"layerGridDefaultSize\"", 1, true) or string.find(h, "\"levelPaths\"", 1, true) then + return 1 + end + return 0.9 +end +end + +do -- vector/svg +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["vector/svg"] = function(r: Bytes.Reader): number + local h = Sniff.text(r, 4096) + if not string.match(h, "^%s*<") then + return 0 + end + if string.find(h, "<svg[%s>:]") or string.find(h, "<%w+:svg[%s>]") then + return 0.95 + end + return 0 +end +end + +do -- vector/tiled +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +local function head(r: Bytes.Reader): string + local h = Sniff.text(r, 1024) + return h +end +S["vector/tiled"] = function(r: Bytes.Reader): number + local h = head(r) + if string.match(h, "^%s*<") then + if string.find(h, "<map[%s>]") or string.find(h, "<tileset[%s>]") then + return 0.9 + end + return 0 + end + if string.match(h, "^%s*{") then + -- Tiled writes its keys sorted: "type" comes last, so look at the tail too + local n = r:remaining() + local tail = if n > 1024 then r:peek(1024, n - 1024) else "" + for _, part in { h, tail } do + if string.find(part, "\"type\"%s*:%s*\"map\"") or string.find(part, "\"type\"%s*:%s*\"tileset\"") then + return 0.8 + end + end + if string.find(h, "\"tilewidth\"", 1, true) and (string.find(h, "\"orientation\"", 1, true) or string.find(h, "\"tilesets\"", 1, true)) then + return 0.6 + end + end + return 0 +end +end + +do -- layered/aseprite +local Bytes = __include("core/Bytes") +S["layered/aseprite"] = function(r: Bytes.Reader): number + if r:peekU8(4) == 0xE0 and r:peekU8(5) == 0xA5 then + local d = r:peekU8(12) + if (d == 32 or d == 16 or d == 8) and r:peekU8(13) == 0 then + return 1 + end + return 0.5 + end + return 0 +end +end + +do -- layered/ora +local Bytes = __include("core/Bytes") +local MIME = "image/openraster" +S["layered/ora"] = function(r: Bytes.Reader): number + -- a zip whose first (stored) entry is "mimetype" holding image/openraster + if r:peek(4) == "PK\3\4" and r:peek(8, 30) == "mimetype" and r:peek(#MIME, 38) == MIME then + return 1 + end + return 0 +end +end + +do -- layered/psd +local Bytes = __include("core/Bytes") +S["layered/psd"] = function(r: Bytes.Reader): number + local h = r:peek(6) + if string.sub(h, 1, 4) == "8BPS" and (string.sub(h, 5, 6) == "\0\1" or string.sub(h, 5, 6) == "\0\2") then + return 1 + end + return 0 +end +end + +do -- subtitle/ass +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["subtitle/ass"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 64) + if string.match(head, "^%s*%[[Ss]cript [Ii]nfo%]") then + return 1 + end + return 0 +end +end + +do -- subtitle/srt +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +local TIMING = "^%s*(%d+):(%d%d?):(%d%d?)[,.](%d+)%s*%-%->%s*(%d+):(%d%d?):(%d%d?)[,.](%d+)%s*(.-)%s*$" +local function frac(digits: string): number + return (tonumber(digits) :: number) / 10 ^ #digits +end +local function timing(line: string): (number?, number?, string?) + local h1, m1, s1, f1, h2, m2, s2, f2, rest = string.match(line, TIMING) + if not h1 then + return nil, nil, nil + end + local a = tonumber(h1) :: number * 3600 + tonumber(m1) :: number * 60 + tonumber(s1) :: number + frac(f1 :: string) + local b = tonumber(h2) :: number * 3600 + tonumber(m2) :: number * 60 + tonumber(s2) :: number + frac(f2 :: string) + return a, b, rest +end +S["subtitle/srt"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 512) + head = string.gsub(head, "\r", "\n") + local first, second = string.match(head, "^%s*([^\n]*)\n([^\n]*)") + if first and string.match(first, "^%d+%s*$") and second and timing(second) then + return 0.9 + end + if first and timing(first) then + return 0.6 + end + return 0 +end +end + +do -- subtitle/vtt +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["subtitle/vtt"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 10) + if string.sub(head, 1, 6) == "WEBVTT" then + local c = string.sub(head, 7, 7) + if c == "" or c == " " or c == "\t" or c == "\n" or c == "\r" then + return 1 + end + end + return 0 +end +end + +do -- music/669 +local Bytes = __include("core/Bytes") +local function validHeader(r: Bytes.Reader): boolean + if r:size() < 497 then + return false + end + local magic = r:peek(2) + if magic ~= "if" and magic ~= "JN" then + return false + end + local nsmp, npat, restart = r:peekU8(110), r:peekU8(111), r:peekU8(112) + if nsmp > 64 or restart >= 128 or npat > 128 then + return false + end + local bad = 0 + for i = 2, 109 do + local c = r:peekU8(i) + if c > 0 and c <= 31 then + bad += 1 + if bad > 40 then + return false + end + end + end + for i = 0, 127 do + local o, t, b = r:peekU8(113 + i), r:peekU8(241 + i), r:peekU8(369 + i) + if (o >= 128 and o < 0xFE) or (o < 128 and t == 0) or t > 15 or b >= 64 then + return false + end + end + return true +end +S["music/669"] = function(r: Bytes.Reader): number + return if validHeader(r) then 0.6 else 0 +end +end + +do -- music/ahx +local Bytes = __include("core/Bytes") +S["music/ahx"] = function(r: Bytes.Reader): number + local m = r:peek(4) + return if m and #m == 4 and string.sub(m, 1, 3) == "THX" and string.byte(m, 4) < 3 then 1 else 0 +end +end + +do -- music/far +local Bytes = __include("core/Bytes") +S["music/far"] = function(r: Bytes.Reader): number + if r:size() >= 98 and r:peek(4) == "FAR\xFE" and r:peek(3, 44) == "\r\n\x1A" and r:peekU8(47) + r:peekU8(48) * 256 >= 98 then + return 1 + end + return 0 +end +end + +do -- music/hmp +local Bytes = __include("core/Bytes") +local HMI_MAGIC = "HMI-MIDISONG061595" +S["music/hmp"] = function(r: Bytes.Reader): number + return if r:peek(8) == "HMIMIDIP" or r:peek(18) == HMI_MAGIC then 1 else 0 +end +end + +do -- music/hvl +local Bytes = __include("core/Bytes") +S["music/hvl"] = function(r: Bytes.Reader): number + local m = r:peek(4) + return if m and #m == 4 and string.sub(m, 1, 3) == "HVL" and string.byte(m, 4) <= 1 then 1 else 0 +end +end + +do -- music/it +local Bytes = __include("core/Bytes") +S["music/it"] = function(r: Bytes.Reader): number + return if r:peek(4) == "IMPM" then 1 else 0 +end +end + +do -- music/med +local Bytes = __include("core/Bytes") +local function validHeader(r: Bytes.Reader): boolean + if r:size() < 52 or r:peek(3) ~= "MMD" then + return false + end + local v = r:peekU8(3) + if v < 0x30 or v > 0x33 then + return false + end + local h = r:sub(8, 44) + local songOff = h:u32be() + h:skip(4) + local blockOff = h:u32be() + h:skip(4) + local smpOff = h:u32be() + return songOff >= 52 and songOff + 63 * 8 + 284 <= r:size() and blockOff >= 52 and (smpOff == 0 or smpOff >= 52) +end +S["music/med"] = function(r: Bytes.Reader): number + return if validHeader(r) then 1 else 0 +end +end + +do -- music/midi +local Bytes = __include("core/Bytes") +S["music/midi"] = function(r: Bytes.Reader): number + if r:peek(4) == "MThd" then + return 1 + end + if r:peek(4) == "RIFF" and r:peek(4, 8) == "RMID" then + return 1 + end + return 0 +end +end + +do -- music/mod +local Bytes = __include("core/Bytes") +local FIXED: { [string]: number } = { + ["M.K."] = 4, + ["M!K!"] = 4, + ["M&K!"] = 4, + ["N.T."] = 4, + ["FLT4"] = 4, + ["FLT8"] = 8, + ["CD81"] = 8, + ["OKTA"] = 8, + ["OCTA"] = 8, + ["EXO4"] = 4, + ["EXO8"] = 8, +} +local function signatureChannels(sig: string): number? + local fixed = FIXED[sig] + if fixed then + return fixed + end + local d = string.match(sig, "^(%d)CHN$") + if d then + local n = tonumber(d) :: number + return if n >= 1 then n else nil + end + local dd = string.match(sig, "^(%d%d)C[HN]$") + if dd then + local n = tonumber(dd) :: number + return if n >= 1 and n <= 32 then n else nil + end + local t = string.match(sig, "^TDZ(%d)$") + if t then + local n = tonumber(t) :: number + return if n >= 1 then n else nil + end + return nil +end +S["music/mod"] = function(r: Bytes.Reader): number + if r:size() < 1084 then + return 0 + end + local sig = r:peek(4, 1080) + if signatureChannels(sig) then + return 0.8 + end + return 0 +end +end + +do -- music/mtm +local Bytes = __include("core/Bytes") +S["music/mtm"] = function(r: Bytes.Reader): number + if r:size() >= 66 and r:peek(3) == "MTM" and r:peekU8(3) < 0x20 and r:peekU8(33) >= 1 and r:peekU8(33) <= 32 then + return 1 + end + return 0 +end +end + +do -- music/mus +local Bytes = __include("core/Bytes") +S["music/mus"] = function(r: Bytes.Reader): number + return if r:peek(4) == "MUS\x1a" then 1 else 0 +end +end + +do -- music/okt +local Bytes = __include("core/Bytes") +S["music/okt"] = function(r: Bytes.Reader): number + return if r:peek(8) == "OKTASONG" then 1 else 0 +end +end + +do -- music/ptm +local Bytes = __include("core/Bytes") +local function validHeader(r: Bytes.Reader): boolean + if r:size() < 608 or r:peek(4, 44) ~= "PTMF" or r:peekU8(28) ~= 26 or r:peekU8(30) > 2 then + return false + end + local h = r:sub(32, 10) + local nord, nsmp, npat, nch, flags = h:u16le(), h:u16le(), h:u16le(), h:u16le(), h:u16le() + return flags == 0 and nch >= 1 and nch <= 32 and nord >= 1 and nord <= 256 and nsmp >= 1 and nsmp <= 255 and npat >= 1 and npat <= 128 +end +S["music/ptm"] = function(r: Bytes.Reader): number + return if validHeader(r) then 1 else 0 +end +end + +do -- music/s3m +local Bytes = __include("core/Bytes") +S["music/s3m"] = function(r: Bytes.Reader): number + if r:size() >= 48 and r:peek(4, 44) == "SCRM" then + return 1 + end + return 0 +end +end + +do -- music/sf2 +local Bytes = __include("core/Bytes") +local SoundFont = lazy(function() + return __include("codecs/audio/SoundFont") +end) +S["music/sf2"] = function(r: Bytes.Reader): number + return if SoundFont.sniff(r) then 1 else 0 +end +end + +do -- music/stm +local Bytes = __include("core/Bytes") +local function validHeader(r: Bytes.Reader): boolean + if r:size() < 48 then + return false + end + local eof, ftype, major, minor = r:peekU8(28), r:peekU8(29), r:peekU8(30), r:peekU8(31) + local npat, gv = r:peekU8(33), r:peekU8(34) + if ftype ~= 2 or (eof ~= 0x1A and eof ~= 2) or major ~= 2 or (minor ~= 0 and minor ~= 10 and minor ~= 20 and minor ~= 21) then + return false + end + if npat > 64 or (gv > 64 and gv ~= 0x58) then + return false + end + for i = 20, 27 do + local c = r:peekU8(i) + if c < 0x20 or c >= 0x7F then + return false + end + end + return true +end +S["music/stm"] = function(r: Bytes.Reader): number + return if validHeader(r) then 0.7 else 0 +end +end + +do -- music/ult +local Bytes = __include("core/Bytes") +S["music/ult"] = function(r: Bytes.Reader): number + local v = r:peekU8(14) + if r:size() >= 48 and r:peek(14) == "MAS_UTrack_V00" and v >= 0x31 and v <= 0x34 then + return 1 + end + return 0 +end +end + +do -- music/umx +local Bytes = __include("core/Bytes") +local MAGIC = "\xC1\x83\x2A\x9E" +type Header = { version: number, nameCount: number, nameOffset: number, exportCount: number, exportOffset: number, importCount: number, importOffset: number } +local function header(r: Bytes.Reader): Header? + if r:size() < 36 or r:peek(4) ~= MAGIC then + return nil + end + local h = r:sub(4, 32) + local version = h:u16le() + h:skip(6) + local hd: Header = { + version = version, + nameCount = h:u32le(), + nameOffset = h:u32le(), + exportCount = h:u32le(), + exportOffset = h:u32le(), + importCount = h:u32le(), + importOffset = h:u32le(), + } + if h.err or hd.nameOffset < 36 or hd.exportOffset < 36 or hd.importOffset < 36 then + return nil + end + if hd.nameCount == 0 or hd.exportCount == 0 or hd.importCount == 0 or hd.nameCount > 2 ^ 20 or hd.exportCount > 2 ^ 20 or hd.importCount > 2 ^ 20 then + return nil + end + return hd +end +local function index(r: Bytes.Reader): number + local b = r:u8() + local neg = b >= 0x80 + local v = b % 64 + if bit32.band(b, 0x40) ~= 0 then + local shift = 6 + repeat + b = r:u8() + v += (b % 128) * 2 ^ shift + shift += 7 + until b < 0x80 or shift >= 32 + end + return if neg then -v else v +end +local function names(r: Bytes.Reader, h: Header): { string } + local list = {} + local nr = r:sub(h.nameOffset) + for _ = 1, math.min(h.nameCount, 65536) do + if nr:remaining() < 5 then + break + end + if h.version >= 64 then + index(nr) + end + table.insert(list, string.lower(nr:cstring(1024))) + nr:skip(4) + end + return list +end +S["music/umx"] = function(r: Bytes.Reader): number + local h = header(r) + if not h then + return 0 + end + return if table.find(names(r, h), "music") then 1 else 0.3 +end +end + +do -- music/xm +local Bytes = __include("core/Bytes") +local MAGIC = "Extended Module: " +S["music/xm"] = function(r: Bytes.Reader): number + return if r:peek(17) == MAGIC then 1 else 0 +end +end + +do -- music/xmi +local Bytes = __include("core/Bytes") +S["music/xmi"] = function(r: Bytes.Reader): number + local id, kind = r:peek(4), r:peek(4, 8) + if id == "FORM" and (kind == "XDIR" or kind == "XMID") then + return 1 + end + return if id == "CAT " and kind == "XMID" then 0.9 else 0 +end +end + +do -- playlist/m3u +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["playlist/m3u"] = function(r: Bytes.Reader): number + local s = Sniff.text(r, 512) + s = (string.match(s, "^%s*(.*)$") :: string) + if string.sub(s, 1, 7) == "#EXTM3U" then + return 0.95 + end + if string.find(s, "^#EXTINF:") or string.find(s, "^#EXT%-X%-") then + return 0.8 + end + return 0 +end +end + +do -- playlist/pls +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +local Text = lazy(function() + return __include("codecs/text/Text") +end) +S["playlist/pls"] = function(r: Bytes.Reader): number + local s = Sniff.text(r, 64) + local first = string.match(s, "^%s*([^\r\n]*)") + return if first and string.lower(Text.trim(first)) == "[playlist]" then 0.95 else 0 +end +end + +do -- playlist/xspf +local Bytes = __include("core/Bytes") +local NS = "http://xspf.org/ns/0/" +S["playlist/xspf"] = function(r: Bytes.Reader): number + local s = r:peek(1024) + local i = string.find(s, "<%w*:?playlist[%s>]") + if i and string.find(s, NS, 1, true) then + return 0.95 + end + return 0 +end +end + +return S +end +end + + + + archive_1 --!optimize 2 @@ -82641,7 +86282,7 @@ end - + archive_2 --!optimize 2 @@ -83501,7 +87142,7 @@ end - + audio --!optimize 2 @@ -91631,7 +95272,7 @@ end - + cad --!optimize 2 @@ -93066,7 +96707,7 @@ end - + codecs_audio --!optimize 2 @@ -99314,7 +102955,7 @@ end - + codecs_compress --!optimize 2 @@ -102355,7 +105996,7 @@ end - + codecs_entropy --!optimize 2 @@ -103131,7 +106772,7 @@ end - + codecs_font --!optimize 2 @@ -105344,7 +108985,7 @@ end - + codecs_image --!optimize 2 @@ -108399,7 +112040,7 @@ end - + codecs_model --!optimize 2 @@ -116478,7 +120119,7 @@ end - + codecs_text --!optimize 2 @@ -122680,7 +126321,7 @@ end - + codecs_video --!optimize 2 @@ -122979,7 +126620,7 @@ end - + containers --!optimize 2 @@ -131362,7 +135003,7 @@ end - + core --!optimize 2 @@ -132195,7 +135836,7 @@ end - + data --!optimize 2 @@ -137949,7 +141590,7 @@ end - + font --!optimize 2 @@ -141858,7 +145499,7 @@ end - + host --!optimize 2 @@ -142446,7 +146087,7 @@ end - + image_1 --!optimize 2 @@ -150290,7 +153931,7 @@ end - + image_2 --!optimize 2 @@ -154039,7 +157680,7 @@ end - + layered --!optimize 2 @@ -156164,7 +159805,7 @@ end - + model_1 --!optimize 2 @@ -163177,7 +166818,7 @@ end - + model_2 --!optimize 2 @@ -169836,7 +173477,7 @@ end - + model_3 --!optimize 2 @@ -177190,7 +180831,7 @@ end - + model_4 --!optimize 2 @@ -184598,7 +188239,7 @@ end - + model_5 --!optimize 2 @@ -192656,7 +196297,7 @@ end - + model_6 --!optimize 2 @@ -200621,7 +204262,7 @@ end - + model_7 --!optimize 2 @@ -201572,7 +205213,7 @@ end - + music --!optimize 2 @@ -207177,7 +210818,7 @@ end - + ops --!optimize 2 @@ -209330,7 +212971,7 @@ end - + playlist --!optimize 2 @@ -210077,7 +213718,7 @@ end - + subtitle --!optimize 2 @@ -210910,7 +214551,7 @@ end - + vector --!optimize 2 @@ -216924,7 +220565,7 @@ end - + video --!optimize 2 diff --git a/build/rosetta.lua b/build/rosetta.lua index 36cfb6f..a5f46e2 100644 --- a/build/rosetta.lua +++ b/build/rosetta.lua @@ -743,6 +743,56 @@ end local LATE= { br = 0.3 } -- archive/br: a trial decode of up to 256 KB +-- detection order: by the cost of a sniff (Registry.sniff: Sniffs.luau, Sniffs.luau reaching a codec, the format +-- module), then registry order; the costly LATE sniffs last +local order= nil +local byExt= {} +local Sniffs= nil + +local function sniffOrder() +local o = order + if o then + return o + end + local list= {} + for idx, e in __iter(Registry) do + table.insert(list, idx) + for _, x in __iter(e.extensions) do + byExt[x] = byExt[x] or {} + table.insert(byExt[x], idx) + end + end + local function rank(idx) +local e = Registry[idx] + return LATE[e.name] and 3 or e.sniff + end + table.sort(list, function(a, b) +local ra, rb = rank(a), rank(b) + if ra ~= rb then + return ra < rb + end + return a < b + end) + order = list + return list +end + +local function sniffer(e) +if e.sniff < 2 then + local s = Sniffs + if not s then + s = (__include("Sniffs") ) +Sniffs = s + end + local f = (s )[e.path] + if f then + return f + end + end + local m = module(e) + return (m and type(m.sniff) == "function" and{m.sniff }or{nil +})[1]end + local function detect(buf, name, category, format) if format then local e = find(format, category) @@ -752,52 +802,35 @@ if format then return e, nil end local ext = Input.extension(name) - local best= nil + local list = sniffOrder() + local hits = (ext and{byExt[ext] }or{nil +})[1] local best= nil local bestScore, bestIdx = 0, 0 - -- sniffs score 0..1 (core/Sniff); the extension's format scoring 1 cannot be beaten. Formats with a costly sniff - -- (LATE: the most they score) run last, and only when they could still win; ties go to registry order. - local late= nil - for idx, e in __iter(Registry) do -local __DARKLUA_CONTINUE_3=false repeat if inCategory(e, category) and (e.caps.decode or e.caps.open) then - local cap = LATE[e.name] - if cap then - late = late or {} - table.insert(late , idx) -__DARKLUA_CONTINUE_3=true break - end - local m = module(e) - if m and m.sniff then - local ok, score = pcall(m.sniff, Bytes.reader(buf)) - if ok and type(score) == "number" and score > 0 then - local extHit = ext and table.find(e.extensions, ext) - if extHit then - score =score+ 0.01 -- ties go to the extension - end - if score > bestScore then - best, bestScore, bestIdx = e, score, idx - if extHit and score >= 1.01 then - return e, nil - end - end + -- sniffs score 0..1 (core/Sniff), +0.01 for the extension's formats; the best wins, ties go to registry order. The + -- extension's formats run first, and a sniff runs only while its cap (1, or LATE) could still win. + for pass = 1, 2 do + local ids = (pass == 1 and{hits }or{list +})[1] if ids then + for _, idx in __iter(ids) do + if pass == 2 and bestScore > 1 then + break end - end - end -__DARKLUA_CONTINUE_3=true until true if not __DARKLUA_CONTINUE_3 then break end end - if late then - for _, idx in __iter(late) do - local e = Registry[idx] - local extHit = ext and table.find(e.extensions, ext) - local cap = LATE[e.name] + (extHit and 0.01 or 0) - if cap > bestScore or (cap == bestScore and idx < bestIdx) then - local m = module(e) - if m and m.sniff then - local ok, score = pcall(m.sniff, Bytes.reader(buf)) - if ok and type(score) == "number" and score > 0 then - if extHit then - score =score+ 0.01 - end - if score > bestScore or (score == bestScore and idx < bestIdx) then - best, bestScore, bestIdx = e, score, idx + local e = Registry[idx] + local extHit = pass == 1 or (hits ~= nil and table.find(hits, idx) ~= nil) + if (pass == 1 or not extHit) and inCategory(e, category) and (e.caps.decode or e.caps.open) then + local cap = (LATE[e.name] or 1) + (extHit and 0.01 or 0) + if cap > bestScore or (cap == bestScore and idx < bestIdx) then + local sniff = sniffer(e) + if sniff then + local ok, score = pcall(sniff, Bytes.reader(buf)) + if ok and type(score) == "number" and score > 0 then + if extHit then + score =score+ 0.01 + end + if score > bestScore or (score == bestScore and idx < bestIdx) then + best, bestScore, bestIdx = e, score, idx + end + end end end end @@ -1361,8 +1394,8 @@ local o= opts or {} return nil, err end -- a format may name the file's flavour more precisely (video/mkv: "webm" for DocType webm) - local m = module(entry) - if m and type(m.variant) == "function" then + local m = (entry.variant and{(module(entry) )}or{nil +})[1] if m and type(m.variant) == "function" then local ok, v = pcall(m.variant, Bytes.reader(buf)) if ok and type(v) == "string" then return v, nil @@ -1551,6 +1584,10 @@ __FILES["Registry"] = function() -- Registry: GENERATED by tools/gen_registry.py from the format folders - do not edit. -- One entry per format: the contract metadata (copied from its init.luau) and load(), which requires the format -- module on first use (a static require, as Roblox needs). Order: category, then name. +-- sniff: where detection finds the format's sniff (tools/sniff_extract.py): 0 Sniffs.luau, 1 Sniffs.luau reaching a +-- codec / container on first call, 2 the format module. variant: the module has variant(r). + + @@ -1571,6 +1608,7 @@ local list= { mime = { "application/x-navi-animation" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Riff" }, caps = { decode = true, encode = true, alpha = true, animation = true, frames = true }, + sniff = 0, load = function() return __include("image/ani") end, @@ -1583,6 +1621,7 @@ local list= { mime = { "image/x-build-art" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Pixels", "codecs/image/Quantize" }, caps = { decode = true, encode = true, alpha = true, palette = true, frames = true, depths = { 8 } }, + sniff = 0, load = function() return __include("image/art") end, @@ -1595,6 +1634,7 @@ local list= { mime = { "image/x-blp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Jpeg", "codecs/image/Bcn" }, caps = { decode = true, encode = true, alpha = true, variants = { "blp1", "blp2" }, compressions = { "jpeg", "palette", "dxt1", "dxt3", "dxt5", "bgra" } }, + sniff = 0, load = function() return __include("image/blp") end, @@ -1607,6 +1647,7 @@ local list= { mime = { "image/bmp", "image/x-bmp", "image/x-ms-bmp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, depths = { 1, 2, 4, 8, 16, 24, 32 }, rle = true }, + sniff = 0, load = function() return __include("image/bmp") end, @@ -1619,6 +1660,7 @@ local list= { mime = { "image/vnd-ms.dds", "image/x-dds" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/image/Bcn", "codecs/image/Texel", "codecs/image/Texture" }, caps = { decode = true, encode = true, alpha = true, float = true, mipmaps = true, cubemap = true, compressed = { "bc1", "bc2", "bc3", "bc4", "bc5", "bc6h", "bc7" } }, + sniff = 0, load = function() return __include("image/dds") end, @@ -1631,6 +1673,7 @@ local list= { mime = { "image/x-exr", "image/aces" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/image/Half", "codecs/compress/Deflate" }, caps = { decode = true, encode = true, alpha = true, float = true, hdr = true, depths = { 16, 32 }, multipart = true, tiled = true }, + sniff = 0, load = function() return __include("image/exr") end, @@ -1643,6 +1686,7 @@ local list= { mime = { "image/gif" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Lzw", "codecs/image/Quantize", "Types" }, caps = { decode = true, encode = true, animation = true, alpha = true, palette = true, depths = { 1, 2, 4, 8 } }, + sniff = 0, load = function() return __include("image/gif") end, @@ -1655,6 +1699,7 @@ local list= { mime = { "image/vnd.radiance", "image/x-hdr" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = false, float = true, depths = { 32 } }, + sniff = 0, load = function() return __include("image/hdr") end, @@ -1667,6 +1712,7 @@ local list= { mime = { "image/icns", "image/x-icns" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "containers/Chunks" }, caps = { decode = true, encode = true, alpha = true, frames = true, depths = { 1, 24, 32 } }, + sniff = 0, load = function() return __include("image/icns") end, @@ -1679,6 +1725,7 @@ local list= { mime = { "image/vnd.microsoft.icon", "image/x-icon" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, frames = true, depths = { 1, 4, 8, 16, 24, 32 } }, + sniff = 0, load = function() return __include("image/ico") end, @@ -1691,6 +1738,7 @@ local list= { mime = { "image/x-ilbm", "image/x-iff" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks", "codecs/compress/PackBits", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 1, 2, 3, 4, 5, 6, 7, 8, 24, 32 } }, + sniff = 0, load = function() return __include("image/ilbm") end, @@ -1703,6 +1751,7 @@ local list= { mime = { "image/jpeg" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Jpeg" }, caps = { decode = true, encode = true, lossy = true, alpha = false, depths = { 8, 12 }, progressive = true, arithmetic = true }, + sniff = 0, load = function() return __include("image/jpeg") end, @@ -1715,6 +1764,7 @@ local list= { mime = { "image/ktx2", "image/ktx" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/compress/Deflate", "codecs/compress/Zstd", "codecs/image/Texel", "codecs/image/Texture" }, caps = { decode = true, encode = true, alpha = true, float = true, mipmaps = true, cubemap = true, compressed = { "bc1", "bc2", "bc3", "bc4", "bc5", "bc6h", "bc7", "etc1", "etc2", "eac" } }, + sniff = 0, load = function() return __include("image/ktx") end, @@ -1727,6 +1777,7 @@ local list= { mime = { "image/x-quake-lmp" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Pixels", "codecs/image/Miptex" }, caps = { decode = true, encode = true, alpha = true, depths = { 8 }, variants = { "qpic", "palette", "colormap" } }, + sniff = 0, load = function() return __include("image/lmp") end, @@ -1739,6 +1790,7 @@ local list= { mime = { "image/vnd.zbrush.pcx", "image/x-pcx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 1, 2, 4, 8, 24, 32 } }, + sniff = 0, load = function() return __include("image/pcx") end, @@ -1751,6 +1803,7 @@ local list= { mime = { "image/png", "image/apng" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "codecs/compress/Deflate", "Types", "containers/Chunks" }, caps = { decode = true, encode = true, animation = true, alpha = true, depths = { 1, 2, 4, 8, 16 } }, + sniff = 0, load = function() return __include("image/png") end, @@ -1763,6 +1816,7 @@ local list= { mime = { "image/x-portable-anymap", "image/x-portable-bitmap", "image/x-portable-graymap", "image/x-portable-pixmap", "image/x-portable-arbitrarymap", "image/x-portable-floatmap" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = true, depths = { 1, 8, 16, 32 }, float = true }, + sniff = 0, load = function() return __include("image/pnm") end, @@ -1775,6 +1829,7 @@ local list= { mime = { "image/qoi", "image/x-qoi" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = true, depths = { 8 } }, + sniff = 0, load = function() return __include("image/qoi") end, @@ -1787,6 +1842,7 @@ local list= { mime = { "image/sgi", "image/x-rgb" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types" }, caps = { decode = true, encode = true, alpha = true, depths = { 8, 16 } }, + sniff = 0, load = function() return __include("image/sgi") end, @@ -1799,6 +1855,7 @@ local list= { mime = { "image/x-quake-sprite" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Pixels", "codecs/image/Miptex" }, caps = { decode = true, encode = true, alpha = true, animation = true, variants = { "quake", "halflife", "spr32" } }, + sniff = 0, load = function() return __include("image/spr") end, @@ -1811,6 +1868,7 @@ local list= { mime = { "image/x-sun-raster", "image/x-cmu-raster" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 1, 8, 24, 32 } }, + sniff = 0, load = function() return __include("image/sunras") end, @@ -1823,6 +1881,7 @@ local list= { mime = { "image/x-tga", "image/x-targa" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 8, 15, 16, 24, 32 } }, + sniff = 0, load = function() return __include("image/tga") end, @@ -1835,6 +1894,7 @@ local list= { mime = { "image/tiff" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate", "codecs/compress/Lzw", "codecs/compress/PackBits" }, caps = { decode = true, encode = true, alpha = true, pages = true, depths = { 1, 2, 4, 8, 16, 32 }, float = true }, + sniff = 0, load = function() return __include("image/tiff") end, @@ -1847,6 +1907,7 @@ local list= { mime = { "image/x-tim" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 4, 8, 16, 24 } }, + sniff = 0, load = function() return __include("image/tim") end, @@ -1859,6 +1920,7 @@ local list= { mime = { "image/x-vtf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Bcn", "codecs/image/Texel" }, caps = { decode = true, encode = false, alpha = true, animation = true, versions = { "7.0", "7.1", "7.2", "7.3", "7.4", "7.5" } }, + sniff = 0, load = function() return __include("image/vtf") end, @@ -1871,6 +1933,7 @@ local list= { mime = { "image/webp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Vp8", "codecs/image/Vp8L", "containers/Riff" }, caps = { decode = true, encode = true, animation = true, alpha = true, lossy = true, lossless = true, depths = { 8 } }, + sniff = 0, load = function() return __include("image/webp") end, @@ -1883,6 +1946,7 @@ local list= { mime = { "image/x-xbitmap", "image/x-xbm" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types" }, caps = { decode = true, encode = true, depths = { 1 } }, + sniff = 0, load = function() return __include("image/xbm") end, @@ -1895,6 +1959,7 @@ local list= { mime = { "image/x-xpixmap", "image/x-xpm" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 8 } }, + sniff = 0, load = function() return __include("image/xpm") end, @@ -1907,6 +1972,7 @@ local list= { mime = { "audio/aac", "audio/aacp", "audio/x-aac" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Aac", "codecs/audio/Pcm", "codecs/audio/Stream" }, caps = { decode = true, encode = false, codecs = { "aac" }, streaming = true }, + sniff = 1, load = function() return __include("audio/aac") end, @@ -1919,6 +1985,7 @@ local list= { mime = { "audio/ac3", "audio/x-ac3" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/Ac3" }, caps = { decode = true, encode = false, codecs = { "ac3" }, channels = 6, streaming = true, lossy = true }, + sniff = 1, load = function() return __include("audio/ac3") end, @@ -1931,6 +1998,7 @@ local list= { mime = { "audio/x-adpcm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm", "codecs/audio/Adpcm/Decoder" }, caps = { decode = true, encode = true, streaming = true, lossy = true, headerless = true, codecs = { "ima", "ima_wav", "ms", "ima_qt", "psx" } }, + sniff = 0, load = function() return __include("audio/adpcm") end, @@ -1943,6 +2011,7 @@ local list= { mime = { "audio/x-adx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm", "codecs/audio/Adpcm/Decoder" }, caps = { decode = true, encode = true, streaming = true, lossy = true, loops = true, channels = 8 }, + sniff = 0, load = function() return __include("audio/adx") end, @@ -1955,6 +2024,7 @@ local list= { mime = { "audio/aiff", "audio/x-aiff" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm/Decoder", "containers/Chunks" }, caps = { decode = true, encode = true, streaming = true, depths = { 8, 16, 24, 32 }, float = true, lossy = false }, + sniff = 0, load = function() return __include("audio/aiff") end, @@ -1967,6 +2037,7 @@ local list= { mime = { "audio/ape", "audio/x-ape", "audio/x-monkeys-audio" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/ApeTag", "codecs/audio/Ape" }, caps = { decode = true, encode = false, streaming = true, seek = true, lossless = true, float = true, depths = { 8, 16, 24, 32 } }, + sniff = 0, load = function() return __include("audio/ape") end, @@ -1979,6 +2050,7 @@ local list= { mime = { "audio/basic", "audio/x-au" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm" }, caps = { decode = true, encode = true, streaming = true, depths = { 8, 16, 24, 32 }, float = true, lossy = false }, + sniff = 0, load = function() return __include("audio/au") end, @@ -1991,6 +2063,8 @@ local list= { mime = { "audio/x-brstm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm/Decoder" }, caps = { decode = true, encode = false, streaming = true, lossy = true, loops = true, containers = { "RSTM", "CSTM", "FSTM" } }, + sniff = 0, + variant = true, load = function() return __include("audio/brstm") end, @@ -2003,6 +2077,7 @@ local list= { mime = { "audio/x-caf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Aac", "codecs/audio/Adpcm/Decoder", "codecs/audio/Alac", "codecs/audio/Pcm", "codecs/audio/Stream", "containers/Chunks" }, caps = { decode = true, encode = true, codecs = { "pcm", "alac", "aac", "ulaw", "alaw" }, encodeCodecs = { "pcm", "alac" }, tags = true, streaming = true }, + sniff = 0, load = function() return __include("audio/caf") end, @@ -2015,6 +2090,7 @@ local list= { mime = { "audio/flac", "audio/x-flac" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ogg", "codecs/audio/Pcm", "codecs/audio/VorbisComment", "codecs/audio/Flac/Frame", "codecs/audio/Flac/Encode" }, caps = { decode = true, encode = true, streaming = true, depths = { 4, 8, 12, 16, 20, 24, 32 }, ogg = true, seek = true }, + sniff = 0, load = function() return __include("audio/flac") end, @@ -2027,6 +2103,7 @@ local list= { mime = { "audio/mp4", "audio/x-m4a", "audio/m4a" }, deps = { "core/Err", "core/Bytes", "Types", "containers/IsoBmff", "codecs/audio/Aac", "codecs/audio/Alac", "codecs/audio/Pcm", "codecs/audio/Stream" }, caps = { decode = true, encode = true, codecs = { "aac", "alac" }, encodeCodecs = { "alac" }, tags = true, streaming = true }, + sniff = 1, load = function() return __include("audio/m4a") end, @@ -2039,6 +2116,7 @@ local list= { mime = { "audio/mpeg", "audio/mp3", "audio/mpa" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Resample", "codecs/audio/Mpa/Header", "codecs/audio/Mpa/Core", "codecs/audio/Mpa/Encode3", "codecs/audio/Mpa/Encode2" }, caps = { decode = true, encode = true, streaming = true, seek = true, layers = { 1, 2, 3 }, encodeLayers = { 2, 3 }, channels = 2 }, + sniff = 1, load = function() return __include("audio/mp3") end, @@ -2051,6 +2129,7 @@ local list= { mime = { "audio/x-musepack", "audio/musepack" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/ApeTag", "codecs/audio/Musepack" }, caps = { decode = true, encode = false, codecs = { "musepack" }, versions = { 7, 8 }, streaming = true, lossy = true }, + sniff = 1, load = function() return __include("audio/mpc") end, @@ -2063,6 +2142,7 @@ local list= { mime = { "audio/opus", "audio/ogg" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ogg", "codecs/entropy/RangeCoder/Decoder", "codecs/audio/Pcm", "codecs/audio/Resample", "codecs/audio/VorbisComment", "codecs/audio/Opus/CeltEncoder", "codecs/audio/Opus/Decoder", "codecs/audio/Opus/Packet", "codecs/audio/Opus/Celt", "codecs/audio/Opus/Silk" }, caps = { decode = true, encode = true, streaming = true, seek = true, lossy = true, channels = 255, rates = { 48000 }, encodeModes = { "celt" }, encodeChannels = 2 }, + sniff = 0, load = function() return __include("audio/opus") end, @@ -2075,6 +2155,7 @@ local list= { mime = { "audio/qoa" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/Qoa" }, caps = { decode = true, encode = true, streaming = true, lossy = true, seek = true, channels = 8 }, + sniff = 0, load = function() return __include("audio/qoa") end, @@ -2087,6 +2168,7 @@ local list= { mime = { "audio/x-tta", "audio/tta" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/ApeTag", "codecs/audio/Tta" }, caps = { decode = true, encode = false, streaming = true, seek = true, lossless = true, depths = { 8, 16, 24 } }, + sniff = 0, load = function() return __include("audio/tta") end, @@ -2099,6 +2181,7 @@ local list= { mime = { "audio/x-vag" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm", "codecs/audio/Adpcm/Decoder" }, caps = { decode = true, encode = true, streaming = true, lossy = true, loops = true, channels = 2 }, + sniff = 0, load = function() return __include("audio/vag") end, @@ -2111,6 +2194,7 @@ local list= { mime = { "audio/x-voc" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm" }, caps = { decode = true, encode = true, streaming = true, depths = { 8, 16 }, lossy = false }, + sniff = 0, load = function() return __include("audio/voc") end, @@ -2123,6 +2207,7 @@ local list= { mime = { "audio/ogg", "audio/vorbis" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ogg", "codecs/audio/Mdct", "codecs/audio/Pcm", "codecs/audio/VorbisComment", "codecs/audio/Vorbis/Tables", "codecs/audio/Vorbis/Setup", "codecs/audio/Vorbis/Packet" }, caps = { decode = true, encode = true, streaming = true, seek = true, lossy = true, channels = 255 }, + sniff = 0, load = function() return __include("audio/vorbis") end, @@ -2135,6 +2220,7 @@ local list= { mime = { "audio/wav", "audio/x-wav", "audio/wave", "audio/vnd.wave" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Riff", "codecs/audio/Pcm", "codecs/audio/Adpcm" }, caps = { decode = true, encode = true, streaming = true, depths = { 8, 16, 24, 32 }, float = true, rf64 = true }, + sniff = 1, load = function() return __include("audio/wav") end, @@ -2147,6 +2233,7 @@ local list= { mime = { "audio/x-wavpack", "audio/wavpack" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/ApeTag", "codecs/audio/WavPack" }, caps = { decode = true, encode = false, streaming = true, seek = true, lossless = true, hybrid = true, float = true, depths = { 8, 12, 16, 20, 24, 32 } }, + sniff = 0, load = function() return __include("audio/wavpack") end, @@ -2159,6 +2246,7 @@ local list= { mime = { "video/x-msvideo", "video/avi" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Avi", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, video = { "mjpeg", "mpeg1", "mpeg2", "rawvideo" }, audio = true, odml = true }, + sniff = 0, load = function() return __include("video/avi") end, @@ -2171,6 +2259,7 @@ local list= { mime = { "video/x-fli", "video/fli", "video/x-flc" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video" }, caps = { decode = true, encode = false, streaming = true, video = { "flic" }, depths = { 8, 15, 16, 24 } }, + sniff = 0, load = function() return __include("video/fli") end, @@ -2183,6 +2272,7 @@ local list= { mime = { "video/x-flv", "video/flv" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source", "codecs/video/H263", "codecs/video/H264", "codecs/audio/Aac" }, caps = { decode = true, encode = true, streaming = true, remux = true, video = { "flv1", "h264" }, audio = true, metadata = true }, + sniff = 0, load = function() return __include("video/flv") end, @@ -2195,6 +2285,7 @@ local list= { mime = { "video/h264" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source", "codecs/video/H264" }, caps = { decode = true, encode = true, streaming = true, video = { "h264" }, depths = { 8 } }, + sniff = 0, load = function() return __include("video/h264") end, @@ -2207,6 +2298,8 @@ local list= { mime = { "video/x-matroska", "video/webm", "audio/x-matroska", "audio/webm" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ebml", "containers/Demux", "containers/Avi", "containers/IsoBmff/QtPalette", "codecs/compress/Deflate", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, remux = true, video = { "vp8", "mjpeg", "mpeg1", "mpeg2", "theora", "rawvideo" }, audio = true, subtitles = true }, + sniff = 0, + variant = true, load = function() return __include("video/mkv") end, @@ -2219,6 +2312,7 @@ local list= { mime = { "video/mp4", "video/quicktime", "video/3gpp" }, deps = { "core/Err", "core/Bytes", "Types", "containers/IsoBmff", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, remux = true, video = { "mjpeg", "mpeg1", "mpeg2", "h264" }, audio = true, fragments = true }, + sniff = 1, load = function() return __include("video/mp4") end, @@ -2231,6 +2325,7 @@ local list= { mime = { "video/mpeg" }, deps = { "core/Err", "core/Bytes", "Types", "containers/MpegPs", "containers/MpegEs", "containers/Demux", "codecs/video/Video" }, caps = { decode = true, encode = false, streaming = true, video = { "mpeg1", "mpeg2" }, audio = true }, + sniff = 0, load = function() return __include("video/mpegps") end, @@ -2243,6 +2338,7 @@ local list= { mime = { "video/mp2t" }, deps = { "core/Err", "core/Bytes", "Types", "containers/MpegTs", "containers/MpegEs", "containers/Demux", "codecs/video/Video" }, caps = { decode = true, encode = false, streaming = true, video = { "mpeg1", "mpeg2", "h264" }, audio = true }, + sniff = 0, load = function() return __include("video/mpegts") end, @@ -2255,6 +2351,7 @@ local list= { mime = { "video/ogg" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ogg", "containers/Demux", "containers/AudioWrap", "codecs/video/Theora", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, remux = true, video = { "theora" }, audio = true }, + sniff = 0, load = function() return __include("video/ogv") end, @@ -2267,6 +2364,7 @@ local list= { mime = { "video/vnd.radgamettools.smacker" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video", "codecs/audio/Stream", "codecs/video/Legacy/Smacker" }, caps = { decode = true, encode = false, streaming = true, video = { "smackvid" }, audio = { "smackaudio", "pcm_u8", "pcm_s16le" } }, + sniff = 0, load = function() return __include("video/smk") end, @@ -2279,6 +2377,7 @@ local list= { mime = { "video/x-yuv4mpeg" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, video = { "rawvideo" }, depths = { 8, 10, 12, 16 } }, + sniff = 0, load = function() return __include("video/y4m") end, @@ -2291,6 +2390,7 @@ local list= { mime = { "application/x-3ds", "image/x-3ds" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Mat4", "codecs/model/MeshFlatten", "codecs/model/Sampler" }, caps = { decode = true, encode = true, materials = true, textures = true, animation = true, cameras = true, lights = true, instancing = true }, + sniff = 0, load = function() return __include("model/3ds") end, @@ -2303,6 +2403,7 @@ local list= { mime = { "model/3mf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Xml", "containers/Zip" }, caps = { decode = true, encode = true, materials = true, vertexColors = true, textures = true, units = true }, + sniff = 0, load = function() return __include("model/3mf") end, @@ -2315,6 +2416,7 @@ local list= { mime = { "model/x-ase", "text/plain" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Text", "codecs/model/Mat4" }, caps = { decode = true, encode = true, text = true, materials = true, cameras = true, lights = true, vertexColors = true }, + sniff = 1, load = function() return __include("model/ase") end, @@ -2327,6 +2429,7 @@ local list= { mime = { "model/x-b3d" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks", "codecs/model/Mat4" }, caps = { decode = true, encode = false, materials = true, textures = true, skins = true, animation = true, colors = true }, + sniff = 0, load = function() return __include("model/b3d") end, @@ -2339,6 +2442,7 @@ local list= { mime = { "application/x-blender" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Blend", "codecs/compress/Deflate", "codecs/compress/Zstd", "codecs/model/Mat4", "codecs/model/Rig", "codecs/model/Polygon" }, caps = { decode = true, encode = false, materials = true, textures = true, animation = true, skins = true, morphTargets = true, cameras = true, lights = true, polygons = true, compressed = true }, + sniff = 1, load = function() return __include("model/blend") end, @@ -2351,6 +2455,7 @@ local list= { mime = { "model/x-bsp" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Pixels", "codecs/image/Miptex", "codecs/model/Patch" }, caps = { decode = true, encode = false, variants = { "quake", "bsp2", "2psb", "halflife", "quake2", "quake3" }, lightmaps = true, collision = true, visibility = true }, + sniff = 0, load = function() return __include("model/bsp") end, @@ -2363,6 +2468,7 @@ local list= { mime = { "application/x-build-map" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Polygon" }, caps = { decode = true, encode = true, sprites = true, slopes = true }, + sniff = 0, load = function() return __include("model/buildmap") end, @@ -2375,6 +2481,7 @@ local list= { mime = { "text/x-doom3-map" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/Brush", "codecs/model/Patch", "codecs/model/Mat4", "codecs/text/Lexer" }, caps = { decode = true, encode = false, patches = true, variants = { "doom3", "quake4" } }, + sniff = 0, load = function() return __include("model/d3map") end, @@ -2387,6 +2494,7 @@ local list= { mime = { "model/vnd.collada+xml", "model/vnd.collada+zip" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Xml", "core/Base64", "containers/Zip", "codecs/model/Mat4" }, caps = { decode = true, encode = true, materials = true, polygons = true, skins = true, morphTargets = true, animation = true, cameras = true, lights = true, zae = true }, + sniff = 0, load = function() return __include("model/dae") end, @@ -2399,6 +2507,7 @@ local list= { mime = { "application/vnd.autodesk.fbx", "model/fbx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate", "core/Base64", "codecs/model/Mat4" }, caps = { decode = true, encode = true, binary = true, ascii = true, materials = true, animation = true, skins = true, morphTargets = true, cameras = true, lights = true, polygons = true }, + sniff = 2, load = function() return __include("model/fbx") end, @@ -2411,6 +2520,7 @@ local list= { mime = { "model/gltf+json", "model/gltf-binary" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Json", "core/Base64", "core/Sniff", "codecs/model/Draco" }, caps = { decode = true, encode = true, binary = true, materials = true, animation = true, skins = true, morphTargets = true, cameras = true, lights = true, draco = true }, + sniff = 0, load = function() return __include("model/gltf") end, @@ -2423,6 +2533,7 @@ local list= { mime = { "application/x-godot-scene" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/GodotVariant", "codecs/model/Mat4" }, caps = { decode = true, encode = true, text = true, materials = true, cameras = true, lights = true, instances = true }, + sniff = 0, load = function() return __include("model/godot") end, @@ -2435,6 +2546,7 @@ local list= { mime = { "model/x-iqm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Mat4", "codecs/model/Rig", "codecs/model/Sampler" }, caps = { decode = true, encode = true, materials = true, skins = true, animation = true, vertexColors = true }, + sniff = 0, load = function() return __include("model/iqm") end, @@ -2447,6 +2559,7 @@ local list= { mime = { "application/x-ldraw", "application/x-multi-part-ldraw" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types" }, caps = { decode = true, encode = false, materials = true, lines = true, instancing = true }, + sniff = 0, load = function() return __include("model/ldraw") end, @@ -2459,6 +2572,7 @@ local list= { mime = { "image/x-lwo", "model/x-lwo" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks" }, caps = { decode = true, encode = false, materials = true, polygons = true, vertexColors = true, morphTargets = true }, + sniff = 0, load = function() return __include("model/lwo") end, @@ -2471,6 +2585,7 @@ local list= { mime = { "text/x-quake-map" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Miptex", "codecs/model/Brush", "codecs/model/Patch" }, caps = { decode = true, encode = true, variants = { "quake", "valve220", "quake2", "quake3" }, patches = true }, + sniff = 0, load = function() return __include("model/map") end, @@ -2483,6 +2598,7 @@ local list= { mime = { "application/x-minecraft-region" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate", "codecs/text/Nbt", "codecs/model/Minecraft", "codecs/compress/Lz4" }, caps = { decode = true, encode = false, voxels = true, blocks = true }, + sniff = 0, load = function() return __include("model/mca") end, @@ -2495,6 +2611,7 @@ local list= { mime = { "model/x-md2" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/Rig" }, caps = { decode = true, encode = false, morph = true, animation = true }, + sniff = 0, load = function() return __include("model/md2") end, @@ -2507,6 +2624,7 @@ local list= { mime = { "model/x-md3" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/Mat4", "codecs/model/Rig" }, caps = { decode = true, encode = false, morph = true, animation = true, tags = true }, + sniff = 0, load = function() return __include("model/md3") end, @@ -2519,6 +2637,7 @@ local list= { mime = { "model/x-md5mesh", "model/x-md5anim" }, deps = { "core/Err", "core/Bytes", "core/Input", "core/Sniff", "Types", "codecs/model/Rig" }, caps = { decode = true, encode = false, skins = true, animation = true }, + sniff = 0, load = function() return __include("model/md5") end, @@ -2531,6 +2650,7 @@ local list= { mime = { "model/x-mdl" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Pixels", "codecs/model/Mat4", "codecs/model/Rig", "codecs/model/SourceAnim" }, caps = { decode = true, encode = false, variants = { "quake", "halflife" }, morph = true, skins = true, animation = true }, + sniff = 0, load = function() return __include("model/mdl") end, @@ -2543,6 +2663,7 @@ local list= { mime = { "application/x-ms3d" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Mat4", "codecs/model/MeshFlatten" }, caps = { decode = true, encode = true, materials = true, skins = true, animation = true }, + sniff = 1, load = function() return __include("model/ms3d") end, @@ -2555,6 +2676,7 @@ local list= { mime = { "model/obj" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, materials = true, polygons = true, vertexColors = true }, + sniff = 0, load = function() return __include("model/obj") end, @@ -2567,6 +2689,7 @@ local list= { mime = { "model/off", "text/plain" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/MeshFlatten" }, caps = { decode = true, encode = true, polygons = true, points = true, colors = true, binary = false }, + sniff = 0, load = function() return __include("model/off") end, @@ -2579,6 +2702,7 @@ local list= { mime = { "model/ply", "application/ply" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/MeshFlatten" }, caps = { decode = true, encode = true, ascii = true, binary = true, polygons = true, points = true, colors = true }, + sniff = 0, load = function() return __include("model/ply") end, @@ -2591,6 +2715,7 @@ local list= { mime = { "model/x-pmx", "model/x-pmd" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Text" }, caps = { decode = true, encode = false, materials = true, skins = true, morphTargets = true, pmd = true }, + sniff = 0, load = function() return __include("model/pmx") end, @@ -2603,6 +2728,7 @@ local list= { mime = { "model/x-doom3-proc" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/Lexer" }, caps = { decode = true, encode = false, portals = true }, + sniff = 0, load = function() return __include("model/proc") end, @@ -2615,6 +2741,7 @@ local list= { mime = { "model/x-qubicle" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, voxels = true, truecolor = true }, + sniff = 0, load = function() return __include("model/qb") end, @@ -2627,6 +2754,8 @@ local list= { mime = { "application/x-roblox-rbxm", "application/x-roblox-rbxl" }, deps = { "core/Err", "core/Bytes", "core/Md5", "codecs/compress/Lz4", "codecs/compress/Zstd", "codecs/model/Rbx", "codecs/model/Rbx/Binary" }, caps = { decode = true, encode = true, tree = true, compression = { "none", "lz4", "zstd" } }, + sniff = 0, + variant = true, load = function() return __include("model/rbxm") end, @@ -2639,6 +2768,8 @@ local list= { mime = { "application/x-roblox-rbxmx", "application/x-roblox-rbxlx" }, deps = { "core/Err", "core/Bytes", "core/Base64", "core/Md5", "codecs/text/Xml", "codecs/model/Rbx" }, caps = { decode = true, encode = true, tree = true }, + sniff = 0, + variant = true, load = function() return __include("model/rbxmx") end, @@ -2651,6 +2782,7 @@ local list= { mime = { "application/x-roblox-mesh" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Mat4", "codecs/model/MeshFlatten", "codecs/model/Draco" }, caps = { decode = true, encode = true, skinning = true, lods = true, versions = { "1.00", "1.01", "2.00", "3.00", "3.01", "4.00", "4.01", "5.00", "6.00", "7.00" } }, + sniff = 0, load = function() return __include("model/robloxmesh") end, @@ -2663,6 +2795,8 @@ local list= { mime = { "application/x-minecraft-schematic" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Nbt", "codecs/model/Minecraft" }, caps = { decode = true, encode = true, voxels = true, blocks = true, variants = { "schem", "schematic", "litematic" } }, + sniff = 1, + variant = true, load = function() return __include("model/schematic") end, @@ -2675,6 +2809,7 @@ local list= { mime = { "model/x-smd", "text/plain" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/Mat4", "codecs/model/MeshFlatten", "codecs/model/Rig" }, caps = { decode = true, encode = true, skins = true, animation = true }, + sniff = 0, load = function() return __include("model/smd") end, @@ -2687,6 +2822,7 @@ local list= { mime = { "model/x-source-mdl" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Half", "codecs/model/Mat4", "codecs/model/Rig", "codecs/model/SourceAnim", "codecs/text/KeyValues" }, caps = { decode = true, encode = false, skins = true, morph = true, animation = true, lods = true }, + sniff = 0, load = function() return __include("model/sourcemdl") end, @@ -2699,6 +2835,7 @@ local list= { mime = { "model/stl", "application/sla" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/MeshFlatten" }, caps = { decode = true, encode = true, ascii = true, binary = true, colors = true, indexed = false }, + sniff = 0, load = function() return __include("model/stl") end, @@ -2711,6 +2848,7 @@ local list= { mime = { "text/x-unreal-t3d" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/Text", "codecs/model/Brush" }, caps = { decode = true, encode = false, text = true, brushes = true, actors = true }, + sniff = 0, load = function() return __include("model/t3d") end, @@ -2723,6 +2861,7 @@ local list= { mime = { "text/x-udmf" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/DoomMap" }, caps = { decode = true, encode = false, maps = true }, + sniff = 0, load = function() return __include("model/udmf") end, @@ -2735,6 +2874,7 @@ local list= { mime = { "model/vnd.usda", "model/vnd.usdz+zip" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Zip", "codecs/model/Mat4" }, caps = { decode = true, encode = true, materials = true, animation = true, cameras = true, lights = true, polygons = true, vertexColors = true, usdz = "read", usdc = false }, + sniff = 0, load = function() return __include("model/usda") end, @@ -2747,6 +2887,7 @@ local list= { mime = { "model/x-vbsp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Lzma", "codecs/text/KeyValues", "codecs/model/Mat4", "codecs/model/Displacement", "containers/Zip", "containers/Archive" }, caps = { decode = true, encode = false, versions = { 19, 20, 21 }, displacements = true, staticProps = true, pak = true }, + sniff = 0, load = function() return __include("model/vbsp") end, @@ -2759,6 +2900,7 @@ local list= { mime = { "model/x-vmf" }, deps = { "core/Err", "core/Bytes", "core/Input", "core/Sniff", "Types", "codecs/text/KeyValues", "codecs/model/Brush", "codecs/model/Displacement", "codecs/model/Mat4" }, caps = { decode = true, encode = true, displacements = true, roundTrip = true }, + sniff = 0, load = function() return __include("model/vmf") end, @@ -2771,6 +2913,7 @@ local list= { mime = { "model/x-vox" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, voxels = true, sceneGraph = true, materials = true }, + sniff = 0, load = function() return __include("model/vox") end, @@ -2783,6 +2926,7 @@ local list= { mime = { "model/vrml", "x-world/x-vrml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Vrml" }, caps = { decode = true, encode = true, materials = true, polygons = true, animation = true, cameras = true, lights = true, lines = true, points = true }, + sniff = 0, load = function() return __include("model/vrml") end, @@ -2795,6 +2939,7 @@ local list= { mime = { "model/x-directx", "text/x-directx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate", "codecs/model/Mat4", "codecs/model/Rig" }, caps = { decode = true, encode = false, text = true, binary = true, compressed = true, materials = true, skins = true, animation = true, polygons = true, vertexColors = true }, + sniff = 0, load = function() return __include("model/x") end, @@ -2807,6 +2952,7 @@ local list= { mime = { "model/x3d+xml", "model/x3d-vrml", "model/x3d+fastinfoset" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Vrml" }, caps = { decode = true, encode = true, materials = true, polygons = true, animation = true, cameras = true, lights = true, lines = true, points = true, xml = true, classic = true }, + sniff = 0, load = function() return __include("model/x3d") end, @@ -2819,6 +2965,7 @@ local list= { mime = { "model/step", "application/step", "application/p21" }, deps = { "core/Err", "core/Bytes", "Types", "core/Sniff" }, caps = { decode = true, encode = true, complexEntities = true, sections = true, brep = "plugin", tessellate = "plugin" }, + sniff = 0, load = function() return __include("cad/step") end, @@ -2831,6 +2978,7 @@ local list= { mime = { "application/x-font-bdf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/font/Bitmap" }, caps = { decode = true, encode = true, bitmap = true }, + sniff = 0, load = function() return __include("font/bdf") end, @@ -2843,6 +2991,7 @@ local list= { mime = { "application/x-bmfont" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, bitmap = true, variants = { "text", "xml", "binary" }, extraFiles = true }, + sniff = 0, load = function() return __include("font/bmfont") end, @@ -2855,6 +3004,7 @@ local list= { mime = { "application/vnd.ms-fontobject" }, deps = { "core/Err", "core/Bytes", "codecs/text/Text", "codecs/font/TrueType" }, caps = { decode = true, encode = true, variants = { "1.0", "2.1", "2.2" } }, + sniff = 0, load = function() return __include("font/eot") end, @@ -2867,6 +3017,7 @@ local list= { mime = { "application/x-font-fnt" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Text", "codecs/font/Bitmap" }, caps = { decode = true, encode = false, bitmap = true, variants = { "fnt2", "fnt3", "ne", "pe" } }, + sniff = 0, load = function() return __include("font/fon") end, @@ -2879,6 +3030,7 @@ local list= { mime = { "application/x-hershey-font" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Raster" }, caps = { decode = true, encode = false, strokes = true }, + sniff = 0, load = function() return __include("font/hershey") end, @@ -2891,6 +3043,7 @@ local list= { mime = { "application/x-font-pcf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/font/Bitmap" }, caps = { decode = true, encode = false, bitmap = true }, + sniff = 0, load = function() return __include("font/pcf") end, @@ -2903,6 +3056,7 @@ local list= { mime = { "application/x-font-linux-psf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/font/Bitmap" }, caps = { decode = true, encode = true, bitmap = true, variants = { "psf1", "psf2" } }, + sniff = 0, load = function() return __include("font/psf") end, @@ -2915,6 +3069,7 @@ local list= { mime = { "font/ttf", "font/otf", "font/collection" }, deps = { "core/Err", "core/Bytes", "codecs/font/TrueType" }, caps = { decode = true, encode = false, outlines = { "truetype", "cff" }, collection = true, kerning = true }, + sniff = 0, load = function() return __include("font/ttf") end, @@ -2927,6 +3082,7 @@ local list= { mime = { "application/x-font-type1" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Raster", "codecs/font/GlyphNames" }, caps = { decode = true, encode = false, outlines = { "type1" }, variants = { "pfb", "pfa" } }, + sniff = 0, load = function() return __include("font/type1") end, @@ -2939,6 +3095,7 @@ local list= { mime = { "font/woff" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Deflate", "codecs/font/TrueType" }, caps = { decode = true, encode = false, outlines = { "truetype", "cff" } }, + sniff = 0, load = function() return __include("font/woff") end, @@ -2951,6 +3108,7 @@ local list= { mime = { "font/woff2" }, deps = { "core/Err", "core/Bytes", "codecs/font/TrueType", "codecs/compress/Brotli" }, caps = { decode = true, encode = false, outlines = { "truetype", "cff" }, transforms = { "glyf", "loca", "hmtx" } }, + sniff = 0, load = function() return __include("font/woff2") end, @@ -2963,6 +3121,7 @@ local list= { mime = { "application/x-7z-compressed" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "Types", "codecs/compress/Lzma", "codecs/compress/Deflate", "codecs/compress/Bzip2", "codecs/compress/Zstd", "containers/Archive", "codecs/text/Text" }, caps = { decode = true, encode = false, methods = { "copy", "lzma", "lzma2", "deflate", "bcj", "delta" }, encrypted = false }, + sniff = 0, load = function() return __include("archive/7z") end, @@ -2975,6 +3134,7 @@ local list= { mime = { "application/x-amiga-disk-format" }, deps = { "core/Err", "core/Bytes", "containers/Archive" }, caps = { decode = true, encode = false, variants = { "ofs", "ffs" } }, + sniff = 0, load = function() return __include("archive/adf") end, @@ -2987,6 +3147,7 @@ local list= { mime = { "application/applefile", "multipart/appledouble" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/MacFile" }, caps = { decode = true, encode = true, forks = true, variants = { "applesingle", "appledouble" } }, + sniff = 0, load = function() return __include("archive/applesingle") end, @@ -2999,6 +3160,7 @@ local list= { mime = { "application/x-archive", "application/vnd.debian.binary-package" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Deflate", "codecs/compress/Lzma", "codecs/compress/Zstd", "codecs/compress/Bzip2", "containers/Archive", "containers/Tar" }, caps = { decode = true, encode = true, variants = { "gnu", "bsd" }, deb = true }, + sniff = 0, load = function() return __include("archive/ar") end, @@ -3011,6 +3173,7 @@ local list= { mime = { "application/x-arj" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "codecs/compress/Lzh", "containers/Archive" }, caps = { decode = true, encode = false, methods = { "store", "arj1", "arj2", "arj3", "arj4" } }, + sniff = 0, load = function() return __include("archive/arj") end, @@ -3023,6 +3186,7 @@ local list= { mime = { "application/mac-binhex40" }, deps = { "core/Err", "core/Bytes", "core/Crc16", "containers/Archive", "containers/MacFile" }, caps = { decode = true, encode = true, forks = true }, + sniff = 0, load = function() return __include("archive/binhex") end, @@ -3035,6 +3199,7 @@ local list= { mime = { "application/x-brotli" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Brotli", "containers/Archive" }, caps = { decode = true, encode = false, stream = true }, + sniff = 1, load = function() return __include("archive/br") end, @@ -3047,6 +3212,7 @@ local list= { mime = { "application/x-bzip2" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "codecs/compress/Bzip2" }, caps = { decode = true, encode = false, stream = true }, + sniff = 0, load = function() return __include("archive/bz2") end, @@ -3059,6 +3225,7 @@ local list= { mime = { "application/vnd.ms-cab-compressed" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Deflate", "codecs/compress/Lzx", "codecs/compress/Quantum", "containers/Archive" }, caps = { decode = true, encode = true, methods = { "store", "mszip", "lzx", "quantum" } }, + sniff = 0, load = function() return __include("archive/cab") end, @@ -3071,6 +3238,7 @@ local list= { mime = { "application/x-cpio" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/Cpio" }, caps = { decode = true, encode = true, variants = { "newc", "crc", "odc", "bin" } }, + sniff = 0, load = function() return __include("archive/cpio") end, @@ -3083,6 +3251,7 @@ local list= { mime = { "application/x-d64" }, deps = { "core/Err", "core/Bytes", "containers/Archive" }, caps = { decode = true, encode = true, variants = { "d64", "d71", "d81" } }, + sniff = 0, load = function() return __include("archive/d64") end, @@ -3095,6 +3264,7 @@ local list= { mime = { "application/x-fat-image" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/Fat" }, caps = { decode = true, encode = true, variants = { "fat12", "fat16", "fat32" } }, + sniff = 1, load = function() return __include("archive/fat") end, @@ -3107,6 +3277,7 @@ local list= { mime = { "application/x-build-grp" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "containers/Archive" }, caps = { decode = true, encode = true }, + sniff = 0, load = function() return __include("archive/grp") end, @@ -3119,6 +3290,7 @@ local list= { mime = { "application/gzip" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "codecs/compress/Deflate", "containers/Archive", "containers/Tar" }, caps = { decode = true, encode = true, stream = true }, + sniff = 0, load = function() return __include("archive/gzip") end, @@ -3131,6 +3303,7 @@ local list= { mime = { "application/x-iso9660-image" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/Iso9660" }, caps = { decode = true, encode = false, extensions = { "joliet", "rockridge", "eltorito" } }, + sniff = 0, load = function() return __include("archive/iso") end, @@ -3143,6 +3316,7 @@ local list= { mime = { "application/x-lzh-compressed" }, deps = { "core/Err", "core/Bytes", "core/Crc16", "codecs/compress/Lzh", "containers/Archive" }, caps = { decode = true, encode = true, methods = { "lh0", "lh1", "lh4", "lh5", "lh6", "lh7", "lhx", "lzs", "lz5", "lz4", "lhd" } }, + sniff = 0, load = function() return __include("archive/lha") end, @@ -3155,6 +3329,7 @@ local list= { mime = { "application/x-lz4" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Lz4", "codecs/compress/Xxh32", "containers/Archive" }, caps = { decode = true, encode = true, stream = true, legacy = true }, + sniff = 0, load = function() return __include("archive/lz4") end, @@ -3167,6 +3342,7 @@ local list= { mime = { "application/x-macbinary" }, deps = { "core/Err", "core/Bytes", "core/Crc16", "containers/Archive", "containers/MacFile" }, caps = { decode = true, encode = true, forks = true, variants = { "I", "II", "III" } }, + sniff = 0, load = function() return __include("archive/macbinary") end, @@ -3179,6 +3355,7 @@ local list= { mime = { "application/x-mpq" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "codecs/compress/Deflate", "codecs/compress/Bzip2", "codecs/compress/Lzma", "codecs/compress/Explode" }, caps = { decode = true, encode = false, versions = { 1, 2, 3, 4 }, methods = { "zlib", "implode", "bzip2", "lzma", "sparse" }, encryption = true }, + sniff = 0, load = function() return __include("archive/mpq") end, @@ -3191,6 +3368,7 @@ local list= { mime = { "application/x-pak" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "containers/Archive" }, caps = { decode = true, encode = true, variants = { "quake", "sin" } }, + sniff = 0, load = function() return __include("archive/pak") end, @@ -3203,6 +3381,7 @@ local list= { mime = { "application/x-rpm" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Deflate", "codecs/compress/Lzma", "codecs/compress/Zstd", "codecs/compress/Bzip2", "containers/Archive", "containers/Cpio" }, caps = { decode = true, encode = false, compressors = { "gzip", "bzip2", "xz", "lzma", "zstd" } }, + sniff = 0, load = function() return __include("archive/rpm") end, @@ -3215,6 +3394,7 @@ local list= { mime = { "application/x-tar" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/Tar" }, caps = { decode = true, encode = true, variants = { "ustar", "pax", "gnu" } }, + sniff = 1, load = function() return __include("archive/tar") end, @@ -3227,6 +3407,7 @@ local list= { mime = { "application/x-unitypackage" }, deps = { "core/Err", "core/Bytes", "core/Md5", "codecs/compress/Deflate", "containers/Archive", "containers/Tar" }, caps = { decode = true, encode = true }, + sniff = 1, load = function() return __include("archive/unitypackage") end, @@ -3239,6 +3420,7 @@ local list= { mime = { "text/x-uuencode" }, deps = { "core/Err", "core/Bytes", "core/Base64", "containers/Archive" }, caps = { decode = true, encode = true, variants = { "uu", "xx", "base64" } }, + sniff = 0, load = function() return __include("archive/uu") end, @@ -3251,6 +3433,7 @@ local list= { mime = { "application/x-vpk" }, deps = { "core/Err", "core/Bytes", "core/Input", "core/Crc32", "core/Md5", "containers/Archive" }, caps = { decode = true, encode = true, versions = { 1, 2 }, multipart = true }, + sniff = 0, load = function() return __include("archive/vpk") end, @@ -3263,6 +3446,7 @@ local list= { mime = { "application/x-wolf3d-vswap" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Archive", "codecs/image/Pixels" }, caps = { decode = true, encode = false, images = true, sounds = true }, + sniff = 0, load = function() return __include("archive/vswap") end, @@ -3275,6 +3459,7 @@ local list= { mime = { "application/x-doom" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Archive", "codecs/image/Pixels", "codecs/model/DoomMap" }, caps = { decode = true, encode = true, images = true, maps = true, variants = { "iwad", "pwad" } }, + sniff = 0, load = function() return __include("archive/wad") end, @@ -3287,6 +3472,7 @@ local list= { mime = { "application/x-quake-wad" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "containers/Archive", "codecs/image/Pixels", "codecs/image/Miptex" }, caps = { decode = true, encode = true, images = true, variants = { "wad2", "wad3" } }, + sniff = 0, load = function() return __include("archive/wad2") end, @@ -3299,6 +3485,7 @@ local list= { mime = { "application/x-xz", "application/x-lzma" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Lzma", "containers/Archive" }, caps = { decode = true, encode = false, stream = true, filters = { "lzma2", "lzma", "delta", "x86", "powerpc", "arm", "armthumb", "sparc", "arm64" } }, + sniff = 0, load = function() return __include("archive/xz") end, @@ -3311,6 +3498,7 @@ local list= { mime = { "application/x-yenc" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "containers/Archive" }, caps = { decode = true, encode = true, multipart = true }, + sniff = 0, load = function() return __include("archive/yenc") end, @@ -3323,6 +3511,7 @@ local list= { mime = { "application/x-compress" }, deps = { "core/Err", "core/Bytes", "codecs/compress/UnixCompress", "containers/Archive" }, caps = { decode = true, encode = true, stream = true, bits = { 9, 16 } }, + sniff = 0, load = function() return __include("archive/z") end, @@ -3335,6 +3524,7 @@ local list= { mime = { "application/zip", "application/x-zip-compressed" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Zip" }, caps = { decode = true, encode = true, methods = { "store", "deflate" }, zip64 = true }, + sniff = 0, load = function() return __include("archive/zip") end, @@ -3347,6 +3537,7 @@ local list= { mime = { "application/x-zoo" }, deps = { "core/Err", "core/Bytes", "core/Crc16", "codecs/compress/Lzw", "codecs/compress/Lzh", "containers/Archive" }, caps = { decode = true, encode = false, methods = { "store", "lzw", "lzh" } }, + sniff = 0, load = function() return __include("archive/zoo") end, @@ -3359,6 +3550,7 @@ local list= { mime = { "application/zstd" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Zstd", "containers/Archive" }, caps = { decode = true, encode = false, stream = true }, + sniff = 1, load = function() return __include("archive/zst") end, @@ -3371,6 +3563,7 @@ local list= { mime = { "application/cbor", "application/cbor-seq" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, binary = true, ordered = true, tags = true }, + sniff = 0, load = function() return __include("data/cbor") end, @@ -3383,6 +3576,7 @@ local list= { mime = { "text/csv", "text/tab-separated-values" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Json", "core/Sniff" }, caps = { decode = true, encode = true, header = true }, + sniff = 0, load = function() return __include("data/csv") end, @@ -3395,6 +3589,7 @@ local list= { mime = { "text/plain" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Json", "core/Sniff" }, caps = { decode = true, encode = true, ordered = true }, + sniff = 0, load = function() return __include("data/ini") end, @@ -3407,6 +3602,7 @@ local list= { mime = { "application/json", "application/x-ndjson" }, deps = { "core/Err", "core/Bytes", "codecs/text/Json", "core/Sniff" }, caps = { decode = true, encode = true, ordered = true, streaming = true }, + sniff = 0, load = function() return __include("data/json") end, @@ -3419,6 +3615,7 @@ local list= { mime = { "application/msgpack", "application/x-msgpack" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, binary = true, ordered = true }, + sniff = 0, load = function() return __include("data/msgpack") end, @@ -3431,6 +3628,7 @@ local list= { mime = { "application/x-minecraft-nbt" }, deps = { "core/Err", "core/Bytes", "codecs/text/Nbt" }, caps = { decode = true, encode = true, binary = true, ordered = true, typed = true }, + sniff = 1, load = function() return __include("data/nbt") end, @@ -3443,6 +3641,7 @@ local list= { mime = { "application/x-plist", "application/x-bplist" }, deps = { "core/Err", "core/Bytes", "Types", "core/Base64", "codecs/text/Xml", "codecs/text/Json" }, caps = { decode = true, encode = true, binary = "read", ordered = true }, + sniff = 0, load = function() return __include("data/plist") end, @@ -3455,6 +3654,7 @@ local list= { mime = { "text/x-quake3-shader" }, deps = { "core/Err", "core/Bytes" }, caps = { decode = true, encode = true }, + sniff = 0, load = function() return __include("data/q3shader") end, @@ -3467,6 +3667,7 @@ local list= { mime = { "text/x-quake3-skin" }, deps = { "core/Err", "core/Bytes" }, caps = { decode = true, encode = true }, + sniff = 0, load = function() return __include("data/q3skin") end, @@ -3479,6 +3680,7 @@ local list= { mime = { "text/x-minecraft-snbt" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "codecs/text/Nbt" }, caps = { decode = true, encode = true, ordered = true, typed = true }, + sniff = 0, load = function() return __include("data/snbt") end, @@ -3491,6 +3693,7 @@ local list= { mime = { "application/toml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Json", "codecs/text/Text" }, caps = { decode = true, encode = true, ordered = true, dates = true }, + sniff = 0, load = function() return __include("data/toml") end, @@ -3503,6 +3706,7 @@ local list= { mime = { "application/x-godot-resource" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/GodotVariant" }, caps = { decode = true, encode = true, ordered = true }, + sniff = 0, load = function() return __include("data/tres") end, @@ -3515,6 +3719,7 @@ local list= { mime = { "text/x-vdf" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "codecs/text/KeyValues" }, caps = { decode = true, encode = true, ordered = true, binary = true }, + sniff = 1, load = function() return __include("data/vdf") end, @@ -3527,6 +3732,7 @@ local list= { mime = { "application/xml", "text/xml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Xml", "core/Sniff" }, caps = { decode = true, encode = true, namespaces = true, streaming = true }, + sniff = 0, load = function() return __include("data/xml") end, @@ -3539,6 +3745,7 @@ local list= { mime = { "application/yaml", "application/x-yaml", "text/yaml" }, deps = { "core/Err", "core/Bytes", "Types", "core/Base64", "codecs/text/Text" }, caps = { decode = true, encode = true, ordered = true, multiDocument = true, anchors = true }, + sniff = 0, load = function() return __include("data/yaml") end, @@ -3551,6 +3758,7 @@ local list= { mime = { "application/x-wolf3d-gamemaps" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types" }, caps = { decode = true, encode = false, tilemap = true }, + sniff = 0, load = function() return __include("vector/gamemaps") end, @@ -3563,6 +3771,7 @@ local list= { mime = { "application/x-ldtk+json" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/Json" }, caps = { decode = true, encode = true, levels = true, worlds = true, intGrid = true, entities = true }, + sniff = 0, load = function() return __include("vector/ldtk") end, @@ -3575,6 +3784,7 @@ local list= { mime = { "application/x-ogmo+json" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "core/Base64", "Types", "codecs/text/Json" }, caps = { decode = true, encode = true, projects = true, entities = true, decals = true }, + sniff = 0, load = function() return __include("vector/ogmo") end, @@ -3587,6 +3797,7 @@ local list= { mime = { "image/svg+xml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Xml", "codecs/image/Raster", "codecs/image/Blend", "core/Sniff" }, caps = { decode = true, encode = true, rasterize = true, text = false }, + sniff = 0, load = function() return __include("vector/svg") end, @@ -3599,6 +3810,7 @@ local list= { mime = { "application/x-tiled-tmx", "application/x-tiled-tmj" }, deps = { "core/Err", "core/Bytes", "core/Base64", "Types", "codecs/text/Xml", "codecs/text/Json", "codecs/compress/Deflate", "core/Sniff" }, caps = { decode = true, encode = true, tilesets = true, infinite = true }, + sniff = 0, load = function() return __include("vector/tiled") end, @@ -3611,6 +3823,7 @@ local list= { mime = { "image/x-aseprite" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate" }, caps = { decode = true, encode = true, layers = true, groups = true, animation = true, depths = { 8, 16, 32 } }, + sniff = 0, load = function() return __include("layered/aseprite") end, @@ -3623,6 +3836,7 @@ local list= { mime = { "image/openraster" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Zip", "codecs/text/Xml", "codecs/image/Blend" }, caps = { decode = true, encode = true, layers = true, groups = true, depths = { 8 } }, + sniff = 0, load = function() return __include("layered/ora") end, @@ -3635,6 +3849,7 @@ local list= { mime = { "image/vnd.adobe.photoshop" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Blend", "codecs/compress/Deflate", "codecs/compress/PackBits", "codecs/text/Text" }, caps = { decode = true, encode = true, layers = true, groups = true, depths = { 1, 8, 16, 32 } }, + sniff = 0, load = function() return __include("layered/psd") end, @@ -3647,6 +3862,7 @@ local list= { mime = { "text/x-ssa", "text/x-ass" }, deps = { "core/Err", "core/Bytes", "Types", "core/Sniff" }, caps = { decode = true, encode = true, styles = true }, + sniff = 0, load = function() return __include("subtitle/ass") end, @@ -3659,6 +3875,7 @@ local list= { mime = { "application/x-subrip", "text/srt" }, deps = { "core/Err", "core/Bytes", "Types", "core/Sniff" }, caps = { decode = true, encode = true, styles = false }, + sniff = 0, load = function() return __include("subtitle/srt") end, @@ -3671,6 +3888,7 @@ local list= { mime = { "text/vtt" }, deps = { "core/Err", "core/Bytes", "Types", "core/Sniff" }, caps = { decode = true, encode = true, styles = true }, + sniff = 0, load = function() return __include("subtitle/vtt") end, @@ -3683,6 +3901,7 @@ local list= { mime = { "audio/x-669" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 8, 8 } }, + sniff = 0, load = function() return __include("music/669") end, @@ -3695,6 +3914,7 @@ local list= { mime = { "audio/x-ahx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Hively" }, caps = { decode = true, encode = false, render = true, channels = { 4, 4 }, subsongs = true }, + sniff = 0, load = function() return __include("music/ahx") end, @@ -3707,6 +3927,7 @@ local list= { mime = { "audio/x-far" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 16, 16 } }, + sniff = 0, load = function() return __include("music/far") end, @@ -3719,6 +3940,7 @@ local list= { mime = { "audio/x-hmp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/MidiRender" }, caps = { decode = true, encode = false, render = true, hmi = true }, + sniff = 0, load = function() return __include("music/hmp") end, @@ -3731,6 +3953,7 @@ local list= { mime = { "audio/x-hvl" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Hively" }, caps = { decode = true, encode = false, render = true, channels = { 4, 16 }, subsongs = true }, + sniff = 0, load = function() return __include("music/hvl") end, @@ -3743,6 +3966,7 @@ local list= { mime = { "audio/it", "audio/x-it" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker" }, caps = { decode = true, encode = false, render = true, channels = { 1, 64 }, compressedSamples = true }, + sniff = 0, load = function() return __include("music/it") end, @@ -3755,6 +3979,7 @@ local list= { mime = { "audio/x-med" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 1, 64 } }, + sniff = 0, load = function() return __include("music/med") end, @@ -3767,6 +3992,7 @@ local list= { mime = { "audio/midi", "audio/x-midi" }, deps = { "core/Err", "core/Bytes", "codecs/audio/MidiRender", "Types" }, caps = { decode = true, encode = true, formats = { 0, 1, 2 }, render = true, streaming = true, rmid = true }, + sniff = 0, load = function() return __include("music/midi") end, @@ -3779,6 +4005,7 @@ local list= { mime = { "audio/x-mod", "audio/mod" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker" }, caps = { decode = true, encode = true, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return __include("music/mod") end, @@ -3791,6 +4018,7 @@ local list= { mime = { "audio/x-mtm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return __include("music/mtm") end, @@ -3803,6 +4031,7 @@ local list= { mime = { "audio/x-mus" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/MidiRender" }, caps = { decode = true, encode = false, render = true }, + sniff = 0, load = function() return __include("music/mus") end, @@ -3815,6 +4044,7 @@ local list= { mime = { "audio/x-okt" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 4, 8 } }, + sniff = 0, load = function() return __include("music/okt") end, @@ -3827,6 +4057,7 @@ local list= { mime = { "audio/x-ptm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return __include("music/ptm") end, @@ -3839,6 +4070,7 @@ local list= { mime = { "audio/s3m", "audio/x-s3m" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker" }, caps = { decode = true, encode = false, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return __include("music/s3m") end, @@ -3851,6 +4083,7 @@ local list= { mime = { "audio/x-soundfont" }, deps = { "core/Err", "core/Bytes", "codecs/audio/SoundFont" }, caps = { decode = true, encode = false, sm24 = true, sf3 = false }, + sniff = 1, load = function() return __include("music/sf2") end, @@ -3863,6 +4096,7 @@ local list= { mime = { "audio/x-stm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 4, 4 } }, + sniff = 0, load = function() return __include("music/stm") end, @@ -3875,6 +4109,7 @@ local list= { mime = { "audio/x-ult" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return __include("music/ult") end, @@ -3887,6 +4122,7 @@ local list= { mime = { "audio/x-umx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker" }, caps = { decode = true, encode = false, render = true, container = true }, + sniff = 0, load = function() return __include("music/umx") end, @@ -3899,6 +4135,7 @@ local list= { mime = { "audio/xm", "audio/x-xm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Adpcm" }, caps = { decode = true, encode = true, render = true, channels = { 1, 64 } }, + sniff = 0, load = function() return __include("music/xm") end, @@ -3911,6 +4148,7 @@ local list= { mime = { "audio/x-xmidi" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks", "codecs/audio/MidiRender" }, caps = { decode = true, encode = false, render = true, songs = true }, + sniff = 0, load = function() return __include("music/xmi") end, @@ -3923,6 +4161,7 @@ local list= { mime = { "audio/x-mpegurl", "audio/mpegurl", "application/vnd.apple.mpegurl", "application/x-mpegurl" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Url", "codecs/text/Text", "core/Sniff" }, caps = { decode = true, encode = true, hls = true }, + sniff = 0, load = function() return __include("playlist/m3u") end, @@ -3935,6 +4174,7 @@ local list= { mime = { "audio/x-scpls", "audio/scpls" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Url", "codecs/text/Text", "core/Sniff" }, caps = { decode = true, encode = true }, + sniff = 1, load = function() return __include("playlist/pls") end, @@ -3947,6 +4187,7 @@ local list= { mime = { "application/xspf+xml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Url", "codecs/text/Xml" }, caps = { decode = true, encode = true }, + sniff = 0, load = function() return __include("playlist/xspf") end, @@ -3955,6 +4196,3392 @@ local list= { return list end +__FILES["Sniffs"] = function() +local __compat = __compat local buffer, bit32, __iter = __compat.buffer, __compat.bit32, __compat.__iter --!strict +--!optimize 2 +-- Sniffs: GENERATED by tools/gen_registry.py from the format folders - do not edit. +-- Each format's sniff (format path -> sniff(r)), copied from its init.luau with the top-level locals and types it +-- reaches (tools/sniff_extract.py), so detection requires no format module. Requires outside core/ are proxies that +-- require on first use. Formats whose sniff needs their module (Registry sniff = 2) are not here. +local S= {} + +local function lazy(load) +local proxy = {} + return setmetatable(proxy, { + __index = function(_, k) +local m = load() + setmetatable(proxy, { __index = m }) + return m[k] + end, + }) +end + +do -- image/ani +local Bytes = __include("core/Bytes") +S["image/ani"] = function(r) +return r:peek(4) == "RIFF" and r:peek(4, 8) == "ACON" and 1 or 0 +end +end + +do -- image/art +local Bytes = __include("core/Bytes") +local readu8, readu16, readu32, readi16 = buffer.readu8, buffer.readu16, buffer.readu32, buffer.readi16 +local function header(b, o, limit) +local p = o + local prefixed = false + if limit - p >= 8 and buffer.readstring(b, p, 8) == "BUILDART" then + p =p+ 8 + prefixed = true + end + if limit - p < 16 or readu32(b, p) ~= 1 then + return nil, nil, nil, nil, nil + end + local first, last = readu32(b, p + 8), readu32(b, p + 12) + if last < first or last - first >= 65536 then + return nil, nil, nil, nil, nil + end + return p + 16, first, last, readu32(b, p + 4), prefixed +end +S["image/art"] = function(r) +local at, first, last = header(r.buf, r.base, r.limit) + if not at or not first or not last then + return 0 + end + local n = last - first + 1 + local p = at +if r.limit - p < n * 8 then + return 0 + end + local total = 0 + for i = 0, n - 1 do + local w, h = readi16(r.buf, p + i * 2), readi16(r.buf, p + n * 2 + i * 2) + if w < 0 or h < 0 then + return 0 + end + total =total+ w * h + end + local size = p + n * 8 + total - r.base + local have = r.limit - r.base + return size == have and 0.9 or(size < have and have - size < 4096 and 0.5 or 0 +)end +end + +do -- image/blp +local Bytes = __include("core/Bytes") +S["image/blp"] = function(r) +local m = r:peek(4) + return (m == "BLP1" or m == "BLP2" )and 1 or(m == "BLP0" and 0.8 or 0 +)end +end + +do -- image/bmp +local Bytes = __include("core/Bytes") +S["image/bmp"] = function(r) +if r:peek(2) ~= "BM" then + return 0 + end + local n = r:peekU8(14) + math.max(r:peekU8(15), 0) * 256 + if r:peekU8(16) == 0 and r:peekU8(17) == 0 and (n == 12 or n == 16 or n == 40 or n == 52 or n == 56 or n == 64 or n == 108 or n == 124) then + return 0.9 + end + return 0.2 +end +end + +do -- image/dds +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +local MAGIC = "DDS " +S["image/dds"] = function(r) +return math.max(Sniff.magic(r, MAGIC .. "\124\0\0\0"), Sniff.magic(r, MAGIC, 0, 0.6)) +end +end + +do -- image/exr +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +local MAGIC = "\118\47\49\1" +S["image/exr"] = function(r) +return Sniff.magic(r, MAGIC) +end +end + +do -- image/gif +local Bytes = __include("core/Bytes") +S["image/gif"] = function(r) +local s = r:peek(6) + return (s == "GIF89a" or s == "GIF87a" )and 1 or 0 +end +end + +do -- image/hdr +local Bytes = __include("core/Bytes") +S["image/hdr"] = function(r) +local s = r:peek(10) + if s == "#?RADIANCE" then + return 1 + end + if string.sub(s, 1, 6) == "#?RGBE" then + return 1 + end + if string.sub(s, 1, 2) == "#?" and string.match(s, "^#%?%u") then + return 0.5 + end + return 0 +end +end + +do -- image/icns +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["image/icns"] = function(r) +return Sniff.magic(r, "icns") +end +end + +do -- image/ico +local Bytes = __include("core/Bytes") +local readu8 = buffer.readu8 +S["image/ico"] = function(r) +if r:remaining() < 22 then + return 0 + end + local b, o = r.buf, r.pos + local typ = buffer.readu16(b, o + 2) + local count = buffer.readu16(b, o + 4) + if buffer.readu16(b, o) ~= 0 or (typ ~= 1 and typ ~= 2) or count == 0 then + return 0 + end + -- the first entry: reserved byte 0, a size and offset inside the file + local size, off = buffer.readu32(b, o + 14), buffer.readu32(b, o + 18) + if readu8(b, o + 9) ~= 0 or size == 0 or off < 6 + count * 16 then + return 0 + end + return 0.8 +end +end + +do -- image/ilbm +local Bytes = __include("core/Bytes") +S["image/ilbm"] = function(r) +if r:peek(4) ~= "FORM" then + return 0 + end + local t = r:peek(4, 8) + return (t == "ILBM" or t == "PBM " )and 1 or 0 +end +end + +do -- image/jpeg +local Bytes = __include("core/Bytes") +S["image/jpeg"] = function(r) +local s = r:peek(3) + return s == "\255\216\255" and 1 or 0 +end +end + +do -- image/ktx +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +local ID1 = "\171KTX 11\187\r\n\26\n" +local ID2 = "\171KTX 20\187\r\n\26\n" +S["image/ktx"] = function(r) +return math.max(Sniff.magic(r, ID2), Sniff.magic(r, ID1)) +end +end + +do -- image/lmp +local Bytes = __include("core/Bytes") +local function kindOf(r) +local n = r:remaining() + if n == 768 then + return "palette" + elseif n == 16385 or n == 16384 then + return "colormap" + end + if n < 9 then + return nil + end + local w, h = buffer.readu32(r.buf, r.pos), buffer.readu32(r.buf, r.pos + 4) + if w > 0 and h > 0 and w <= 4096 and h <= 4096 and 8 + w * h == n then + return "qpic" + end + return nil +end +S["image/lmp"] = function(r) +local k = kindOf(r) + return k == "qpic" and 0.3 or(k and 0.05 or 0 +)end +end + +do -- image/pcx +local Bytes = __include("core/Bytes") +S["image/pcx"] = function(r) +if r:size() < 128 then + return 0 + end + local m, v, e, bpp = r:peekU8(0), r:peekU8(1), r:peekU8(2), r:peekU8(3) + if m ~= 10 or (v ~= 0 and v ~= 2 and v ~= 3 and v ~= 4 and v ~= 5) or e > 1 then + return 0 + end + return (bpp == 1 or bpp == 2 or bpp == 4 or bpp == 8 )and 0.8 or 0 +end +end + +do -- image/png +local Bytes = __include("core/Bytes") +local SIGNATURE = "\137PNG\r\n\26\n" +S["image/png"] = function(r) +return r:peek(8) == SIGNATURE and 1 or 0 +end +end + +do -- image/pnm +local Bytes = __include("core/Bytes") +S["image/pnm"] = function(r) +if r:remaining() < 3 then + return 0 + end + local a, b, c = r:peekU8(0), r:peekU8(1), r:peekU8(2) + if a ~= 80 then -- 'P' + return 0 + end + local ws = c == 32 or (c >= 9 and c <= 13) + if b >= 49 and b <= 55 and ws then -- P1..P7 + return 0.9 + end + if (b == 70 or b == 102) and ws then -- PF / Pf + return 0.9 + end + return 0 +end +end + +do -- image/qoi +local Bytes = __include("core/Bytes") +S["image/qoi"] = function(r) +return r:peek(4) == "qoif" and 1 or 0 +end +end + +do -- image/sgi +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["image/sgi"] = function(r) +if Sniff.magic(r, "\1\218") == 0 or r:size() < 512 then + return 0 + end + local st, bpc = r:peekU8(2), r:peekU8(3) + return st <= 1 and (bpc == 1 or bpc == 2) and 1 or 0 +end +end + +do -- image/spr +local Bytes = __include("core/Bytes") +S["image/spr"] = function(r) +if r:remaining() < 36 or r:peek(4) ~= "IDSP" then + return 0 + end + local v = buffer.readi32(r.buf, r.pos + 4) + return (v == 1 or v == 2 or v == 32 )and 1 or 0.3 +end +end + +do -- image/sunras +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +local MAGIC = "\89\166\106\149" +S["image/sunras"] = function(r) +return Sniff.magic(r, MAGIC) +end +end + +do -- image/tga +local Bytes = __include("core/Bytes") +local TYPES = { [1] = true, [2] = true, [3] = true, [9] = true, [10] = true, [11] = true } +local FOOTER = "TRUEVISION-XFILE.\0" +local readu8 = buffer.readu8 + + + + + + + + + + + + +local function header(r) +if r.limit - r.base < 18 then + return nil + end + local b, o = r.buf, r.base + local function u16(q) +return readu8(b, o + q) + readu8(b, o + q + 1) * 256 + end + local h= { + idLen = readu8(b, o), + cmapType = readu8(b, o + 1), + imageType = readu8(b, o + 2), + cmapFirst = u16(3), + cmapLen = u16(5), + cmapBits = readu8(b, o + 7), + width = u16(12), + height = u16(14), + depth = readu8(b, o + 16), + desc = readu8(b, o + 17), + } + return h +end +local function implausible(h) +local t = h.imageType + if not TYPES[t] then + return "image type " .. t + end + if h.cmapType > 1 then + return "colour map type " .. h.cmapType + end + local mapped = t == 1 or t == 9 + if mapped and (h.cmapType ~= 1 or (h.depth ~= 8 and h.depth ~= 16)) then + return "colour-mapped image without a colour map" + end + if h.cmapType == 1 and h.cmapLen > 0 and h.cmapBits ~= 15 and h.cmapBits ~= 16 and h.cmapBits ~= 24 and h.cmapBits ~= 32 then + return "colour map entry size " .. h.cmapBits + end + if (t == 2 or t == 10) and h.depth ~= 15 and h.depth ~= 16 and h.depth ~= 24 and h.depth ~= 32 then + return "pixel depth " .. h.depth + end + if (t == 3 or t == 11) and h.depth ~= 8 and h.depth ~= 16 then + return "grey pixel depth " .. h.depth + end + if h.width == 0 or h.height == 0 then + return "zero size" + end + if h.desc >= 64 then + return "interleaving / reserved descriptor bits" + end + return nil +end +S["image/tga"] = function(r) +local h = header(r) + if not h or implausible(h) then + return 0 + end + local n = r.limit - r.base + if n >= 44 and buffer.readstring(r.buf, r.limit - 18, 18) == FOOTER then + return 0.9 + end + return 0.2 +end +end + +do -- image/tiff +local Bytes = __include("core/Bytes") +S["image/tiff"] = function(r) +local s = r:peek(4) + if s == "II*\0" or s == "MM\0*" or s == "II+\0" or s == "MM\0+" then + return 1 + end + return 0 +end +end + +do -- image/tim +local Bytes = __include("core/Bytes") +S["image/tim"] = function(r) +if r:remaining() < 20 or r:peek(4) ~= "\16\0\0\0" then + return 0 + end + local flags = r:peekU8(4) + if flags > 0x0F or (flags % 8) > 3 or r:peek(3, 5) ~= "\0\0\0" then + return 0 + end + return 0.8 +end +end + +do -- image/vtf +local Bytes = __include("core/Bytes") +S["image/vtf"] = function(r) +return r:peek(4) == "VTF\0" and r:peekU8(4) == 7 and 1 or 0 +end +end + +do -- image/webp +local Bytes = __include("core/Bytes") +S["image/webp"] = function(r) +if r:peek(4) == "RIFF" and r:peek(4, 8) == "WEBP" then + return 1 + end + return 0 +end +end + +do -- image/xbm +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["image/xbm"] = function(r) +local s = Sniff.text(r, 256, true) + if string.match(s, "^#define%s+[%w_]*_?width%s+%d+") or string.match(s, "^/%*.-%*/%s*#define%s+[%w_]*width%s+%d+") then + return 0.9 + end + return 0 +end +end + +do -- image/xpm +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["image/xpm"] = function(r) +local s = Sniff.text(r, 64, true) + if string.sub(s, 1, 9) == "/* XPM */" or string.sub(s, 1, 6) == "! XPM2" then + return 1 + end + return 0 +end +end + +do -- audio/aac +local Bytes = __include("core/Bytes") +local Aac = lazy(function() + return __include("codecs/audio/Aac") +end) +local readu8 = buffer.readu8 +local function id3Size(b, p, limit) +if p + 10 > limit or buffer.readstring(b, p, 3) ~= "ID3" then + return 0 + end + local s = 0 + for i = 6, 9 do + s = s * 128 + bit32.band(readu8(b, p + i), 127) + end + local footer = bit32.band(readu8(b, p + 5), 0x10) ~= 0 and 10 or 0 + return 10 + s + footer +end +S["audio/aac"] = function(r) +local b, p, limit = r.buf, r.pos, r.limit + p =p+ id3Size(b, p, limit) + local h = Aac.adts(b, p, limit) + if not h then + return 0 + end + local h2 = Aac.adts(b, p + h.frameSize, limit) + if h2 and h2.sfIndex == h.sfIndex and h2.channelConfig == h.channelConfig then + return 0.9 + end + return p + h.frameSize >= limit and 0.7 or 0.4 +end +end + +do -- audio/ac3 +local Bytes = __include("core/Bytes") +local Ac3 = lazy(function() + return __include("codecs/audio/Ac3") +end) +S["audio/ac3"] = function(r) +local b, p, limit = r.buf, r.pos, r.limit + local h = Ac3.header(b, p, limit) + if not h then + return 0 + end + local h2 = Ac3.header(b, p + h.frameSize, limit) + if h2 and h2.sampleRate == h.sampleRate then + return 0.9 + end + return p + h.frameSize >= limit and 0.6 or 0.3 +end +end + +do -- audio/adpcm +local Bytes = __include("core/Bytes") +S["audio/adpcm"] = function(_r) +return 0 +end +end + +do -- audio/adx +local Bytes = __include("core/Bytes") +S["audio/adx"] = function(r) +if r:peekU8(0) ~= 0x80 or r:peekU8(1) ~= 0 then + return 0 + end + local off = r:peekU8(2) * 256 + r:peekU8(3) + return r:peek(6, off - 2) == "(c)CRI" and 1 or 0 +end +end + +do -- audio/aiff +local Bytes = __include("core/Bytes") +S["audio/aiff"] = function(r) +if r:remaining() < 12 or r:peek(4) ~= "FORM" then + return 0 + end + local form = buffer.readstring(r.buf, r.pos + 8, 4) + return (form == "AIFF" or form == "AIFC" )and 1 or 0 +end +end + +do -- audio/ape +local Bytes = __include("core/Bytes") +S["audio/ape"] = function(r) +local head = r:peek(4) + if head == "MAC " or head == "MACF" then -- MACF: float samples + return 1 + end + if string.sub(head, 1, 3) == "ID3" then + local sz = 0 + for i = 6, 9 do + local v = r:peekU8(i) + if v < 0 then + return 0 + end + sz = sz * 128 + bit32.band(v, 127) + end + local footer = bit32.band(math.max(r:peekU8(5), 0), 0x10) ~= 0 + local id = r:peek(4, 10 + sz + (footer and 10 or 0)) + return (id == "MAC " or id == "MACF" )and 1 or 0 + end + return 0 +end +end + +do -- audio/au +local Bytes = __include("core/Bytes") +S["audio/au"] = function(r) +return r:peek(4) == ".snd" and 1 or 0 +end +end + +do -- audio/brstm +local Bytes = __include("core/Bytes") +S["audio/brstm"] = function(r) +local m = r:peek(4) + if m ~= "RSTM" and m ~= "CSTM" and m ~= "FSTM" then + return 0 + end + local bom = r:peek(2, 4) + return (bom == "\254\255" or bom == "\255\254" )and 1 or 0 +end +end + +do -- audio/caf +local Bytes = __include("core/Bytes") +S["audio/caf"] = function(r) +local h = r:peek(8) + if #h == 8 and string.sub(h, 1, 4) == "caff" and string.byte(h, 5) == 0 and string.byte(h, 6) == 1 then + return 1 + end + return 0 +end +end + +do -- audio/flac +local Bytes = __include("core/Bytes") +S["audio/flac"] = function(r) +local head = r:peek(4) + if head == "fLaC" then + return 1 + end + if head == "OggS" then + -- the first page's packet: 0x7F "FLAC" (the Ogg FLAC mapping) + local nseg = r:peekU8(26) + if nseg > 0 and r:peek(5, 27 + nseg) == "\127FLAC" then + return 1 + end + return 0 + end + if string.sub(head, 1, 3) == "ID3" then + -- an ID3v2 tag, then fLaC (mp3 files start with ID3 too) + local sz = 0 + for i = 6, 9 do + local v = r:peekU8(i) + if v < 0 then + return 0 + end + sz = sz * 128 + bit32.band(v, 127) + end + local footer = bit32.band(math.max(r:peekU8(5), 0), 0x10) ~= 0 + return r:peek(4, 10 + sz + (footer and 10 or 0)) == "fLaC" and 1 or 0 + end + return 0 +end +end + +do -- audio/m4a +local Bytes = __include("core/Bytes") +local IsoBmff = lazy(function() + return __include("containers/IsoBmff") +end) +local AUDIO_BRANDS= { ["M4A "] = 1, ["M4B "] = 1, ["M4P "] = 1, ["M4V "] = 0.3 } +S["audio/m4a"] = function(r) +local brand = IsoBmff.sniff(r) + if brand == nil then + return 0 + end + if AUDIO_BRANDS[brand] then + return AUDIO_BRANDS[brand] + end + if brand == "avif" or brand == "avis" or brand == "heic" or brand == "heix" or brand == "mif1" or brand == "msf1" or brand == "crx " then + return 0 + end + return 0.4 -- an MP4 / MOV that may hold audio; a video format claims it more strongly +end +end + +do -- audio/mp3 +local Bytes = __include("core/Bytes") +local Header = lazy(function() + return __include("codecs/audio/Mpa/Header") +end) +local Tags = lazy(function() + return __include("audio/mp3/Tags") +end) +S["audio/mp3"] = function(r) +local b, p, lim = r.buf, r.pos, r.limit + local id3 = false + for _ = 1, 4 do -- (ffmpeg writes a tag even when the input had one: tags can follow each other) + local n = (p + 3 <= lim and buffer.readstring(b, p, 3) == "ID3" and{(Tags.id3v2Size(b, p, lim) )}or{0 +})[1] if n <= 0 then + break + end + id3 = true + p =p+ n + end + if p + 4 > lim or not Header.valid(b, p) then + return id3 and 0.5 or 0 + end + local fb = Header.frameBytes(b, p, 0) + if fb > 0 then + fb =fb+ Header.padding(b, p) + if p + fb + 4 <= lim and Header.compare(b, p, p + fb) then + return 0.9 + end + if p + fb == lim then + return 0.6 + end + end + return id3 and 0.7 or 0.25 +end +end + +do -- audio/mpc +local Bytes = __include("core/Bytes") +local Musepack = lazy(function() + return __include("codecs/audio/Musepack") +end) +local function id3v2(b, p, limit) +if p + 10 > limit or buffer.readstring(b, p, 3) ~= "ID3" then + return 0 + end + local n = 10 + for i = 6, 9 do + n =n+ bit32.band(buffer.readu8(b, p + i), 127) * 128 ^ (9 - i) + end + return n + (bit32.band(buffer.readu8(b, p + 5), 0x10) ~= 0 and 10 or 0) +end +S["audio/mpc"] = function(r) +local b, p, limit = r.buf, r.pos, r.limit + p =p+ id3v2(b, p, limit) + local v = Musepack.magic(b, p, limit) + if v == 8 then + return 1 + end + return v == 7 and 0.9 or 0 +end +end + +do -- audio/opus +local Bytes = __include("core/Bytes") +S["audio/opus"] = function(r) +if r:peek(4) ~= "OggS" then + return 0 + end + local nseg = r:peekU8(26) + if nseg < 1 then + return 0 + end + return r:peek(8, 27 + nseg) == "OpusHead" and 1 or 0 +end +end + +do -- audio/qoa +local Bytes = __include("core/Bytes") +S["audio/qoa"] = function(r) +return r:peek(4) == "qoaf" and 1 or 0 +end +end + +do -- audio/tta +local Bytes = __include("core/Bytes") +local function id3Size(r) +if r:peek(3) ~= "ID3" then + return 0 + end + local sz = 0 + for i = 6, 9 do + local v = r:peekU8(i) + if v < 0 then + return 0 + end + sz = sz * 128 + bit32.band(v, 127) + end + local footer = bit32.band(math.max(r:peekU8(5), 0), 0x10) ~= 0 + return 10 + sz + (footer and 10 or 0) +end +S["audio/tta"] = function(r) +return r:peek(4, id3Size(r)) == "TTA1" and 1 or 0 +end +end + +do -- audio/vag +local Bytes = __include("core/Bytes") +S["audio/vag"] = function(r) +local m = r:peek(4) + return (m == "VAGp" or m == "VAGi" or m == "KVAG" )and 1 or 0 +end +end + +do -- audio/voc +local Bytes = __include("core/Bytes") +local MAGIC = "Creative Voice File\26" +S["audio/voc"] = function(r) +return r:peek(20) == MAGIC and 1 or 0 +end +end + +do -- audio/vorbis +local Bytes = __include("core/Bytes") +S["audio/vorbis"] = function(r) +if r:remaining() < 35 or r:peek(4) ~= "OggS" then + return 0 + end + local b, p = r.buf, r.pos + local nseg = buffer.readu8(b, p + 26) + local d = p + 27 + nseg + if d + 7 > r.limit then + return 0 + end + return buffer.readu8(b, d) == 1 and buffer.readstring(b, d + 1, 6) == "vorbis" and 1 or 0 +end +end + +do -- audio/wav +local Bytes = __include("core/Bytes") +local Riff = lazy(function() + return __include("containers/Riff") +end) +S["audio/wav"] = function(r) +return Riff.sniff(r) == "WAVE" and 1 or 0 +end +end + +do -- audio/wavpack +local Bytes = __include("core/Bytes") +S["audio/wavpack"] = function(r) +if r:peek(4) ~= "wvpk" then + return 0 + end + local v = r:peekU8(9) + return v == 4 and 1 or 0.5 +end +end + +do -- video/avi +local Bytes = __include("core/Bytes") +S["video/avi"] = function(r) +if r:peek(4) == "RIFF" and r:peek(4, 8) == "AVI " then + return 1 + end + return 0 +end +end + +do -- video/fli +local Bytes = __include("core/Bytes") +local FLI, FLC, DTA = 0xAF11, 0xAF12, 0xAF44 +S["video/fli"] = function(r) +local s = r:peek(18) + if #s < 18 then + return 0 + end + local magic = string.byte(s, 5) + string.byte(s, 6) * 256 + if magic ~= FLI and magic ~= FLC and magic ~= DTA then + return 0 + end + local w = string.byte(s, 9) + string.byte(s, 10) * 256 + local h = string.byte(s, 11) + string.byte(s, 12) * 256 + if w > 4096 or h > 4096 then + return 0 + end + return 0.9 +end +end + +do -- video/flv +local Bytes = __include("core/Bytes") +S["video/flv"] = function(r) +if r:remaining() >= 9 and r:peek(3) == "FLV" then + return r:peekU8(3) == 1 and 1 or 0.6 + end + return 0 +end +end + +do -- video/h264 +local Bytes = __include("core/Bytes") +S["video/h264"] = function(r) +local s = r:peek(5) + if not s or #s < 4 then + return 0 + end + local hdr + if string.byte(s, 1) == 0 and string.byte(s, 2) == 0 and string.byte(s, 3) == 1 then + hdr = string.byte(s, 4) + elseif #s >= 5 and string.byte(s, 1) == 0 and string.byte(s, 2) == 0 and string.byte(s, 3) == 0 and string.byte(s, 4) == 1 then + hdr = string.byte(s, 5) + else + return 0 + end + if hdr >= 128 then + return 0 + end + local t = hdr % 32 + if t == 7 then + return 0.8 + elseif t == 9 or t == 6 or t == 8 then + return 0.5 + elseif t == 5 then + return 0.4 + end + return 0 +end +end + +do -- video/mkv +local Bytes = __include("core/Bytes") +S["video/mkv"] = function(r) +if r:peek(4) ~= "\26\69\223\163" then + return 0 + end + local head = r:peek(math.min(64, r:remaining())) + if string.find(head, "webm", 1, true) or string.find(head, "matroska", 1, true) then + return 1 + end + return 0.5 +end +end + +do -- video/mp4 +local Bytes = __include("core/Bytes") +local IsoBmff = lazy(function() + return __include("containers/IsoBmff") +end) +local IMAGE_BRANDS = { avif = true, avis = true, heic = true, heix = true, mif1 = true, msf1 = true, ["crx "] = true } +local AUDIO_BRANDS = { ["M4A "] = true, ["M4B "] = true, ["M4P "] = true } +S["video/mp4"] = function(r) +local brand = IsoBmff.sniff(r) + if brand == nil or IMAGE_BRANDS[brand] then + return 0 + end + if AUDIO_BRANDS[brand] then + return 0.2 + end + if brand == "M4V " then + return 0.9 + end + return brand == "" and 0.6 or 0.8 +end +end + +do -- video/mpegps +local Bytes = __include("core/Bytes") +S["video/mpegps"] = function(r) +if r:peek(4) == "\0\0\1\186" then + return 0.9 + end + if r:peek(4) == "\0\0\1\179" then + return 0.5 -- an MPEG-1 / 2 video elementary stream (sequence header) + end + return 0 +end +end + +do -- video/mpegts +local Bytes = __include("core/Bytes") +local SIZES = { 188, 192 } +local function packetSize(r) +local n = r:remaining() + local head = r:peek(2048 + 2 * 192) + local lim = math.min(n, 2048) + local start = 0 + while start < lim do + local f = string.find(head, "G", start + 1, true) -- 0x47 + if not f or f > lim then + break + end + start = f - 1 + for _, size in __iter(SIZES) do + local hits, need = 0, math.min(3, math.floor((n - start - 1) / size )+ 1) + for k = 0, 2 do + local at = start + k * size + if at < n and string.byte(head, at + 1) == 0x47 then + hits =hits+ 1 + end + end + if hits >= need and (need >= 2 or start == 0) then + if size == 192 and start >= 4 then + return 192, start - 4 + elseif size == 188 then + return 188, start + end + end + end + start =start+ 1 + end + return 0, 0 +end +S["video/mpegts"] = function(r) +local s, off = packetSize(r) + if s == 0 then + return 0 + end + if off > 0 then + return 0.6 + end + return r:remaining() >= 3 * s and 0.9 or 0.5 +end +end + +do -- video/ogv +local Bytes = __include("core/Bytes") +S["video/ogv"] = function(r) +if r:peek(4) ~= "OggS" then + return 0 + end + local b, p, lim = r.buf, r.pos, r.limit + for _ = 1, 8 do + if p + 27 > lim or buffer.readstring(b, p, 4) ~= "OggS" or buffer.readu8(b, p + 5) % 4 < 2 then + return 0 + end + local nseg = buffer.readu8(b, p + 26) + local d = p + 27 + nseg + if d + 7 <= lim and buffer.readu8(b, d) == 0x80 and buffer.readstring(b, d + 1, 6) == "theora" then + return 1 + end + if d > lim then + return 0 + end + local size = 0 + for i = 0, nseg - 1 do + size =size+ buffer.readu8(b, p + 27 + i) + end + p = d + size + end + return 0 +end +end + +do -- video/smk +local Bytes = __include("core/Bytes") +S["video/smk"] = function(r) +local s = r:peek(4) + if s ~= "SMK2" and s ~= "SMK4" then + return 0 + end + return 1 +end +end + +do -- video/y4m +local Bytes = __include("core/Bytes") +local MAGIC = "YUV4MPEG2 " +S["video/y4m"] = function(r) +return r:peek(10) == MAGIC and 1 or 0 +end +end + +do -- model/3ds +local Bytes = __include("core/Bytes") +S["model/3ds"] = function(r) +local h = r:peek(8) + if #h < 8 or string.byte(h, 1) ~= 0x4D or string.byte(h, 2) ~= 0x4D then + return 0 + end + local b1, b2, b3, b4, c1, c2 = string.byte(h, 3, 8) + local size = b1 + b2 * 256 + b3 * 65536 + b4 * 16777216 + local child = c1 + c2 * 256 + if size < 16 or not (child == 0x0002 or child == 0x3D3D or child == 0xB000) then + return 0 + end + return size == r.limit - r.pos and 0.95 or 0.7 +end +end + +do -- model/3mf +local Bytes = __include("core/Bytes") +S["model/3mf"] = function(r) +if r:peek(4) ~= "PK\3\4" then + return 0 + end + local n = r:size() + local tail = buffer.readstring(r.buf, r.base + math.max(0, n - 65536), math.min(n, 65536)) + if string.find(tail, "3D/[^/]*%.model") or string.find(tail, "3dmodel.model", 1, true) then + return 0.95 + end + local head = r:peek(256) + if string.find(head, "3D/", 1, true) then + return 0.7 + end + return 0 +end +end + +do -- model/ase +local Bytes = __include("core/Bytes") +local Text = lazy(function() + return __include("codecs/text/Text") +end) +local MAGIC = "*3DSMAX_ASCIIEXPORT" +local function utf16(r) +local h = r:peek(2) + if h == "\255\254" then + return true, false + elseif h == "\254\255" then + return true, true + elseif #h == 2 and string.byte(h, 2) == 0 and string.byte(h, 1) == 42 then + return true, false + elseif #h == 2 and string.byte(h, 1) == 0 and string.byte(h, 2) == 42 then + return true, true + end + return nil, false +end +local function text(r, n) +local wide, be = utf16(r) + local len = r.limit - r.pos + if n then + len = math.min(len, n) + end + if wide then + local skip = (r:peek(2) == "\255\254" or r:peek(2) == "\254\255" )and 2 or 0 + return Text.utf16(r.buf, r.pos + skip, len - skip, be) + end + return Text.toUtf8(buffer.readstring(r.buf, r.pos, len)) +end +S["model/ase"] = function(r) +local h = string.match(text(r, 256), "^%s*(%*[%w_]+)") + if h == MAGIC then + return 1 + end + return 0 +end +end + +do -- model/b3d +local Bytes = __include("core/Bytes") +S["model/b3d"] = function(r) +if r:peek(4) == "BB3D" then + return r:peek(4, 8) ~= "" and 1 or 0.8 + end + return 0 +end +end + +do -- model/blend +local Bytes = __include("core/Bytes") +local Deflate = lazy(function() + return __include("codecs/compress/Deflate") +end) +local Zstd = lazy(function() + return __include("codecs/compress/Zstd") +end) +S["model/blend"] = function(r) +local head = r:peek(7) + if head == "BLENDER" then + return 1 + end + local n = r.limit - r.base + if string.sub(head, 1, 3) == "\31\139\8" then + local inner = Deflate.peek(r.buf, r.base, n, 7) + return inner and buffer.tostring(inner) == "BLENDER" and 1 or 0 + end + if string.sub(head, 1, 4) == Zstd.MAGIC then + if n > 4 * 2 ^ 20 then + return 0.5 + end + local out = Zstd.decompress(r.buf, r.base, n, { verify = false }) + return out and buffer.len(out) >= 7 and buffer.readstring(out, 0, 7) == "BLENDER" and 1 or 0 + end + return 0 +end +end + +do -- model/bsp +local Bytes = __include("core/Bytes") +S["model/bsp"] = function(r) +if r:remaining() < 64 then + return 0 + end + local m = r:peek(4) + local v = buffer.readi32(r.buf, r.pos + (m == "IBSP" and 4 or 0)) + if m == "BSP2" or m == "2PSB" then + v = 29 + end + if m == "IBSP" then + return (v == 38 or v == 46 or v == 47 )and 1 or 0.3 + end + if v == 29 or v == 30 then + local size = r:remaining() + for i = 0, 14 do + local o, n = buffer.readi32(r.buf, r.pos + 4 + i * 8), buffer.readi32(r.buf, r.pos + 8 + i * 8) + if o < 0 or n < 0 or o + n > size then + return 0 + end + end + return 0.6 + end + return 0 +end +end + +do -- model/buildmap +local Bytes = __include("core/Bytes") +local SECTOR_SIZE, WALL_SIZE, SPRITE_SIZE = 40, 32, 44 +local HEADER = 22 -- version, posx, posy, posz, ang, cursectnum, then u16 numsectors at 20 +local readu16 = buffer.readu16 +local function layout(b, o, limit) +if limit - o < HEADER then + return nil, nil, nil, nil + end + local ns = readu16(b, o + 20) + local p = o + HEADER + ns * SECTOR_SIZE + if p + 2 > limit then + return nil, nil, nil, nil + end + local nw = readu16(b, p) + p =p+ (2 + nw * WALL_SIZE +) if p + 2 > limit then + return nil, nil, nil, nil + end + local nsp = readu16(b, p) + p =p+ (2 + nsp * SPRITE_SIZE +) return ns, nw, nsp, p +end +S["model/buildmap"] = function(r) +local b, o, limit = r.buf, r.base, r.limit + if limit - o < HEADER then + return 0 + end + local v = buffer.readu32(b, o) + if v ~= 7 and v ~= 8 and v ~= 9 then + return 0 + end + local ns, _, _, stop = layout(b, o, limit) + if not ns or not stop or stop > limit then + return 0 + end + return stop == limit and 0.9 or 0.5 +end +end + +do -- model/d3map +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/d3map"] = function(r) +local head = Sniff.text(r, 512, true) + for _ = 1, 16 do + local rest = string.match(head, "^//[^\n]*\n%s*(.*)$") + if not rest then + break + end + head = rest + end + return string.match(head, "^Version%s+[123]%s") and 1 or 0 +end +end + +do -- model/dae +local Bytes = __include("core/Bytes") +S["model/dae"] = function(r) +local head = r:peek(2048) + if string.sub(head, 1, 4) == "PK\3\4" then + local nlen = string.byte(head, 27) or 0 + local name = string.lower(string.sub(head, 31, 30 + nlen)) + if string.find(name, "%.dae$") or name == "manifest.xml" then + return 0.95 + end + return 0 + end + -- UTF-16 files: drop the zero bytes + if string.find(string.sub(head, 1, 4), "\0", 1, true) then + head = string.gsub(head, "%z", "") + end + if string.find(head, " sectors then + return 0 + end + used =used+ 1 + if used == 1 then + local p = r.base + off * 4096 + if p + 5 > r.limit then + return 0 + end + local c = buffer.readu8(b, p + 4) % 128 + if COMPRESSION[c] == nil then + return 0 + end + end + end + end + return used > 0 and 0.8 or 0.2 +end +end + +do -- model/md2 +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/md2"] = function(r) +if r:remaining() < 68 then + return 0 + end + return Sniff.magic(r, "IDP2") == 1 and r:peekU8(4) == 8 and 1 or 0 +end +end + +do -- model/md3 +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/md3"] = function(r) +if r:remaining() < 108 then + return 0 + end + return Sniff.magic(r, "IDP3") == 1 and r:peekU8(4) == 15 and 1 or 0 +end +end + +do -- model/md5 +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/md5"] = function(r) +local head = Sniff.text(r, 512, true) + head = string.gsub(head, "^//[^\n]*\n%s*", "") + return string.match(head, "^MD5Version%s+%d+") and 1 or 0 +end +end + +do -- model/mdl +local Bytes = __include("core/Bytes") +S["model/mdl"] = function(r) +local m = r:peek(4) + local v = r:peekU8(4) + if (m == "IDPO" and v == 6) or (m == "IDST" and v == 10) then + return 1 + end + return 0 +end +end + +do -- model/ms3d +local Bytes = __include("core/Bytes") +local Read = lazy(function() + return __include("model/ms3d/Read") +end) +S["model/ms3d"] = function(r) +local h = r:peek(14) + if string.sub(h, 1, 10) ~= Read.MAGIC then + return 0 + end + local v = string.byte(h, 11) + return (v == 3 or v == 4 )and 1 or 0.6 +end +end + +do -- model/obj +local Bytes = __include("core/Bytes") +S["model/obj"] = function(r) +local head = r:peek(512) + if string.find(head, "\0", 1, true) then + return 0 + end + if string.find(head, "^%s*v%s+[%-%d%.]") or string.find(head, "\n%s*v%s+[%-%d%.]") then + return 0.6 + end + if string.find(head, "^#") and (string.find(head, "\nmtllib ") or string.find(head, "\no ") or string.find(head, "\ng ")) then + return 0.4 + end + return 0 +end +end + +do -- model/off +local Bytes = __include("core/Bytes") +S["model/off"] = function(r) +local head = r:peek(512) + for _ = 1, 16 do + local rest = string.match(head, "^%s*#[^\n]*\n(.*)$") + if not rest then + break + end + head = rest + end + local kw = string.match(head, "^%s*(%w+)") + if kw and string.match(kw, "^S?T?C?N?4?n?OFF$") then + return 0.9 + end + return 0 +end +end + +do -- model/ply +local Bytes = __include("core/Bytes") +S["model/ply"] = function(r) +local h = r:peek(4) + return (h == "ply\n" or h == "ply\r" )and 1 or 0 +end +end + +do -- model/pmx +local Bytes = __include("core/Bytes") +S["model/pmx"] = function(r) +local head = r:peek(8) + if string.sub(head, 1, 4) == "PMX " then + return 1 + end + if string.sub(head, 1, 7) == "Pmd\0\0\128\63" then + return 1 + end + return 0 +end +end + +do -- model/proc +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/proc"] = function(r) +local head = Sniff.text(r, 64, true) + if string.match(head, "^mapProcFile%d%d%d") then + return 1 + end + if string.match(head, '^"?PROC"?%s+"?%d') then + return 0.9 + end + return 0 +end +end + +do -- model/qb +local Bytes = __include("core/Bytes") +S["model/qb"] = function(r) +if r:remaining() < 24 or r:peek(4) ~= "\1\1\0\0" then + return 0 + end + local b, p = r.buf, r.pos + local fmt, z, comp, mask = buffer.readu32(b, p + 4), buffer.readu32(b, p + 8), buffer.readu32(b, p + 12), buffer.readu32(b, p + 16) + if fmt > 1 or z > 1 or comp > 1 or mask > 1 then + return 0 + end + return 0.9 +end +end + +do -- model/rbxm +local Bytes = __include("core/Bytes") +local MAGIC = "]*%?>", "") + if match(head, "^%s*]") then + return find(head, "version=", 1, true) and 1 or 0.8 + end + return 0 +end +end + +do -- model/robloxmesh +local Bytes = __include("core/Bytes") +S["model/robloxmesh"] = function(r) +return string.match(r:peek(13), "^version [1-7]%.%d%d[\r\n]") and 1 or 0 +end +end + +do -- model/schematic +local Bytes = __include("core/Bytes") +local Nbt = lazy(function() + return __include("codecs/text/Nbt") +end) +local LITEMATIC_HINTS = { "Regions", "EnclosingSize", "RegionCount", "TotalVolume", "MinecraftDataVersion" } +local SPONGE_HINTS = { "BlockData", "PaletteMax" } -- v1 / v2 fields (some writers leave the root unnamed) +local function hinted(head, hints) +for _, h in __iter(hints) do + if string.find(head, string.char(0, #h) .. h, 1, true) then + return true + end + end + return false +end +S["model/schematic"] = function(r) +local p = Nbt.peek(r.buf, r.base, r.limit - r.base) + if not p or p.rootType ~= "compound" or p.endian ~= "big" then + return 0 + end + if p.name == "Schematic" or (p.firstName == "Schematic" and p.firstType == "compound") then + return 1 + end + local head = buffer.tostring(p.head) + return (hinted(head, LITEMATIC_HINTS) or hinted(head, SPONGE_HINTS) )and 1 or 0 +end +end + +do -- model/smd +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/smd"] = function(r) +local head = Sniff.text(r, 256, true) + head = string.gsub(head, "^//[^\n]*\n%s*", "") + if string.match(head, "^version%s+1%s") and string.find(head, "nodes", 1, true) then + return 0.9 + end + return 0 +end +end + +do -- model/sourcemdl +local Bytes = __include("core/Bytes") +S["model/sourcemdl"] = function(r) +if r.limit - r.base < 8 or r:peek(4) ~= "IDST" then + return 0 + end + local v = buffer.readi32(r.buf, r.base + 4) + return v >= 44 and v <= 49 and 1 or 0 +end +end + +do -- model/stl +local Bytes = __include("core/Bytes") +local function lower5(s) +return string.lower(s) == "solid" +end +S["model/stl"] = function(r) +local size = r:remaining() + if size >= 84 then + local c = r:peek(4, 80) + local n = string.byte(c, 1) + string.byte(c, 2) * 256 + string.byte(c, 3) * 65536 + string.byte(c, 4) * 16777216 + if 84 + 50 * n == size then + return 0.9 + end + end + local head = r:peek(512) + local s = string.match(head, "^%s*(%a+)") + if s and lower5(s) then + local l = string.lower(head) + return (string.find(l, "facet", 1, true) or string.find(l, "endsolid", 1, true) )and 0.9 or 0.5 + end + return 0 +end +end + +do -- model/t3d +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/t3d"] = function(r) +local h = Sniff.text(r, 512) + local first = string.match(h, "^%s*(Begin%s+%a+)") + if first == nil then + return 0 + end + local kind = string.lower(string.match(first, "%a+$") or "") + if kind == "map" or kind == "actor" or kind == "level" or kind == "brush" or kind == "polylist" then + return 0.9 + end + return 0.3 +end +end + +do -- model/udmf +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/udmf"] = function(r) +local head = Sniff.text(r, 1024, true) + for _ = 1, 32 do + local rest = string.match(head, "^//[^\n]*\n%s*(.*)$") or string.match(head, "^/%*.-%*/%s*(.*)$") + if not rest then + break + end + head = rest + end + if string.match(head, "^[Nn][Aa][Mm][Ee][Ss][Pp][Aa][Cc][Ee]%s*=%s*\"") then + return 0.9 + end + return 0 +end +end + +do -- model/usda +local Bytes = __include("core/Bytes") +local function isUsdz(r) +if r:peek(4) ~= "PK\3\4" then + return false + end + local lo, hi = r:peekU8(26), r:peekU8(27) + if lo < 0 or hi < 0 then + return false + end + local nameLen = lo + hi * 256 + local name = string.lower(r:peek(30 + nameLen)) + name = string.sub(name, 31) + return string.find(name, "%.usd[ac]?$") ~= nil +end +S["model/usda"] = function(r) +local head = r:peek(8) + if string.sub(head, 1, 5) == "#usda" or string.sub(head, 1, 8) == "\239\187\191#usda" then + return 1 + end + if head == "PXR-USDC" then + return 0.9 -- USDC magic, so the error says it is unsupported + end + if isUsdz(r) then + return 0.95 + end + return 0 +end +end + +do -- model/vbsp +local Bytes = __include("core/Bytes") +local HEADER = 8 + 64 * 16 + 4 +S["model/vbsp"] = function(r) +if r:remaining() < HEADER or r:peek(4) ~= "VBSP" then + return 0 + end + local v = buffer.readi32(r.buf, r.pos + 4) + return v >= 19 and v <= 21 and 1 or 0.5 +end +end + +do -- model/vmf +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["model/vmf"] = function(r) +local head = Sniff.text(r, 512, true) + if string.find(head, "%z") then + return 0 + end + if string.match(head, "^versioninfo%s*{") or string.match(head, '^"versioninfo"%s*{') then + return 0.9 + end + if string.match(head, "^world%s*{") or string.match(head, "^visgroups%s*{") then + return 0.6 + end + return 0 +end +end + +do -- model/vox +local Bytes = __include("core/Bytes") +S["model/vox"] = function(r) +return r:peek(4) == "VOX " and r:peek(4, 8) == "MAIN" and 1 or(r:peek(4) == "VOX " and 0.8 or 0 +)end +end + +do -- model/vrml +local Bytes = __include("core/Bytes") +S["model/vrml"] = function(r) +local head = r:peek(16) + if string.sub(head, 1, 3) == "\239\187\191" then + head = string.sub(head, 4) + end + return string.sub(head, 1, 10) == "#VRML V2.0" and 1 or(string.sub(head, 1, 6) == "#VRML " and 0.6 or 0 +)end +end + +do -- model/x +local Bytes = __include("core/Bytes") +local ENCODINGS = { ["txt "] = "text", ["bin "] = "binary", tzip = "text", bzip = "binary" } +S["model/x"] = function(r) +if r:peek(4) ~= "xof " then + return 0 + end + return ENCODINGS[r:peek(4, 8)] and 1 or 0.5 +end +end + +do -- model/x3d +local Bytes = __include("core/Bytes") +S["model/x3d"] = function(r) +local head = r:peek(1024) + if string.sub(head, 1, 3) == "\239\187\191" then + head = string.sub(head, 4) + end + if string.sub(head, 1, 5) == "#X3D " then + return 1 + end + if string.sub(head, 1, 4) == "\224\0\0\1" and string.find(head, "x3d", 1, true) then + return 0.9 + end + if string.find(head, "]") or string.find(head, "", 1, true) or (string.find(head, "", 1, true)) then + return string.find(r:peek(512), "= 64 then + local lfanew = string.byte(h, 61) + string.byte(h, 62) * 256 + string.byte(h, 63) * 65536 + local sig = r:peek(2, lfanew) + return sig == "NE" and 0.6 or(sig == "PE" and 0.2 or 0 +) end + if isFnt(h) and #h >= 6 then + local size = string.byte(h, 3) + string.byte(h, 4) * 256 + string.byte(h, 5) * 65536 + string.byte(h, 6) * 16777216 + return size == r:size() and 0.9 or(size <= r:size() and size > 118 and 0.3 or 0 +) end + return 0 +end +end + +do -- font/hershey +local Bytes = __include("core/Bytes") +local function header(line) +if #line < 10 then + return nil, nil + end + local id = tonumber((string.gsub(string.sub(line, 1, 5), "^%s+", ""))) + local n = tonumber((string.gsub(string.sub(line, 6, 8), "^%s+", ""))) + if not id or not n or n < 1 or string.find(string.sub(line, 1, 8), "[^%d ]") then + return nil, nil + end + return id, n +end +S["font/hershey"] = function(r) +local head = r:peek(256) + local line = string.match(head, "^([^\r\n]*)") + local id, n = header(line or "") + if not id or not n then + return 0 + end + local body = string.sub(line , 9) + if string.find(body, "[^ -~]") then + return 0 + end + return (#body == math.min(2 * n, 64) or #body == 2 * n )and 0.7 or 0.3 +end +end + +do -- font/pcf +local Bytes = __include("core/Bytes") +S["font/pcf"] = function(r) +return r:peek(4) == "\1fcp" and 1 or 0 +end +end + +do -- font/psf +local Bytes = __include("core/Bytes") +S["font/psf"] = function(r) +local h = r:peek(4) + if h == "\114\181\74\134" then + return 1 + end + if string.sub(h, 1, 2) == "\54\4" and #h >= 4 and string.byte(h, 3) <= 7 and string.byte(h, 4) > 0 then + return 0.9 + end + return 0 +end +end + +do -- font/ttf +local Bytes = __include("core/Bytes") +S["font/ttf"] = function(r) +local m = r:peek(4) + if m == "\0\1\0\0" or m == "OTTO" or m == "ttcf" or m == "true" then + return 0.9 + end + return 0 +end +end + +do -- font/type1 +local Bytes = __include("core/Bytes") +S["font/type1"] = function(r) +local h = r:peek(64) + if string.sub(h, 1, 2) == "\128\1" then + h = string.sub(h, 7) + end + if string.sub(h, 1, 14) == "%!PS-AdobeFont" or string.sub(h, 1, 10) == "%!FontType" then + return 1 + end + return 0 +end +end + +do -- font/woff +local Bytes = __include("core/Bytes") +S["font/woff"] = function(r) +return r:peek(4) == "wOFF" and 1 or 0 +end +end + +do -- font/woff2 +local Bytes = __include("core/Bytes") +S["font/woff2"] = function(r) +return r:peek(4) == "wOF2" and 1 or 0 +end +end + +do -- archive/7z +local Bytes = __include("core/Bytes") +local MAGIC = "7z\188\175\39\28" +S["archive/7z"] = function(r) +return r:peek(6) == MAGIC and 1 or 0 +end +end + +do -- archive/adf +local Bytes = __include("core/Bytes") +local BS = 512 +S["archive/adf"] = function(r) +local n = r:size() + if n < 4 * BS or n % BS ~= 0 then + return 0 + end + local h = r:peek(4) + if string.sub(h, 1, 3) ~= "DOS" or string.byte(h, 4) > 5 then + return 0 + end + return (n == 901120 or n == 1802240 )and 0.95 or 0.6 +end +end + +do -- archive/applesingle +local Bytes = __include("core/Bytes") +S["archive/applesingle"] = function(r) +local h = r:peek(8) + if #h < 8 then + return 0 + end + local magic = string.sub(h, 1, 4) + local ver = string.sub(h, 5, 8) + if (magic == "\0\5\22\0" or magic == "\0\5\22\7") and (ver == "\0\1\0\0" or ver == "\0\2\0\0") then + return 1 + end + return 0 +end +end + +do -- archive/ar +local Bytes = __include("core/Bytes") +local MAGIC = "!\n" +S["archive/ar"] = function(r) +if r:peek(8) == MAGIC then + return r:peek(13, 68) == "debian-binary" and 1 or 0.9 + end + return r:peek(8) == "!\n" and 0.5 or 0 +end +end + +do -- archive/arj +local Bytes = __include("core/Bytes") +S["archive/arj"] = function(r) +local h = r:peek(4) + if #h == 4 and string.byte(h, 1) == 0x60 and string.byte(h, 2) == 0xEA then + local size = string.byte(h, 3) + string.byte(h, 4) * 256 + return size > 0 and size <= 2600 and 0.9 or 0 + end + return 0 +end +end + +do -- archive/binhex +local Bytes = __include("core/Bytes") +local BANNER = "(This file must be converted with BinHex" +S["archive/binhex"] = function(r) +local head = r:peek(2048) + local at = string.find(head, BANNER, 1, true) + if not at then + return 0 + end + return at == 1 and 1 or 0.8 +end +end + +do -- archive/br +local Err = __include("core/Err") +local Bytes = __include("core/Bytes") +local Brotli = lazy(function() + return __include("codecs/compress/Brotli") +end) +local SNIFF_WHOLE = 262144 -- streams up to this size are decoded whole by sniff +local SNIFF_PREFIX = 65536 +S["archive/br"] = function(r) +local n = r:remaining() + if n == 0 then + return 0 + end + if n <= SNIFF_WHOLE then + local out, consumed = Brotli.decompress(r.buf, r.pos, n, { maxBytes = 2 ^ 26 }) + if out and consumed == r.limit then + return buffer.len(out) > 0 and 0.3 or 0.05 + end + return 0 + end + local _, err = Brotli.decompress(r.buf, r.pos, SNIFF_PREFIX, { maxBytes = 2 ^ 22 }) + if err and (err.code == Err.TRUNCATED or err.code == Err.LIMIT) then + return 0.05 + end + return 0 +end +end + +do -- archive/bz2 +local Bytes = __include("core/Bytes") +S["archive/bz2"] = function(r) +local h = r:peek(10) + if #h < 10 or string.sub(h, 1, 3) ~= "BZh" then + return 0 + end + local lv = string.byte(h, 4) + if lv < 0x31 or lv > 0x39 then + return 0 + end + local magic = string.sub(h, 5, 10) + if magic == "\x31\x41\x59\x26\x53\x59" or magic == "\x17\x72\x45\x38\x50\x90" then + return 1 + end + return 0 +end +end + +do -- archive/cab +local Bytes = __include("core/Bytes") +S["archive/cab"] = function(r) +if r:peek(8) == "MSCF\0\0\0\0" then + return 1 + end + return 0 +end +end + +do -- archive/cpio +local Bytes = __include("core/Bytes") +S["archive/cpio"] = function(r) +local m = r:peek(6) + if m == "070701" or m == "070702" or m == "070707" then + return 1 + end + local b2 = r:peek(2) + if (b2 == "\199\113" or b2 == "\113\199") and r:remaining() >= 26 then + return 0.5 + end + return 0 +end +end + +do -- archive/d64 +local Bytes = __include("core/Bytes") + +local function geometry(kind, tracks) +local offsets, spt = {}, {} + local o = 0 + for t = 1, tracks do + local n + if kind == "d81" then + n = 40 + else + local s = (kind == "d71" and t > 35 and((t - 35 ))or(t +)) n = s <= 17 and 21 or(s <= 24 and 19 or(s <= 30 and 18 or 17 +)) end + offsets[t], spt[t] = o, n + o =o+ n * 256 + end + return { kind = kind, tracks = tracks, offsets = offsets, spt = spt, dirTrack = kind == "d81" and 40 or 18, total = o } +end +local function detect(len) +for _, g in __iter({ { "d64", 35 }, { "d64", 40 }, { "d64", 42 }, { "d71", 70 }, { "d81", 80 } }) do + local geo = geometry(g[1] , g[2] ) + local sectors = math.floor(geo.total / 256 +) if len == geo.total or (g[1] ~= "d81" and len == geo.total + sectors) then + return geo + end + end + return nil +end +S["archive/d64"] = function(r) +local geo = detect(r:size()) + if not geo then + return 0 + end + -- the BAM / header sector: dir track link and DOS version byte + local h = r:sub(geo.offsets[geo.dirTrack], 256) + local t, s, v = h:u8(), h:u8(), h:u8() + if geo.kind == "d81" then + return t == 40 and s == 3 and v == 0x44 and 0.9 or 0.3 + end + return t == 18 and s == 1 and (v == 0x41 or v == 0) and 0.9 or 0.3 +end +end + +do -- archive/fat +local Bytes = __include("core/Bytes") +local Fat = lazy(function() + return __include("containers/Fat") +end) +S["archive/fat"] = function(r) +if r:remaining() < 512 then + return 0 + end + local v = Fat.open(r.buf, r.base + r.pos, r.limit - r.base - r.pos) + if not v then + return 0 + end + return v.partition and 0.6 or 0.8 +end +end + +do -- archive/grp +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +local MAGIC = "KenSilverman" +S["archive/grp"] = function(r) +return Sniff.magic(r, MAGIC) +end +end + +do -- archive/gzip +local Bytes = __include("core/Bytes") +S["archive/gzip"] = function(r) +return r:peek(3) == "\31\139\8" and 1 or 0 +end +end + +do -- archive/iso +local Bytes = __include("core/Bytes") +S["archive/iso"] = function(r) +return r:peek(5, 16 * 2048 + 1) == "CD001" and 1 or 0 +end +end + +do -- archive/lha +local Bytes = __include("core/Bytes") +local METHODS= { + ["-lh0-"] = true, ["-lz4-"] = true, ["-lhd-"] = true, ["-lh1-"] = true, ["-lh4-"] = true, ["-lh5-"] = true, + ["-lh6-"] = true, ["-lh7-"] = true, ["-lhx-"] = true, ["-lzs-"] = true, ["-lz5-"] = true, ["-lh2-"] = true, + ["-lh3-"] = true, ["-pm0-"] = true, ["-pm1-"] = true, ["-pm2-"] = true, ["-lk7-"] = true, +} +local function isHeader(s) +if #s < 22 then + return false + end + local m = string.sub(s, 3, 7) + local level = string.byte(s, 21) + return METHODS[m] == true and level <= 3 +end +S["archive/lha"] = function(r) +if isHeader(r:peek(22)) then + return 0.95 + end + return 0 +end +end + +do -- archive/lz4 +local Bytes = __include("core/Bytes") +S["archive/lz4"] = function(r) +local m = r:peek(4) + if m == "\4\34\77\24" then + return 1 + elseif m == "\2\33\76\24" then + return 0.9 + elseif #m == 4 and string.byte(m, 1) >= 0x50 and string.byte(m, 1) <= 0x5F and string.sub(m, 2) == "\42\77\24" then + -- a skippable frame (zstd shares the magic): an LZ4 frame after it + local h = r:peek(4, 4) + if #h == 4 then + local n = string.byte(h, 1) + string.byte(h, 2) * 256 + string.byte(h, 3) * 65536 + string.byte(h, 4) * 16777216 + if r:peek(4, 8 + n) == "\4\34\77\24" then + return 1 + end + end + end + return 0 +end +end + +do -- archive/macbinary +local Bytes = __include("core/Bytes") +local Crc16 = __include("core/Crc16") +local function version(b, o, len) +if len < 128 then + return nil + end + local u8 = function(i) +return buffer.readu8(b, o + i) + end + if u8(0) ~= 0 or u8(74) ~= 0 then + return nil + end + local nameLen = u8(1) + if nameLen < 1 or nameLen > 63 then + return nil + end + local function be32(i) +return u8(i) * 16777216 + u8(i + 1) * 65536 + u8(i + 2) * 256 + u8(i + 3) + end + local dlen, rlen = be32(83), be32(87) + if dlen > 0x7FFFFFFF or rlen > 0x7FFFFFFF then + return nil + end + local crc = u8(124) * 256 + u8(125) + if crc == Crc16.ccitt(b, o, 124) and (crc ~= 0 or u8(122) >= 129) then + return buffer.readstring(b, o + 102, 4) == "mBIN" and"III" or"II" + end + if buffer.readstring(b, o + 102, 4) == "mBIN" then + return nil -- III with a bad CRC + end + -- MacBinary I: byte 82 zero, bytes 99..125 zero, the forks within the file + if u8(82) ~= 0 then + return nil + end + for i = 99, 125 do + if u8(i) ~= 0 then + return nil + end + end + local need = 128 + math.ceil(dlen / 128) * 128 + rlen + return need <= len + 127 and"I" or nil +end +S["archive/macbinary"] = function(r) +local n = math.min(r:remaining(), 128) + if n < 128 then + return 0 + end + local v = version(r.buf, r.base + r.pos, r.limit - r.base - r.pos) + return v == "III" and 0.95 or(v == "II" and 0.8 or(v == "I" and 0.3 or 0 +))end +end + +do -- archive/mpq +local Bytes = __include("core/Bytes") +S["archive/mpq"] = function(r) +local m = r:peek(4) + if m == "MPQ\x1A" or m == "MPQ\x1B" then + return 1 + end + -- a prefixed archive (an installer stub): the header on a 512-byte boundary in the first 64 KB + for at = 512, math.min(65536, r:remaining() - 32), 512 do + if r:peek(4, at) == "MPQ\x1A" then + return 0.6 + end + end + return 0 +end +end + +do -- archive/pak +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["archive/pak"] = function(r) +if r:remaining() < 12 then + return 0 + end + return math.max(Sniff.magic(r, "PACK", 0, 0.9), Sniff.magic(r, "SPAK", 0, 0.9)) +end +end + +do -- archive/rpm +local Bytes = __include("core/Bytes") +local LEAD_MAGIC = "\237\171\238\219" +S["archive/rpm"] = function(r) +return r:peek(4) == LEAD_MAGIC and 1 or 0 +end +end + +do -- archive/tar +local Bytes = __include("core/Bytes") +local Tar = lazy(function() + return __include("containers/Tar") +end) +S["archive/tar"] = function(r) +if r:remaining() < 512 then + return 0 + end + if not Tar.valid(r.buf, r.pos) then + return 0 + end + return r:peek(5, 257) == "ustar" and 0.95 or 0.6 +end +end + +do -- archive/unitypackage +local Bytes = __include("core/Bytes") +local Deflate = lazy(function() + return __include("codecs/compress/Deflate") +end) +local Tar = lazy(function() + return __include("containers/Tar") +end) +local function guidOf(name) +local n = string.gsub(name, "^%./", "") + local guid, rest = string.match(n, "^(%x+)/?(.*)$") + if guid and #guid == 32 then + return string.lower(guid), rest + end + return nil, nil +end +S["archive/unitypackage"] = function(r) +if r:peek(3) ~= "\31\139\8" then + return 0 + end + local head = Deflate.peek(r.buf, r.pos, r.limit - r.pos, 512) + if not head or buffer.len(head) < 512 or not Tar.valid(head, 0) then + return 0 + end + local z = 0 + while z < 100 and buffer.readu8(head, z) ~= 0 do + z =z+ 1 + end + return guidOf(buffer.readstring(head, 0, z)) and 1 or 0 -- ties with archive/gzip go to the extension +end +end + +do -- archive/uu +local Bytes = __include("core/Bytes") +S["archive/uu"] = function(r) +local head = r:peek(4096) + if string.match(head, "^begin%-base64 [0-7]+ [^\r\n]") or string.match(head, "^begin [0-7]+ [^\r\n]") then + return 0.9 + end + if string.match(head, "\nbegin%-base64 [0-7]+ [^\r\n]") or string.match(head, "\nbegin [0-7][0-7][0-7]+ [^\r\n]") then + return 0.5 + end + return 0 +end +end + +do -- archive/vpk +local Bytes = __include("core/Bytes") +S["archive/vpk"] = function(r) +if r:remaining() < 12 or r:peek(4) ~= "\x34\x12\xAA\x55" then + return 0 + end + local v = r:peekU8(4) + return (v == 1 or v == 2 )and 1 or 0.5 +end +end + +do -- archive/vswap +local Bytes = __include("core/Bytes") +local readu8, readu16, readi16, writeu32 = buffer.readu8, buffer.readu16, buffer.readi16, buffer.writeu32 +local function header(r) +if r:remaining() < 6 then + return nil, 0, 0 + end + local n, ss, so = readu16(r.buf, r.base), readu16(r.buf, r.base + 2), readu16(r.buf, r.base + 4) + if n == 0 or ss > so or so > n or 6 + n * 6 > r:remaining() then + return nil, 0, 0 + end + return n, ss, so +end +S["archive/vswap"] = function(r) +local n = header(r) + if not n then + return 0 + end + local size = r.limit - r.base + local b = r.buf + local last = 6 + n * 6 + local nonzero = 0 + for i = 0, n - 1 do + local o = buffer.readu32(b, r.base + 6 + i * 4) + local l = readu16(b, r.base + 6 + n * 4 + i * 2) + if o ~= 0 then + if o < last or o + l > size then + return 0 + end + last = o + nonzero =nonzero+ 1 + end + end + return nonzero > 0 and 0.6 or 0 +end +end + +do -- archive/wad +local Bytes = __include("core/Bytes") +S["archive/wad"] = function(r) +if r:remaining() < 12 then + return 0 + end + local m = r:peek(4) + if m ~= "IWAD" and m ~= "PWAD" then + return 0 + end + return 0.9 +end +end + +do -- archive/wad2 +local Bytes = __include("core/Bytes") +S["archive/wad2"] = function(r) +if r:remaining() < 12 then + return 0 + end + local m = r:peek(4) + return (m == "WAD2" or m == "WAD3" )and 0.9 or 0 +end +end + +do -- archive/xz +local Bytes = __include("core/Bytes") +local XZ_MAGIC = "\253" .. "7zXZ\0" +local function aloneScore(r) +local h = r:peek(14) + if #h < 14 then + return 0 + end + local d = string.byte(h, 1) + if d >= 225 or string.byte(h, 14) ~= 0 then + return 0 + end + local dict = string.byte(h, 2) + string.byte(h, 3) * 256 + string.byte(h, 4) * 65536 + string.byte(h, 5) * 16777216 + local okDict = false + for n = 12, 31 do + if dict == 2 ^ n or (n < 31 and dict == 2 ^ n + 2 ^ (n - 1)) then + okDict = true + break + end + end + if not okDict then + return 0 + end + local s = string.sub(h, 6, 13) + if s ~= string.rep("\255", 8) and (string.byte(h, 11) ~= 0 or string.byte(h, 12) ~= 0 or string.byte(h, 13) ~= 0) then + return 0 + end + return d == 0x5D and 0.4 or 0.2 +end +S["archive/xz"] = function(r) +if r:peek(6) == XZ_MAGIC then + return 1 + end + return aloneScore(r) +end +end + +do -- archive/yenc +local Bytes = __include("core/Bytes") +S["archive/yenc"] = function(r) +local head = r:peek(4096) + if string.match(head, "^=ybegin ") then + return 0.95 + end + return string.find(head, "\n=ybegin [^\n]*name=") and 0.6 or 0 +end +end + +do -- archive/z +local Bytes = __include("core/Bytes") +S["archive/z"] = function(r) +if r:peek(2) ~= "\31\157" then + return 0 + end + local f = r:peekU8(2) + return f >= 0 and bit32.band(f, 0x60) == 0 and bit32.band(f, 0x1F) >= 9 and bit32.band(f, 0x1F) <= 16 and 1 or 0.3 +end +end + +do -- archive/zip +local Bytes = __include("core/Bytes") +S["archive/zip"] = function(r) +local s = r:peek(4) + -- ZIP-based formats (docx, jar, 3mf, ...) score higher in their own sniff + if s == "PK\3\4" or s == "PK\5\6" then + return 0.6 + end + if string.sub(s, 1, 2) == "MZ" then + return 0 -- a self-extractor opens with Zip.decode / opts.format = "zip" + end + return 0 +end +end + +do -- archive/zoo +local Bytes = __include("core/Bytes") +local TAG = 0xFDC4A7DC +S["archive/zoo"] = function(r) +local h = r:peek(24) + if #h < 24 then + return 0 + end + local tag = string.byte(h, 21) + string.byte(h, 22) * 256 + string.byte(h, 23) * 65536 + string.byte(h, 24) * 16777216 + if tag ~= TAG then + return 0 + end + return string.sub(h, 1, 4) == "ZOO " and 1 or 0.8 +end +end + +do -- archive/zst +local Bytes = __include("core/Bytes") +local Zstd = lazy(function() + return __include("codecs/compress/Zstd") +end) +S["archive/zst"] = function(r) +local m = r:peek(4) + if m == Zstd.MAGIC then + return 1 + end + -- a skippable frame (0x184D2A50 .. 0x184D2A5F) is usually followed by a zstd frame + if #m == 4 and string.sub(m, 2, 4) == "\42\77\24" and bit32.band(string.byte(m, 1), 0xF0) == 0x50 then + return 0.5 + end + return 0 +end +end + +do -- data/cbor +local Bytes = __include("core/Bytes") +S["data/cbor"] = function(r) +return r:peek(3) == "\217\217\247" and 1 or 0 +end +end + +do -- data/csv +local Bytes = __include("core/Bytes") +local find, sub, byte, gsub = string.find, string.sub, string.byte, string.gsub +S["data/csv"] = function(r) +local head = r:peek(1024) + if find(head, "%z") then + return 0 + end + local l1, l2 = string.match(head, "^([^\r\n]*)\r?\n([^\r\n]*)") + if not l1 or l1 == "" then + return 0 + end + for _, d in __iter({ ",", "\t", ";" }) do + local _, c1 = gsub(l1, d, "") + local _, c2 = gsub(l2 , d, "") + if c1 > 0 and c1 == c2 then + return 0.15 + end + end + return 0 +end +end + +do -- data/ini +local Bytes = __include("core/Bytes") +S["data/ini"] = function(r) +local head = r:peek(512) + if string.find(head, "%z") then + return 0 + end + local first = string.match(head, "^[%s]*([^\r\n]*)") + while first and string.match(first, "^[;#]") do + head = string.match(head, "^[^\n]*\n(.*)$") or "" + first = string.match(head, "^[%s]*([^\r\n]*)") + end + if first and string.match(first, "^%[[^%]]+%]%s*$") then + return 0.2 + end + return 0 +end +end + +do -- data/json +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["data/json"] = function(r) +local head = Sniff.text(r, 64) + local first = string.match(head, "^[ \t\r\n]*(.)") + if first == "{" then + local nxt = string.match(head, "^[^{]*{[ \t\r\n]*(.)") + return (nxt == nil or nxt == '"' or nxt == "}" )and 0.6 or 0.1 + elseif first == "[" then + -- past any nested '[': a JSON value must start (TOML / INI "[section]" and "[[table]]" do not) + local nxt = string.match(head, "^[ \t\r\n]*[%[ \t\r\n]*(.)") + if nxt == nil or string.find('{"-0123456789tfn]', nxt, 1, true) then + return 0.3 + end + return 0 + end + return 0 +end +end + +do -- data/msgpack +local Bytes = __include("core/Bytes") +S["data/msgpack"] = function(_r) +return 0 -- no magic: by extension or opts.format only +end +end + +do -- data/nbt +local Bytes = __include("core/Bytes") +local Nbt = lazy(function() + return __include("codecs/text/Nbt") +end) +S["data/nbt"] = function(r) +local p = Nbt.peek(r.buf, r.base, r.limit - r.base) + if not p or p.rootType ~= "compound" then + return 0 + end + if p.compression ~= "none" then + return p.firstType and 1 or 0.5 -- gzip wrapped NBT: ties with archive/gzip go to the extension + end + return p.firstType and p.firstName and 0.6 or 0.2 +end +end + +do -- data/plist +local Bytes = __include("core/Bytes") +S["data/plist"] = function(r) +local head = r:peek(256) + if string.sub(head, 1, 6) == "bplist" then + return 1 + end + if string.find(head, " 0 and good == lines and paths > 0 and 0.5 or 0 +end +end + +do -- data/snbt +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["data/snbt"] = function(r) -- SNBT has what JSON never has: unquoted keys, typed numbers (1b, 2.5f), [I; arrays, single-quoted strings + +local head = Sniff.text(r, 512, true) + local first = string.sub(head, 1, 1) + if first ~= "{" and first ~= "[" then + return 0 + end + if string.find(head, "[{,]%s*[%a_][%w_%-%.%+]*%s*:") or string.find(head, "%d[bBsSlLfFdD]%s*[,}%]]") + or string.find(head, "%[[BIL]%s*;") or string.find(head, "[:,%[]%s*'") + then + return 0.7 + end + return 0 +end +end + +do -- data/toml +local Bytes = __include("core/Bytes") +S["data/toml"] = function(r) +local head = r:peek(512) + if string.find(head, "%z") then + return 0 + end + for line in __iter(string.gmatch(head, "[^\n]+")) do + local l = (string.match(line, "^[ \t]*(.-)[ \t\r]*$") ) +if l ~= "" and string.sub(l, 1, 1) ~= "#" then + if string.match(l, "^%[%[?[%w_%-%.\"' ]+%]%]?$") or string.match(l, "^[%w_%-%.\"']+[ \t]*=[ \t]*[\"'%[{%dtf%+%-in]") then + return 0.2 + end + return 0 + end + end + return 0 +end +end + +do -- data/tres +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["data/tres"] = function(r) +local h = Sniff.text(r, 256) + if string.match(h, "^%s*%[gd_resource[%s%]]") then + return 1 + end + return 0 +end +end + +do -- data/vdf +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +local KeyValues = lazy(function() + return __include("codecs/text/KeyValues") +end) +S["data/vdf"] = function(r) +local n = r:remaining() + if KeyValues.isBinary(r.buf, r.pos, n) then + return 0.3 + end + local head = Sniff.text(r, 256, true) + if string.find(head, "%z") then + return 0 + end + head = string.gsub(head, "^//[^\n]*\n%s*", "") + if string.match(head, '^"[^"\n]+"%s*{') or string.match(head, '^"[^"\n]+"%s*%[[^%]\n]*%]%s*{') then + return 0.6 + end + if string.match(head, "^#base%s") or string.match(head, "^#include%s") then + return 0.5 + end + if string.match(head, '^[%w_]+%s*\n%s*{%s*\n%s*"') then + return 0.3 + end + return 0 +end +end + +do -- data/xml +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["data/xml"] = function(r) +local head = Sniff.text(r, 64) + if string.match(head, "^<%?xml[ \t\r\n]") or string.sub(head, 1, 4) == "\255\254<\0" or string.sub(head, 1, 4) == "\254\255\0<" then + return 0.5 + end + if string.match(head, "^[ \t\r\n]*<[%a!]") then + return 0.3 + end + return 0 +end +end + +do -- data/yaml +local Bytes = __include("core/Bytes") +S["data/yaml"] = function(r) +local head = r:peek(256) + if string.find(head, "%z") then + return 0 + end + if string.match(head, "^%%YAML ") then + return 0.9 + end + if string.match(head, "^%-%-%-[ \r\n]") then + return 0.5 + end + local line = string.match(head, "^[ \t\r\n]*([^\r\n]*)") + if line and (string.match(line, "^[%w_%-\"']+[%w_%- \"']*:[ ]") or string.match(line, "^[%w_%-]+:$") or string.match(line, "^%- ")) then + return 0.2 + end + return 0 +end +end + +do -- vector/gamemaps +local Bytes = __include("core/Bytes") +local MAGIC = "TED5v1.0" +S["vector/gamemaps"] = function(r) +if r:peek(8) == MAGIC then + return 1 + end + -- MAPHEAD: the RLEW tag 0xABCD, then 100 offsets (0 / -1 when absent) + if r:remaining() >= 402 and r:remaining() <= 1024 and buffer.readu16(r.buf, r.base) == 0xABCD then + local first = buffer.readi32(r.buf, r.base + 2) + if first > 0 then + return 0.7 + end + end + return 0 +end +end + +do -- vector/ldtk +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["vector/ldtk"] = function(r) +local h = Sniff.text(r, 1024) + if not string.match(h, "^%s*{") then + return 0 + end + if string.find(h, "\"fileType\"%s*:%s*\"LDtk Project JSON\"") then + return 1 + end + if string.find(h, "\"jsonVersion\"", 1, true) and string.find(h, "\"worldLayout\"", 1, true) then + return 0.8 + end + return 0 +end +end + +do -- vector/ogmo +local Bytes = __include("core/Bytes") +local Sniff = __include("core/Sniff") +S["vector/ogmo"] = function(r) +local h = Sniff.text(r, 2048) + if not string.match(h, "^%s*{") or not string.find(h, "\"ogmoVersion\"", 1, true) then + return 0 + end + if string.find(h, "\"layerGridDefaultSize\"", 1, true) or string.find(h, "\"levelPaths\"", 1, true) then + return 1 + end + return 0.9 +end +end + +do -- vector/svg +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["vector/svg"] = function(r) +local h = Sniff.text(r, 4096) + if not string.match(h, "^%s*<") then + return 0 + end + if string.find(h, ":]") or string.find(h, "<%w+:svg[%s>]") then + return 0.95 + end + return 0 +end +end + +do -- vector/tiled +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +local function head(r) +local h = Sniff.text(r, 1024) + return h +end +S["vector/tiled"] = function(r) +local h = head(r) + if string.match(h, "^%s*<") then + if string.find(h, "]") or string.find(h, "]") then + return 0.9 + end + return 0 + end + if string.match(h, "^%s*{") then + -- Tiled writes its keys sorted: "type" comes last, so look at the tail too + local n = r:remaining() + local tail = (n > 1024 and{(r:peek(1024, n - 1024) )}or{"" +})[1] for _, part in __iter({ h, tail }) do + if string.find(part, "\"type\"%s*:%s*\"map\"") or string.find(part, "\"type\"%s*:%s*\"tileset\"") then + return 0.8 + end + end + if string.find(h, "\"tilewidth\"", 1, true) and (string.find(h, "\"orientation\"", 1, true) or string.find(h, "\"tilesets\"", 1, true)) then + return 0.6 + end + end + return 0 +end +end + +do -- layered/aseprite +local Bytes = __include("core/Bytes") +S["layered/aseprite"] = function(r) +if r:peekU8(4) == 0xE0 and r:peekU8(5) == 0xA5 then + local d = r:peekU8(12) + if (d == 32 or d == 16 or d == 8) and r:peekU8(13) == 0 then + return 1 + end + return 0.5 + end + return 0 +end +end + +do -- layered/ora +local Bytes = __include("core/Bytes") +local MIME = "image/openraster" +S["layered/ora"] = function(r) -- a zip whose first (stored) entry is "mimetype" holding image/openraster + +if r:peek(4) == "PK\3\4" and r:peek(8, 30) == "mimetype" and r:peek(#MIME, 38) == MIME then + return 1 + end + return 0 +end +end + +do -- layered/psd +local Bytes = __include("core/Bytes") +S["layered/psd"] = function(r) +local h = r:peek(6) + if string.sub(h, 1, 4) == "8BPS" and (string.sub(h, 5, 6) == "\0\1" or string.sub(h, 5, 6) == "\0\2") then + return 1 + end + return 0 +end +end + +do -- subtitle/ass +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["subtitle/ass"] = function(r) +local head = Sniff.text(r, 64) + if string.match(head, "^%s*%[[Ss]cript [Ii]nfo%]") then + return 1 + end + return 0 +end +end + +do -- subtitle/srt +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +local TIMING = "^%s*(%d+):(%d%d?):(%d%d?)[,.](%d+)%s*%-%->%s*(%d+):(%d%d?):(%d%d?)[,.](%d+)%s*(.-)%s*$" +local function frac(digits) +return ((tonumber(digits) )) / 10 ^ #digits +end +local function timing(line) +local h1, m1, s1, f1, h2, m2, s2, f2, rest = string.match(line, TIMING) + if not h1 then + return nil, nil, nil + end + local a = (tonumber(h1) )* 3600 + (tonumber(m1) )* 60 + (tonumber(s1) )+ frac(f1 ) + local b = (tonumber(h2) )* 3600 + (tonumber(m2) )* 60 + (tonumber(s2) )+ frac(f2 ) + return a, b, rest +end +S["subtitle/srt"] = function(r) +local head = Sniff.text(r, 512) + head = string.gsub(head, "\r", "\n") + local first, second = string.match(head, "^%s*([^\n]*)\n([^\n]*)") + if first and string.match(first, "^%d+%s*$") and second and timing(second) then + return 0.9 + end + if first and timing(first) then + return 0.6 + end + return 0 +end +end + +do -- subtitle/vtt +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["subtitle/vtt"] = function(r) +local head = Sniff.text(r, 10) + if string.sub(head, 1, 6) == "WEBVTT" then + local c = string.sub(head, 7, 7) + if c == "" or c == " " or c == "\t" or c == "\n" or c == "\r" then + return 1 + end + end + return 0 +end +end + +do -- music/669 +local Bytes = __include("core/Bytes") +local function validHeader(r) +if r:size() < 497 then + return false + end + local magic = r:peek(2) + if magic ~= "if" and magic ~= "JN" then + return false + end + local nsmp, npat, restart = r:peekU8(110), r:peekU8(111), r:peekU8(112) + if nsmp > 64 or restart >= 128 or npat > 128 then + return false + end + local bad = 0 + for i = 2, 109 do + local c = r:peekU8(i) + if c > 0 and c <= 31 then + bad =bad+ 1 + if bad > 40 then + return false + end + end + end + for i = 0, 127 do + local o, t, b = r:peekU8(113 + i), r:peekU8(241 + i), r:peekU8(369 + i) + if (o >= 128 and o < 0xFE) or (o < 128 and t == 0) or t > 15 or b >= 64 then + return false + end + end + return true +end +S["music/669"] = function(r) +return validHeader(r) and 0.6 or 0 +end +end + +do -- music/ahx +local Bytes = __include("core/Bytes") +S["music/ahx"] = function(r) +local m = r:peek(4) + return m and #m == 4 and string.sub(m, 1, 3) == "THX" and string.byte(m, 4) < 3 and 1 or 0 +end +end + +do -- music/far +local Bytes = __include("core/Bytes") +S["music/far"] = function(r) +if r:size() >= 98 and r:peek(4) == "FAR\xFE" and r:peek(3, 44) == "\r\n\x1A" and r:peekU8(47) + r:peekU8(48) * 256 >= 98 then + return 1 + end + return 0 +end +end + +do -- music/hmp +local Bytes = __include("core/Bytes") +local HMI_MAGIC = "HMI-MIDISONG061595" +S["music/hmp"] = function(r) +return (r:peek(8) == "HMIMIDIP" or r:peek(18) == HMI_MAGIC )and 1 or 0 +end +end + +do -- music/hvl +local Bytes = __include("core/Bytes") +S["music/hvl"] = function(r) +local m = r:peek(4) + return m and #m == 4 and string.sub(m, 1, 3) == "HVL" and string.byte(m, 4) <= 1 and 1 or 0 +end +end + +do -- music/it +local Bytes = __include("core/Bytes") +S["music/it"] = function(r) +return r:peek(4) == "IMPM" and 1 or 0 +end +end + +do -- music/med +local Bytes = __include("core/Bytes") +local function validHeader(r) +if r:size() < 52 or r:peek(3) ~= "MMD" then + return false + end + local v = r:peekU8(3) + if v < 0x30 or v > 0x33 then + return false + end + local h = r:sub(8, 44) + local songOff = h:u32be() + h:skip(4) + local blockOff = h:u32be() + h:skip(4) + local smpOff = h:u32be() + return songOff >= 52 and songOff + 63 * 8 + 284 <= r:size() and blockOff >= 52 and (smpOff == 0 or smpOff >= 52) +end +S["music/med"] = function(r) +return validHeader(r) and 1 or 0 +end +end + +do -- music/midi +local Bytes = __include("core/Bytes") +S["music/midi"] = function(r) +if r:peek(4) == "MThd" then + return 1 + end + if r:peek(4) == "RIFF" and r:peek(4, 8) == "RMID" then + return 1 + end + return 0 +end +end + +do -- music/mod +local Bytes = __include("core/Bytes") +local FIXED= { + ["M.K."] = 4, + ["M!K!"] = 4, + ["M&K!"] = 4, + ["N.T."] = 4, + ["FLT4"] = 4, + ["FLT8"] = 8, + ["CD81"] = 8, + ["OKTA"] = 8, + ["OCTA"] = 8, + ["EXO4"] = 4, + ["EXO8"] = 8, +} +local function signatureChannels(sig) +local fixed = FIXED[sig] + if fixed then + return fixed + end + local d = string.match(sig, "^(%d)CHN$") + if d then + local n = (tonumber(d) ) +return (n >= 1 and{n }or{nil +})[1] end + local dd = string.match(sig, "^(%d%d)C[HN]$") + if dd then + local n = (tonumber(dd) ) +return (n >= 1 and n <= 32 and{n }or{nil +})[1] end + local t = string.match(sig, "^TDZ(%d)$") + if t then + local n = (tonumber(t) ) +return (n >= 1 and{n }or{nil +})[1] end + return nil +end +S["music/mod"] = function(r) +if r:size() < 1084 then + return 0 + end + local sig = r:peek(4, 1080) + if signatureChannels(sig) then + return 0.8 + end + return 0 +end +end + +do -- music/mtm +local Bytes = __include("core/Bytes") +S["music/mtm"] = function(r) +if r:size() >= 66 and r:peek(3) == "MTM" and r:peekU8(3) < 0x20 and r:peekU8(33) >= 1 and r:peekU8(33) <= 32 then + return 1 + end + return 0 +end +end + +do -- music/mus +local Bytes = __include("core/Bytes") +S["music/mus"] = function(r) +return r:peek(4) == "MUS\x1a" and 1 or 0 +end +end + +do -- music/okt +local Bytes = __include("core/Bytes") +S["music/okt"] = function(r) +return r:peek(8) == "OKTASONG" and 1 or 0 +end +end + +do -- music/ptm +local Bytes = __include("core/Bytes") +local function validHeader(r) +if r:size() < 608 or r:peek(4, 44) ~= "PTMF" or r:peekU8(28) ~= 26 or r:peekU8(30) > 2 then + return false + end + local h = r:sub(32, 10) + local nord, nsmp, npat, nch, flags = h:u16le(), h:u16le(), h:u16le(), h:u16le(), h:u16le() + return flags == 0 and nch >= 1 and nch <= 32 and nord >= 1 and nord <= 256 and nsmp >= 1 and nsmp <= 255 and npat >= 1 and npat <= 128 +end +S["music/ptm"] = function(r) +return validHeader(r) and 1 or 0 +end +end + +do -- music/s3m +local Bytes = __include("core/Bytes") +S["music/s3m"] = function(r) +if r:size() >= 48 and r:peek(4, 44) == "SCRM" then + return 1 + end + return 0 +end +end + +do -- music/sf2 +local Bytes = __include("core/Bytes") +local SoundFont = lazy(function() + return __include("codecs/audio/SoundFont") +end) +S["music/sf2"] = function(r) +return SoundFont.sniff(r) and 1 or 0 +end +end + +do -- music/stm +local Bytes = __include("core/Bytes") +local function validHeader(r) +if r:size() < 48 then + return false + end + local eof, ftype, major, minor = r:peekU8(28), r:peekU8(29), r:peekU8(30), r:peekU8(31) + local npat, gv = r:peekU8(33), r:peekU8(34) + if ftype ~= 2 or (eof ~= 0x1A and eof ~= 2) or major ~= 2 or (minor ~= 0 and minor ~= 10 and minor ~= 20 and minor ~= 21) then + return false + end + if npat > 64 or (gv > 64 and gv ~= 0x58) then + return false + end + for i = 20, 27 do + local c = r:peekU8(i) + if c < 0x20 or c >= 0x7F then + return false + end + end + return true +end +S["music/stm"] = function(r) +return validHeader(r) and 0.7 or 0 +end +end + +do -- music/ult +local Bytes = __include("core/Bytes") +S["music/ult"] = function(r) +local v = r:peekU8(14) + if r:size() >= 48 and r:peek(14) == "MAS_UTrack_V00" and v >= 0x31 and v <= 0x34 then + return 1 + end + return 0 +end +end + +do -- music/umx +local Bytes = __include("core/Bytes") +local MAGIC = "\xC1\x83\x2A\x9E" + +local function header(r) +if r:size() < 36 or r:peek(4) ~= MAGIC then + return nil + end + local h = r:sub(4, 32) + local version = h:u16le() + h:skip(6) + local hd= { + version = version, + nameCount = h:u32le(), + nameOffset = h:u32le(), + exportCount = h:u32le(), + exportOffset = h:u32le(), + importCount = h:u32le(), + importOffset = h:u32le(), + } + if h.err or hd.nameOffset < 36 or hd.exportOffset < 36 or hd.importOffset < 36 then + return nil + end + if hd.nameCount == 0 or hd.exportCount == 0 or hd.importCount == 0 or hd.nameCount > 2 ^ 20 or hd.exportCount > 2 ^ 20 or hd.importCount > 2 ^ 20 then + return nil + end + return hd +end +local function index(r) +local b = r:u8() + local neg = b >= 0x80 + local v = b % 64 + if bit32.band(b, 0x40) ~= 0 then + local shift = 6 + repeat + b = r:u8() + v =v+ (b % 128) * 2 ^ shift + shift =shift+ 7 + until b < 0x80 or shift >= 32 + end + return (neg and{(-v )}or{v +})[1]end +local function names(r, h) +local list = {} + local nr = r:sub(h.nameOffset) + for _ = 1, math.min(h.nameCount, 65536) do + if nr:remaining() < 5 then + break + end + if h.version >= 64 then + index(nr) + end + table.insert(list, string.lower(nr:cstring(1024))) + nr:skip(4) + end + return list +end +S["music/umx"] = function(r) +local h = header(r) + if not h then + return 0 + end + return table.find(names(r, h), "music") and 1 or 0.3 +end +end + +do -- music/xm +local Bytes = __include("core/Bytes") +local MAGIC = "Extended Module: " +S["music/xm"] = function(r) +return r:peek(17) == MAGIC and 1 or 0 +end +end + +do -- music/xmi +local Bytes = __include("core/Bytes") +S["music/xmi"] = function(r) +local id, kind = r:peek(4), r:peek(4, 8) + if id == "FORM" and (kind == "XDIR" or kind == "XMID") then + return 1 + end + return id == "CAT " and kind == "XMID" and 0.9 or 0 +end +end + +do -- playlist/m3u +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +S["playlist/m3u"] = function(r) +local s = Sniff.text(r, 512) + s = ((string.match(s, "^%s*(.*)$") )) + if string.sub(s, 1, 7) == "#EXTM3U" then + return 0.95 + end + if string.find(s, "^#EXTINF:") or string.find(s, "^#EXT%-X%-") then + return 0.8 + end + return 0 +end +end + +do -- playlist/pls +local Sniff = __include("core/Sniff") +local Bytes = __include("core/Bytes") +local Text = lazy(function() + return __include("codecs/text/Text") +end) +S["playlist/pls"] = function(r) +local s = Sniff.text(r, 64) + local first = string.match(s, "^%s*([^\r\n]*)") + return first and string.lower(Text.trim(first)) == "[playlist]" and 0.95 or 0 +end +end + +do -- playlist/xspf +local Bytes = __include("core/Bytes") +local NS = "http://xspf.org/ns/0/" +S["playlist/xspf"] = function(r) +local s = r:peek(1024) + local i = string.find(s, "<%w*:?playlist[%s>]") + if i and string.find(s, NS, 1, true) then + return 0.95 + end + return 0 +end +end + +return S +end __FILES["Types"] = function() local __compat = __compat local buffer, type, __iter = __compat.buffer, __compat.type, __compat.__iter --!strict -- Types: the standard value types each category decodes to and encodes from, plus small constructors. Every diff --git a/build/rosetta.lua.linemap.json b/build/rosetta.lua.linemap.json index 1f5f820..6397f24 100644 --- a/build/rosetta.lua.linemap.json +++ b/build/rosetta.lua.linemap.json @@ -1,618 +1,619 @@ [ [666, "src/Rosetta/init.luau"], -[1550, "src/Rosetta/Registry.luau"], -[3959, "src/Rosetta/Types.luau"], -[5072, "src/Rosetta/archive/7z/init.luau"], -[5457, "src/Rosetta/archive/7z/Header.luau"], -[5984, "src/Rosetta/archive/adf/init.luau"], -[6266, "src/Rosetta/archive/applesingle/init.luau"], -[6452, "src/Rosetta/archive/ar/init.luau"], -[6855, "src/Rosetta/archive/arj/init.luau"], -[7065, "src/Rosetta/archive/binhex/init.luau"], -[7314, "src/Rosetta/archive/br/init.luau"], -[7389, "src/Rosetta/archive/bz2/init.luau"], -[7453, "src/Rosetta/archive/cab/init.luau"], -[7866, "src/Rosetta/archive/cab/Sum.luau"], -[7907, "src/Rosetta/archive/cpio/init.luau"], -[8075, "src/Rosetta/archive/d64/init.luau"], -[8489, "src/Rosetta/archive/fat/init.luau"], -[8611, "src/Rosetta/archive/grp/init.luau"], -[8725, "src/Rosetta/archive/gzip/init.luau"], -[8910, "src/Rosetta/archive/iso/init.luau"], -[8982, "src/Rosetta/archive/lha/init.luau"], -[9407, "src/Rosetta/archive/lz4/init.luau"], -[9751, "src/Rosetta/archive/macbinary/init.luau"], -[9949, "src/Rosetta/archive/mpq/init.luau"], -[10355, "src/Rosetta/archive/mpq/Crypt.luau"], -[10420, "src/Rosetta/archive/pak/init.luau"], -[10554, "src/Rosetta/archive/rpm/init.luau"], -[10878, "src/Rosetta/archive/tar/init.luau"], -[10996, "src/Rosetta/archive/unitypackage/init.luau"], -[11232, "src/Rosetta/archive/uu/init.luau"], -[11502, "src/Rosetta/archive/vpk/init.luau"], -[11813, "src/Rosetta/archive/vswap/init.luau"], -[12083, "src/Rosetta/archive/wad/init.luau"], -[12537, "src/Rosetta/archive/wad/Picture.luau"], -[12639, "src/Rosetta/archive/wad2/init.luau"], -[12921, "src/Rosetta/archive/xz/init.luau"], -[13021, "src/Rosetta/archive/yenc/init.luau"], -[13293, "src/Rosetta/archive/z/init.luau"], -[13389, "src/Rosetta/archive/zip/init.luau"], -[13608, "src/Rosetta/archive/zoo/init.luau"], -[13804, "src/Rosetta/archive/zst/init.luau"], -[13868, "src/Rosetta/audio/aac/init.luau"], -[14081, "src/Rosetta/audio/ac3/init.luau"], -[14228, "src/Rosetta/audio/adpcm/init.luau"], -[14374, "src/Rosetta/audio/adx/init.luau"], -[14606, "src/Rosetta/audio/aiff/init.luau"], -[14998, "src/Rosetta/audio/ape/init.luau"], -[15127, "src/Rosetta/audio/au/init.luau"], -[15289, "src/Rosetta/audio/brstm/init.luau"], -[15581, "src/Rosetta/audio/caf/init.luau"], -[16248, "src/Rosetta/audio/flac/init.luau"], -[16397, "src/Rosetta/audio/flac/Meta.luau"], -[16619, "src/Rosetta/audio/flac/Stream.luau"], -[16989, "src/Rosetta/audio/m4a/init.luau"], -[17332, "src/Rosetta/audio/mp3/init.luau"], -[17593, "src/Rosetta/audio/mp3/Index.luau"], -[17784, "src/Rosetta/audio/mp3/Stream.luau"], -[18011, "src/Rosetta/audio/mp3/Tags.luau"], -[18323, "src/Rosetta/audio/mpc/init.luau"], -[18418, "src/Rosetta/audio/opus/init.luau"], -[18797, "src/Rosetta/audio/opus/Encode.luau"], -[18909, "src/Rosetta/audio/qoa/init.luau"], -[19090, "src/Rosetta/audio/tta/init.luau"], -[19209, "src/Rosetta/audio/vag/init.luau"], -[19433, "src/Rosetta/audio/voc/init.luau"], -[19709, "src/Rosetta/audio/vorbis/init.luau"], -[20164, "src/Rosetta/audio/vorbis/Encode.luau"], -[20977, "src/Rosetta/audio/wav/init.luau"], -[21598, "src/Rosetta/audio/wav/Codecs.luau"], -[21777, "src/Rosetta/audio/wavpack/init.luau"], -[21985, "src/Rosetta/cad/step/init.luau"], -[22367, "src/Rosetta/cad/step/Brep.luau"], -[22602, "src/Rosetta/cad/step/Parse.luau"], -[23159, "src/Rosetta/cad/step/Write.luau"], -[23407, "src/Rosetta/codecs/audio/Aac/init.luau"], -[23815, "src/Rosetta/codecs/audio/Aac/Decode.luau"], -[24791, "src/Rosetta/codecs/audio/Aac/Ps.luau"], -[25381, "src/Rosetta/codecs/audio/Aac/Sbr.luau"], -[26448, "src/Rosetta/codecs/audio/Aac/SbrBits.luau"], -[26567, "src/Rosetta/codecs/audio/Aac/SbrDct.luau"], -[27809, "src/Rosetta/codecs/audio/Aac/SbrHf.luau"], -[28301, "src/Rosetta/codecs/audio/Aac/SbrQmf.luau"], -[28418, "src/Rosetta/codecs/audio/Aac/SbrTables.luau"], -[28831, "src/Rosetta/codecs/audio/Aac/Tables.luau"], -[29167, "src/Rosetta/codecs/audio/Ac3/init.luau"], -[29327, "src/Rosetta/codecs/audio/Ac3/Decode.luau"], -[30212, "src/Rosetta/codecs/audio/Ac3/Tables.luau"], -[30314, "src/Rosetta/codecs/audio/Adpcm/init.luau"], -[31068, "src/Rosetta/codecs/audio/Adpcm/Decoder.luau"], -[31371, "src/Rosetta/codecs/audio/Alac/init.luau"], -[31606, "src/Rosetta/codecs/audio/Alac/Decode.luau"], -[32025, "src/Rosetta/codecs/audio/Alac/Encode.luau"], -[32437, "src/Rosetta/codecs/audio/Ape/init.luau"], -[32653, "src/Rosetta/codecs/audio/Ape/Decode.luau"], -[33414, "src/Rosetta/codecs/audio/ApeTag.luau"], -[33512, "src/Rosetta/codecs/audio/Flac/init.luau"], -[33524, "src/Rosetta/codecs/audio/Flac/Encode.luau"], -[34473, "src/Rosetta/codecs/audio/Flac/Frame.luau"], -[35093, "src/Rosetta/codecs/audio/Hively/init.luau"], -[35290, "src/Rosetta/codecs/audio/Hively/Load.luau"], -[35540, "src/Rosetta/codecs/audio/Hively/Player.luau"], -[36499, "src/Rosetta/codecs/audio/Hively/Tables.luau"], -[36719, "src/Rosetta/codecs/audio/Mdct/init.luau"], -[36939, "src/Rosetta/codecs/audio/Mdct/Fft.luau"], -[37193, "src/Rosetta/codecs/audio/MidiRender.luau"], -[37540, "src/Rosetta/codecs/audio/Mpa/init.luau"], -[37555, "src/Rosetta/codecs/audio/Mpa/Analysis.luau"], -[37614, "src/Rosetta/codecs/audio/Mpa/Core.luau"], -[39272, "src/Rosetta/codecs/audio/Mpa/EncTables.luau"], -[39565, "src/Rosetta/codecs/audio/Mpa/Encode2.luau"], -[39950, "src/Rosetta/codecs/audio/Mpa/Encode3.luau"], -[40591, "src/Rosetta/codecs/audio/Mpa/Header.luau"], -[40732, "src/Rosetta/codecs/audio/Mpa/Tables.luau"], -[40959, "src/Rosetta/codecs/audio/Musepack/init.luau"], -[41305, "src/Rosetta/codecs/audio/Musepack/Decode.luau"], -[42199, "src/Rosetta/codecs/audio/Musepack/Tables.luau"], -[42578, "src/Rosetta/codecs/audio/Opus/init.luau"], -[42593, "src/Rosetta/codecs/audio/Opus/Celt.luau"], -[44465, "src/Rosetta/codecs/audio/Opus/CeltEncoder.luau"], -[45530, "src/Rosetta/codecs/audio/Opus/CeltTables.luau"], -[45591, "src/Rosetta/codecs/audio/Opus/Decoder.luau"], -[46055, "src/Rosetta/codecs/audio/Opus/Mdct.luau"], -[46406, "src/Rosetta/codecs/audio/Opus/Packet.luau"], -[46639, "src/Rosetta/codecs/audio/Opus/Silk.luau"], -[48681, "src/Rosetta/codecs/audio/Opus/SilkTables.luau"], -[49055, "src/Rosetta/codecs/audio/Pcm/init.luau"], -[49319, "src/Rosetta/codecs/audio/Pcm/Convert.luau"], -[49616, "src/Rosetta/codecs/audio/Qoa/init.luau"], -[49898, "src/Rosetta/codecs/audio/Resample/init.luau"], -[50293, "src/Rosetta/codecs/audio/SoundFont/init.luau"], -[50348, "src/Rosetta/codecs/audio/SoundFont/Fallback.luau"], -[50492, "src/Rosetta/codecs/audio/SoundFont/Parse.luau"], -[51006, "src/Rosetta/codecs/audio/SoundFont/Synth.luau"], -[51805, "src/Rosetta/codecs/audio/Stream.luau"], -[51967, "src/Rosetta/codecs/audio/Tracker/init.luau"], -[52450, "src/Rosetta/codecs/audio/Tracker/Load.luau"], -[52729, "src/Rosetta/codecs/audio/Tracker/Mixer.luau"], -[52976, "src/Rosetta/codecs/audio/Tracker/Pcm.luau"], -[53105, "src/Rosetta/codecs/audio/Tracker/Player.luau"], -[55094, "src/Rosetta/codecs/audio/Tracker/Tables.luau"], -[55211, "src/Rosetta/codecs/audio/Tta/init.luau"], -[55329, "src/Rosetta/codecs/audio/Tta/Decode.luau"], -[55581, "src/Rosetta/codecs/audio/Vorbis/init.luau"], -[55595, "src/Rosetta/codecs/audio/Vorbis/Codebook.luau"], -[55979, "src/Rosetta/codecs/audio/Vorbis/Packet.luau"], -[56552, "src/Rosetta/codecs/audio/Vorbis/Setup.luau"], -[56974, "src/Rosetta/codecs/audio/Vorbis/Tables.luau"], -[57014, "src/Rosetta/codecs/audio/VorbisComment.luau"], -[57067, "src/Rosetta/codecs/audio/WavPack/init.luau"], -[57290, "src/Rosetta/codecs/audio/WavPack/Block.luau"], -[58745, "src/Rosetta/codecs/audio/WavPack/Tables.luau"], -[58808, "src/Rosetta/codecs/compress/Brotli/init.luau"], -[58895, "src/Rosetta/codecs/compress/Brotli/Decode.luau"], -[59871, "src/Rosetta/codecs/compress/Brotli/Static.luau"], -[60739, "src/Rosetta/codecs/compress/Bzip2/init.luau"], -[60783, "src/Rosetta/codecs/compress/Bzip2/Decode.luau"], -[61296, "src/Rosetta/codecs/compress/Deflate/init.luau"], -[61622, "src/Rosetta/codecs/compress/Deflate/Compress.luau"], -[62104, "src/Rosetta/codecs/compress/Deflate/Inflate.luau"], -[62552, "src/Rosetta/codecs/compress/Explode.luau"], -[62748, "src/Rosetta/codecs/compress/Lz4.luau"], -[63017, "src/Rosetta/codecs/compress/Lzh/init.luau"], -[63621, "src/Rosetta/codecs/compress/Lzma/init.luau"], -[64161, "src/Rosetta/codecs/compress/Lzma/Crc64.luau"], -[64228, "src/Rosetta/codecs/compress/Lzma/Decode.luau"], -[64701, "src/Rosetta/codecs/compress/Lzma/Filters.luau"], -[64877, "src/Rosetta/codecs/compress/Lzw/init.luau"], -[65145, "src/Rosetta/codecs/compress/Lzx.luau"], -[65579, "src/Rosetta/codecs/compress/PackBits.luau"], -[65669, "src/Rosetta/codecs/compress/Quantum.luau"], -[65906, "src/Rosetta/codecs/compress/UnixCompress.luau"], -[66210, "src/Rosetta/codecs/compress/Xxh32.luau"], -[66279, "src/Rosetta/codecs/compress/Zstd/init.luau"], -[66336, "src/Rosetta/codecs/compress/Zstd/Decode.luau"], -[67320, "src/Rosetta/codecs/compress/Zstd/Xxh64.luau"], -[67472, "src/Rosetta/codecs/entropy/Huffman.luau"], -[67759, "src/Rosetta/codecs/entropy/RangeCoder/init.luau"], -[67770, "src/Rosetta/codecs/entropy/RangeCoder/Decoder.luau"], -[67991, "src/Rosetta/codecs/entropy/RangeCoder/Encoder.luau"], -[68235, "src/Rosetta/codecs/font/Bitmap.luau"], -[68436, "src/Rosetta/codecs/font/Cff/init.luau"], -[69077, "src/Rosetta/codecs/font/GlyphNames.luau"], -[69227, "src/Rosetta/codecs/font/TrueType/init.luau"], -[69541, "src/Rosetta/codecs/font/TrueType/Glyf.luau"], -[69933, "src/Rosetta/codecs/font/TrueType/Tables.luau"], -[70435, "src/Rosetta/codecs/image/Bcn/init.luau"], -[70542, "src/Rosetta/codecs/image/Bcn/Decode.luau"], -[71026, "src/Rosetta/codecs/image/Bcn/Encode.luau"], -[71455, "src/Rosetta/codecs/image/Blend.luau"], -[71834, "src/Rosetta/codecs/image/Dct/init.luau"], -[72334, "src/Rosetta/codecs/image/Etc.luau"], -[72632, "src/Rosetta/codecs/image/Half.luau"], -[72701, "src/Rosetta/codecs/image/Jpeg/init.luau"], -[73055, "src/Rosetta/codecs/image/Jpeg/Arith.luau"], -[73463, "src/Rosetta/codecs/image/Jpeg/Color.luau"], -[73828, "src/Rosetta/codecs/image/Jpeg/Decode.luau"], -[74593, "src/Rosetta/codecs/image/Jpeg/Encode.luau"], -[75474, "src/Rosetta/codecs/image/Jpeg/Scan.luau"], -[75943, "src/Rosetta/codecs/image/Jpeg/Tables.luau"], -[76021, "src/Rosetta/codecs/image/Jpeg/Yuv.luau"], -[76088, "src/Rosetta/codecs/image/Miptex.luau"], -[76388, "src/Rosetta/codecs/image/Pixels.luau"], -[76708, "src/Rosetta/codecs/image/Quantize/init.luau"], -[77169, "src/Rosetta/codecs/image/Raster.luau"], -[77866, "src/Rosetta/codecs/image/Texel.luau"], -[78239, "src/Rosetta/codecs/image/Texture.luau"], -[78384, "src/Rosetta/codecs/image/Vp8/init.luau"], -[78515, "src/Rosetta/codecs/image/Vp8/Decode.luau"], -[80471, "src/Rosetta/codecs/image/Vp8/Predict.luau"], -[80734, "src/Rosetta/codecs/image/Vp8/Tables.luau"], -[80984, "src/Rosetta/codecs/image/Vp8/Yuv.luau"], -[81126, "src/Rosetta/codecs/image/Vp8L/init.luau"], -[81230, "src/Rosetta/codecs/image/Vp8L/Decode.luau"], -[82170, "src/Rosetta/codecs/image/Vp8L/Encode.luau"], -[83122, "src/Rosetta/codecs/image/Yuv.luau"], -[83427, "src/Rosetta/codecs/model/Brush.luau"], -[84067, "src/Rosetta/codecs/model/Displacement.luau"], -[84216, "src/Rosetta/codecs/model/DoomMap/init.luau"], -[84661, "src/Rosetta/codecs/model/DoomMap/Udmf.luau"], -[84911, "src/Rosetta/codecs/model/Draco/init.luau"], -[85243, "src/Rosetta/codecs/model/Draco/Attributes.luau"], -[85712, "src/Rosetta/codecs/model/Draco/Connectivity.luau"], -[86901, "src/Rosetta/codecs/model/Draco/Int64.luau"], -[87050, "src/Rosetta/codecs/model/Draco/KdTree.luau"], -[87409, "src/Rosetta/codecs/model/Draco/Predict.luau"], -[88371, "src/Rosetta/codecs/model/Draco/Reader.luau"], -[88845, "src/Rosetta/codecs/model/Mat4.luau"], -[89104, "src/Rosetta/codecs/model/MeshFlatten.luau"], -[89632, "src/Rosetta/codecs/model/Minecraft/init.luau"], -[90184, "src/Rosetta/codecs/model/Minecraft/Colors.luau"], -[90263, "src/Rosetta/codecs/model/Minecraft/Legacy.luau"], -[90370, "src/Rosetta/codecs/model/Minecraft/Packed.luau"], -[90576, "src/Rosetta/codecs/model/Patch.luau"], -[90700, "src/Rosetta/codecs/model/Polygon.luau"], -[90934, "src/Rosetta/codecs/model/Rbx/init.luau"], -[91171, "src/Rosetta/codecs/model/Rbx/Binary.luau"], -[91925, "src/Rosetta/codecs/model/Rig.luau"], -[92168, "src/Rosetta/codecs/model/Sampler.luau"], -[92328, "src/Rosetta/codecs/model/SourceAnim.luau"], -[92549, "src/Rosetta/codecs/model/Vrml/init.luau"], -[92697, "src/Rosetta/codecs/model/Vrml/Build.luau"], -[93271, "src/Rosetta/codecs/model/Vrml/Fields.luau"], -[93434, "src/Rosetta/codecs/model/Vrml/Geometry.luau"], -[94183, "src/Rosetta/codecs/model/Vrml/Parse.luau"], -[94705, "src/Rosetta/codecs/model/Vrml/Write.luau"], -[95432, "src/Rosetta/codecs/model/Vrml/Xml.luau"], -[95664, "src/Rosetta/codecs/text/GodotVariant.luau"], -[96323, "src/Rosetta/codecs/text/Json/init.luau"], -[96592, "src/Rosetta/codecs/text/Json/Decode.luau"], -[97027, "src/Rosetta/codecs/text/Json/Encode.luau"], -[97372, "src/Rosetta/codecs/text/KeyValues/init.luau"], -[97942, "src/Rosetta/codecs/text/KeyValues/Binary.luau"], -[98248, "src/Rosetta/codecs/text/Lexer/init.luau"], -[98380, "src/Rosetta/codecs/text/Nbt/init.luau"], -[98733, "src/Rosetta/codecs/text/Nbt/Binary.luau"], -[99425, "src/Rosetta/codecs/text/Nbt/Snbt.luau"], -[100065, "src/Rosetta/codecs/text/Nbt/Value.luau"], -[100303, "src/Rosetta/codecs/text/Text/init.luau"], -[100394, "src/Rosetta/codecs/text/Url/init.luau"], -[100599, "src/Rosetta/codecs/text/Xml/init.luau"], -[101049, "src/Rosetta/codecs/text/Xml/Parse.luau"], -[101853, "src/Rosetta/codecs/video/Dsp.luau"], -[102691, "src/Rosetta/codecs/video/H263/init.luau"], -[102848, "src/Rosetta/codecs/video/H263/Decoder.luau"], -[103706, "src/Rosetta/codecs/video/H263/Tables.luau"], -[103910, "src/Rosetta/codecs/video/H264/init.luau"], -[104284, "src/Rosetta/codecs/video/H264/Bitstream.luau"], -[104559, "src/Rosetta/codecs/video/H264/Cabac.luau"], -[105690, "src/Rosetta/codecs/video/H264/Cavlc.luau"], -[106458, "src/Rosetta/codecs/video/H264/Deblock.luau"], -[106720, "src/Rosetta/codecs/video/H264/Decoder.luau"], -[107730, "src/Rosetta/codecs/video/H264/Inter.luau"], -[108056, "src/Rosetta/codecs/video/H264/Intra.luau"], -[108463, "src/Rosetta/codecs/video/H264/Mb.luau"], -[109402, "src/Rosetta/codecs/video/H264/Params.luau"], -[109850, "src/Rosetta/codecs/video/H264/Slice.luau"], -[110102, "src/Rosetta/codecs/video/H264/Tables.luau"], -[110144, "src/Rosetta/codecs/video/H264/Transform.luau"], -[110309, "src/Rosetta/codecs/video/Legacy/init.luau"], -[110508, "src/Rosetta/codecs/video/Legacy/Cinepak.luau"], -[110805, "src/Rosetta/codecs/video/Legacy/Flic.luau"], -[111172, "src/Rosetta/codecs/video/Legacy/Msvideo1.luau"], -[111290, "src/Rosetta/codecs/video/Legacy/Picture.luau"], -[111398, "src/Rosetta/codecs/video/Legacy/QtRle.luau"], -[111671, "src/Rosetta/codecs/video/Legacy/Smacker.luau"], -[112066, "src/Rosetta/codecs/video/Legacy/Smc.luau"], -[112243, "src/Rosetta/codecs/video/Mpeg1/init.luau"], -[112256, "src/Rosetta/codecs/video/Mpeg2/init.luau"], -[112624, "src/Rosetta/codecs/video/Mpeg2/Decoder.luau"], -[114151, "src/Rosetta/codecs/video/Mpeg2/Tables.luau"], -[114291, "src/Rosetta/codecs/video/Mpeg2/Vlc.luau"], -[114430, "src/Rosetta/codecs/video/Theora/init.luau"], -[114694, "src/Rosetta/codecs/video/Theora/Decoder.luau"], -[115958, "src/Rosetta/codecs/video/Theora/Header.luau"], -[116322, "src/Rosetta/codecs/video/Video/init.luau"], -[116880, "src/Rosetta/codecs/video/Video/Source.luau"], -[117166, "src/Rosetta/containers/Archive.luau"], -[117433, "src/Rosetta/containers/AudioWrap.luau"], -[117943, "src/Rosetta/containers/Avi/init.luau"], -[118496, "src/Rosetta/containers/Blend.luau"], -[119235, "src/Rosetta/containers/Chunks.luau"], -[119370, "src/Rosetta/containers/Cpio.luau"], -[119798, "src/Rosetta/containers/Demux.luau"], -[120073, "src/Rosetta/containers/Ebml/init.luau"], -[120387, "src/Rosetta/containers/Fat.luau"], -[121075, "src/Rosetta/containers/Iso9660.luau"], -[121580, "src/Rosetta/containers/IsoBmff/init.luau"], -[121751, "src/Rosetta/containers/IsoBmff/Box.luau"], -[121940, "src/Rosetta/containers/IsoBmff/Demux.luau"], -[122786, "src/Rosetta/containers/IsoBmff/Meta.luau"], -[123308, "src/Rosetta/containers/IsoBmff/Mux.luau"], -[123825, "src/Rosetta/containers/IsoBmff/QtPalette.luau"], -[123943, "src/Rosetta/containers/MacFile.luau"], -[124092, "src/Rosetta/containers/MpegEs.luau"], -[124259, "src/Rosetta/containers/MpegPs/init.luau"], -[124480, "src/Rosetta/containers/MpegTs/init.luau"], -[125273, "src/Rosetta/containers/Ogg/init.luau"], -[125698, "src/Rosetta/containers/Ogg/Mux.luau"], -[125887, "src/Rosetta/containers/Ogg/Page.luau"], -[126053, "src/Rosetta/containers/Riff/init.luau"], -[126370, "src/Rosetta/containers/Tar.luau"], -[126784, "src/Rosetta/containers/Zip/init.luau"], -[127416, "src/Rosetta/core/Adler32.luau"], -[127476, "src/Rosetta/core/Base64.luau"], -[127704, "src/Rosetta/core/Bits.luau"], -[127997, "src/Rosetta/core/Bytes.luau"], -[128524, "src/Rosetta/core/Crc16.luau"], -[128576, "src/Rosetta/core/Crc32.luau"], -[128727, "src/Rosetta/core/Err.luau"], -[128809, "src/Rosetta/core/Input.luau"], -[128885, "src/Rosetta/core/Md5.luau"], -[129043, "src/Rosetta/core/Sniff.luau"], -[129072, "src/Rosetta/data/cbor/init.luau"], -[129171, "src/Rosetta/data/cbor/Codec.luau"], -[129740, "src/Rosetta/data/csv/init.luau"], -[130052, "src/Rosetta/data/ini/init.luau"], -[130298, "src/Rosetta/data/json/init.luau"], -[130390, "src/Rosetta/data/msgpack/init.luau"], -[130479, "src/Rosetta/data/msgpack/Codec.luau"], -[130921, "src/Rosetta/data/nbt/init.luau"], -[130980, "src/Rosetta/data/plist/init.luau"], -[131286, "src/Rosetta/data/plist/Binary.luau"], -[131553, "src/Rosetta/data/q3shader/init.luau"], -[131792, "src/Rosetta/data/q3skin/init.luau"], -[131888, "src/Rosetta/data/snbt/init.luau"], -[131951, "src/Rosetta/data/toml/init.luau"], -[132018, "src/Rosetta/data/toml/Decode.luau"], -[132646, "src/Rosetta/data/toml/Encode.luau"], -[132855, "src/Rosetta/data/tres/init.luau"], -[133000, "src/Rosetta/data/vdf/init.luau"], -[133101, "src/Rosetta/data/xml/init.luau"], -[133157, "src/Rosetta/data/yaml/init.luau"], -[133230, "src/Rosetta/data/yaml/Emit.luau"], -[133520, "src/Rosetta/data/yaml/Parse.luau"], -[134813, "src/Rosetta/font/bdf/init.luau"], -[135102, "src/Rosetta/font/bmfont/init.luau"], -[135529, "src/Rosetta/font/bmfont/Parse.luau"], -[135982, "src/Rosetta/font/eot/init.luau"], -[136214, "src/Rosetta/font/fon/init.luau"], -[136497, "src/Rosetta/font/hershey/init.luau"], -[136692, "src/Rosetta/font/pcf/init.luau"], -[136972, "src/Rosetta/font/psf/init.luau"], -[137292, "src/Rosetta/font/ttf/init.luau"], -[137343, "src/Rosetta/font/type1/init.luau"], -[137702, "src/Rosetta/font/type1/Charstring.luau"], -[137980, "src/Rosetta/font/woff/init.luau"], -[138112, "src/Rosetta/font/woff2/init.luau"], -[138169, "src/Rosetta/font/woff2/Rebuild.luau"], -[138709, "src/Rosetta/host/init.luau"], -[138754, "src/Rosetta/host/Love.luau"], -[138897, "src/Rosetta/host/LuaJIT.luau"], -[138947, "src/Rosetta/host/Luau.luau"], -[138970, "src/Rosetta/host/Roblox.luau"], -[139329, "src/Rosetta/image/ani/init.luau"], -[139509, "src/Rosetta/image/art/init.luau"], -[139997, "src/Rosetta/image/blp/init.luau"], -[140255, "src/Rosetta/image/bmp/init.luau"], -[140670, "src/Rosetta/image/dds/init.luau"], -[141153, "src/Rosetta/image/exr/init.luau"], -[141913, "src/Rosetta/image/exr/Codec.luau"], -[142024, "src/Rosetta/image/exr/Piz.luau"], -[142381, "src/Rosetta/image/gif/init.luau"], -[142897, "src/Rosetta/image/gif/Decode.luau"], -[142973, "src/Rosetta/image/hdr/init.luau"], -[143202, "src/Rosetta/image/hdr/Codec.luau"], -[143413, "src/Rosetta/image/icns/init.luau"], -[143744, "src/Rosetta/image/ico/init.luau"], -[144021, "src/Rosetta/image/ico/Dib.luau"], -[144116, "src/Rosetta/image/ilbm/init.luau"], -[144435, "src/Rosetta/image/jpeg/init.luau"], -[144571, "src/Rosetta/image/ktx/init.luau"], -[145231, "src/Rosetta/image/lmp/init.luau"], -[145364, "src/Rosetta/image/pcx/init.luau"], -[145628, "src/Rosetta/image/png/init.luau"], -[146208, "src/Rosetta/image/png/Apng.luau"], -[146288, "src/Rosetta/image/png/Decode.luau"], -[146661, "src/Rosetta/image/png/Encode.luau"], -[146864, "src/Rosetta/image/pnm/init.luau"], -[147242, "src/Rosetta/image/pnm/Codec.luau"], -[147519, "src/Rosetta/image/qoi/init.luau"], -[147641, "src/Rosetta/image/qoi/Codec.luau"], -[147798, "src/Rosetta/image/sgi/init.luau"], -[148083, "src/Rosetta/image/spr/init.luau"], -[148396, "src/Rosetta/image/sunras/init.luau"], -[148642, "src/Rosetta/image/tga/init.luau"], -[148912, "src/Rosetta/image/tga/Codec.luau"], -[149112, "src/Rosetta/image/tiff/init.luau"], -[149939, "src/Rosetta/image/tiff/Pixels.luau"], -[150329, "src/Rosetta/image/tim/init.luau"], -[150571, "src/Rosetta/image/vtf/init.luau"], -[150806, "src/Rosetta/image/webp/init.luau"], -[151416, "src/Rosetta/image/webp/Alpha.luau"], -[151492, "src/Rosetta/image/webp/Anim.luau"], -[151647, "src/Rosetta/image/xbm/init.luau"], -[151808, "src/Rosetta/image/xpm/init.luau"], -[152076, "src/Rosetta/image/xpm/Names.luau"], -[152132, "src/Rosetta/layered/aseprite/init.luau"], -[152870, "src/Rosetta/layered/ora/init.luau"], -[153157, "src/Rosetta/layered/psd/init.luau"], -[153892, "src/Rosetta/layered/psd/Channels.luau"], -[154244, "src/Rosetta/model/3ds/init.luau"], -[154327, "src/Rosetta/model/3ds/Build.luau"], -[154974, "src/Rosetta/model/3ds/Read.luau"], -[155470, "src/Rosetta/model/3ds/Write.luau"], -[156275, "src/Rosetta/model/3mf/init.luau"], -[156357, "src/Rosetta/model/3mf/Read.luau"], -[156945, "src/Rosetta/model/3mf/Write.luau"], -[157350, "src/Rosetta/model/ase/init.luau"], -[157473, "src/Rosetta/model/ase/Build.luau"], -[158047, "src/Rosetta/model/ase/Parse.luau"], -[158116, "src/Rosetta/model/ase/Write.luau"], -[158579, "src/Rosetta/model/b3d/init.luau"], -[158634, "src/Rosetta/model/b3d/Read.luau"], -[159205, "src/Rosetta/model/blend/init.luau"], -[159301, "src/Rosetta/model/blend/Anim.luau"], -[159647, "src/Rosetta/model/blend/Material.luau"], -[159999, "src/Rosetta/model/blend/Mesh.luau"], -[160634, "src/Rosetta/model/blend/Normals.luau"], -[160795, "src/Rosetta/model/blend/Prim.luau"], -[161244, "src/Rosetta/model/blend/Read.luau"], -[162144, "src/Rosetta/model/bsp/init.luau"], -[162335, "src/Rosetta/model/bsp/Lightmap.luau"], -[162401, "src/Rosetta/model/bsp/Quake.luau"], -[162790, "src/Rosetta/model/bsp/Quake3.luau"], -[163019, "src/Rosetta/model/bsp/Tree.luau"], -[163407, "src/Rosetta/model/buildmap/init.luau"], -[163679, "src/Rosetta/model/buildmap/Geometry.luau"], -[164082, "src/Rosetta/model/d3map/init.luau"], -[164364, "src/Rosetta/model/d3map/Parse.luau"], -[164562, "src/Rosetta/model/dae/init.luau"], -[164751, "src/Rosetta/model/dae/Math.luau"], -[164798, "src/Rosetta/model/dae/Read.luau"], -[166648, "src/Rosetta/model/dae/Write.luau"], -[167017, "src/Rosetta/model/fbx/init.luau"], -[167165, "src/Rosetta/model/fbx/Ascii.luau"], -[167435, "src/Rosetta/model/fbx/Binary.luau"], -[167890, "src/Rosetta/model/fbx/Read.luau"], -[169252, "src/Rosetta/model/fbx/Write.luau"], -[170237, "src/Rosetta/model/fbx/Xform.luau"], -[170278, "src/Rosetta/model/gltf/init.luau"], -[170515, "src/Rosetta/model/gltf/Pack.luau"], -[170584, "src/Rosetta/model/gltf/Read.luau"], -[171315, "src/Rosetta/model/gltf/Write.luau"], -[171995, "src/Rosetta/model/godot/init.luau"], -[172086, "src/Rosetta/model/godot/Build.luau"], -[172628, "src/Rosetta/model/godot/Primitives.luau"], -[172903, "src/Rosetta/model/godot/Surface.luau"], -[173388, "src/Rosetta/model/godot/Write.luau"], -[173717, "src/Rosetta/model/iqm/init.luau"], -[173793, "src/Rosetta/model/iqm/Read.luau"], -[174148, "src/Rosetta/model/iqm/Write.luau"], -[174835, "src/Rosetta/model/ldraw/init.luau"], -[174913, "src/Rosetta/model/ldraw/Colors.luau"], -[175231, "src/Rosetta/model/ldraw/Read.luau"], -[175808, "src/Rosetta/model/lwo/init.luau"], -[175884, "src/Rosetta/model/lwo/Build.luau"], -[176346, "src/Rosetta/model/lwo/Parse.luau"], -[176889, "src/Rosetta/model/map/init.luau"], -[177206, "src/Rosetta/model/map/Build.luau"], -[177450, "src/Rosetta/model/map/Parse.luau"], -[177835, "src/Rosetta/model/map/Write.luau"], -[177981, "src/Rosetta/model/mca/init.luau"], -[178323, "src/Rosetta/model/mca/Chunk.luau"], -[178456, "src/Rosetta/model/mca/Lz4Block.luau"], -[178526, "src/Rosetta/model/md2/init.luau"], -[178725, "src/Rosetta/model/md3/init.luau"], -[178953, "src/Rosetta/model/md5/init.luau"], -[179034, "src/Rosetta/model/md5/Read.luau"], -[179467, "src/Rosetta/model/mdl/init.luau"], -[179549, "src/Rosetta/model/mdl/HalfLife.luau"], -[179853, "src/Rosetta/model/mdl/Quake.luau"], -[180071, "src/Rosetta/model/ms3d/init.luau"], -[180143, "src/Rosetta/model/ms3d/Read.luau"], -[180589, "src/Rosetta/model/ms3d/Write.luau"], -[181058, "src/Rosetta/model/obj/init.luau"], -[181876, "src/Rosetta/model/obj/Mtl.luau"], -[182164, "src/Rosetta/model/off/init.luau"], -[182626, "src/Rosetta/model/ply/init.luau"], -[183731, "src/Rosetta/model/ply/Binary.luau"], -[183932, "src/Rosetta/model/pmx/init.luau"], -[184001, "src/Rosetta/model/pmx/Build.luau"], -[184297, "src/Rosetta/model/pmx/Pmd.luau"], -[184632, "src/Rosetta/model/pmx/Read.luau"], -[185036, "src/Rosetta/model/proc/init.luau"], -[185418, "src/Rosetta/model/qb/init.luau"], -[185811, "src/Rosetta/model/rbxm/init.luau"], -[186404, "src/Rosetta/model/rbxmx/init.luau"], -[187080, "src/Rosetta/model/robloxmesh/init.luau"], -[187739, "src/Rosetta/model/robloxmesh/Parse.luau"], -[188196, "src/Rosetta/model/robloxmesh/Write.luau"], -[188305, "src/Rosetta/model/schematic/init.luau"], -[188626, "src/Rosetta/model/schematic/Common.luau"], -[188746, "src/Rosetta/model/schematic/Litematic.luau"], -[188957, "src/Rosetta/model/schematic/Mcedit.luau"], -[189201, "src/Rosetta/model/schematic/Sponge.luau"], -[189330, "src/Rosetta/model/smd/init.luau"], -[189397, "src/Rosetta/model/smd/Read.luau"], -[189666, "src/Rosetta/model/smd/Write.luau"], -[189909, "src/Rosetta/model/sourcemdl/init.luau"], -[190080, "src/Rosetta/model/sourcemdl/Build.luau"], -[190510, "src/Rosetta/model/sourcemdl/Material.luau"], -[190671, "src/Rosetta/model/sourcemdl/Mdl.luau"], -[191198, "src/Rosetta/model/sourcemdl/Phy.luau"], -[191321, "src/Rosetta/model/sourcemdl/Vtx.luau"], -[191503, "src/Rosetta/model/sourcemdl/Vvd.luau"], -[191597, "src/Rosetta/model/stl/init.luau"], -[192047, "src/Rosetta/model/stl/Decode.luau"], -[192121, "src/Rosetta/model/t3d/init.luau"], -[192215, "src/Rosetta/model/t3d/Build.luau"], -[192620, "src/Rosetta/model/t3d/Parse.luau"], -[192788, "src/Rosetta/model/udmf/init.luau"], -[192871, "src/Rosetta/model/usda/init.luau"], -[193080, "src/Rosetta/model/usda/Build.luau"], -[194358, "src/Rosetta/model/usda/Parse.luau"], -[195156, "src/Rosetta/model/usda/Write.luau"], -[195973, "src/Rosetta/model/vbsp/init.luau"], -[196419, "src/Rosetta/model/vbsp/Faces.luau"], -[196643, "src/Rosetta/model/vbsp/Props.luau"], -[196735, "src/Rosetta/model/vmf/init.luau"], -[197060, "src/Rosetta/model/vmf/Build.luau"], -[197484, "src/Rosetta/model/vox/init.luau"], -[198370, "src/Rosetta/model/vox/Grid.luau"], -[198427, "src/Rosetta/model/vrml/init.luau"], -[198493, "src/Rosetta/model/x/init.luau"], -[198623, "src/Rosetta/model/x/Build.luau"], -[199186, "src/Rosetta/model/x/Parse.luau"], -[199483, "src/Rosetta/model/x3d/init.luau"], -[199561, "src/Rosetta/music/669/init.luau"], -[199768, "src/Rosetta/music/ahx/init.luau"], -[199820, "src/Rosetta/music/far/init.luau"], -[200050, "src/Rosetta/music/hmp/init.luau"], -[200315, "src/Rosetta/music/hvl/init.luau"], -[200367, "src/Rosetta/music/it/init.luau"], -[200786, "src/Rosetta/music/it/Itsex.luau"], -[200903, "src/Rosetta/music/med/init.luau"], -[201551, "src/Rosetta/music/midi/init.luau"], -[201695, "src/Rosetta/music/midi/Smf.luau"], -[202107, "src/Rosetta/music/mod/init.luau"], -[202461, "src/Rosetta/music/mtm/init.luau"], -[202684, "src/Rosetta/music/mus/init.luau"], -[202842, "src/Rosetta/music/okt/init.luau"], -[203124, "src/Rosetta/music/ptm/init.luau"], -[203347, "src/Rosetta/music/s3m/init.luau"], -[203584, "src/Rosetta/music/sf2/init.luau"], -[203628, "src/Rosetta/music/stm/init.luau"], -[203860, "src/Rosetta/music/ult/init.luau"], -[204165, "src/Rosetta/music/umx/init.luau"], -[204382, "src/Rosetta/music/xm/init.luau"], -[204944, "src/Rosetta/music/xmi/init.luau"], -[205153, "src/Rosetta/ops/AudioOps.luau"], -[205632, "src/Rosetta/ops/ImageOps/init.luau"], -[206280, "src/Rosetta/ops/ImageOps/Kernels.luau"], -[206920, "src/Rosetta/ops/LayerOps.luau"], -[207013, "src/Rosetta/ops/MeshOps/init.luau"], -[208065, "src/Rosetta/ops/MeshOps/Greedy.luau"], -[208232, "src/Rosetta/ops/MusicOps.luau"], -[208581, "src/Rosetta/playlist/m3u/init.luau"], -[208934, "src/Rosetta/playlist/pls/init.luau"], -[209112, "src/Rosetta/playlist/xspf/init.luau"], -[209315, "src/Rosetta/subtitle/ass/init.luau"], -[209759, "src/Rosetta/subtitle/srt/init.luau"], -[209932, "src/Rosetta/subtitle/vtt/init.luau"], -[210135, "src/Rosetta/vector/gamemaps/init.luau"], -[210322, "src/Rosetta/vector/gamemaps/Expand.luau"], -[210419, "src/Rosetta/vector/ldtk/init.luau"], -[210511, "src/Rosetta/vector/ldtk/Read.luau"], -[210847, "src/Rosetta/vector/ldtk/Write.luau"], -[211495, "src/Rosetta/vector/ogmo/init.luau"], -[211614, "src/Rosetta/vector/ogmo/Read.luau"], -[212019, "src/Rosetta/vector/ogmo/Write.luau"], -[212373, "src/Rosetta/vector/svg/init.luau"], -[212459, "src/Rosetta/vector/svg/Parse.luau"], -[213205, "src/Rosetta/vector/svg/PathData.luau"], -[213573, "src/Rosetta/vector/svg/Render.luau"], -[213990, "src/Rosetta/vector/svg/Style.luau"], -[214362, "src/Rosetta/vector/svg/Write.luau"], -[214562, "src/Rosetta/vector/tiled/init.luau"], -[214742, "src/Rosetta/vector/tiled/Data.luau"], -[214893, "src/Rosetta/vector/tiled/Tmj.luau"], -[215524, "src/Rosetta/vector/tiled/Tmx.luau"], -[216136, "src/Rosetta/video/avi/init.luau"], -[216430, "src/Rosetta/video/fli/init.luau"], -[216581, "src/Rosetta/video/flv/init.luau"], -[216965, "src/Rosetta/video/flv/Amf.luau"], -[217123, "src/Rosetta/video/flv/Mux.luau"], -[217404, "src/Rosetta/video/h264/init.luau"], -[217543, "src/Rosetta/video/mkv/init.luau"], -[217699, "src/Rosetta/video/mkv/Mux.luau"], -[217978, "src/Rosetta/video/mkv/Parse.luau"], -[218699, "src/Rosetta/video/mp4/init.luau"], -[219027, "src/Rosetta/video/mpegps/init.luau"], -[219214, "src/Rosetta/video/mpegts/init.luau"], -[219460, "src/Rosetta/video/ogv/init.luau"], -[219855, "src/Rosetta/video/smk/init.luau"], -[220164, "src/Rosetta/video/smk/Audio.luau"], -[220284, "src/Rosetta/video/y4m/init.luau"] +[1583, "src/Rosetta/Registry.luau"], +[4200, "src/Rosetta/Sniffs.luau"], +[7586, "src/Rosetta/Types.luau"], +[8699, "src/Rosetta/archive/7z/init.luau"], +[9084, "src/Rosetta/archive/7z/Header.luau"], +[9611, "src/Rosetta/archive/adf/init.luau"], +[9893, "src/Rosetta/archive/applesingle/init.luau"], +[10079, "src/Rosetta/archive/ar/init.luau"], +[10482, "src/Rosetta/archive/arj/init.luau"], +[10692, "src/Rosetta/archive/binhex/init.luau"], +[10941, "src/Rosetta/archive/br/init.luau"], +[11016, "src/Rosetta/archive/bz2/init.luau"], +[11080, "src/Rosetta/archive/cab/init.luau"], +[11493, "src/Rosetta/archive/cab/Sum.luau"], +[11534, "src/Rosetta/archive/cpio/init.luau"], +[11702, "src/Rosetta/archive/d64/init.luau"], +[12116, "src/Rosetta/archive/fat/init.luau"], +[12238, "src/Rosetta/archive/grp/init.luau"], +[12352, "src/Rosetta/archive/gzip/init.luau"], +[12537, "src/Rosetta/archive/iso/init.luau"], +[12609, "src/Rosetta/archive/lha/init.luau"], +[13034, "src/Rosetta/archive/lz4/init.luau"], +[13378, "src/Rosetta/archive/macbinary/init.luau"], +[13576, "src/Rosetta/archive/mpq/init.luau"], +[13982, "src/Rosetta/archive/mpq/Crypt.luau"], +[14047, "src/Rosetta/archive/pak/init.luau"], +[14181, "src/Rosetta/archive/rpm/init.luau"], +[14505, "src/Rosetta/archive/tar/init.luau"], +[14623, "src/Rosetta/archive/unitypackage/init.luau"], +[14859, "src/Rosetta/archive/uu/init.luau"], +[15129, "src/Rosetta/archive/vpk/init.luau"], +[15440, "src/Rosetta/archive/vswap/init.luau"], +[15710, "src/Rosetta/archive/wad/init.luau"], +[16164, "src/Rosetta/archive/wad/Picture.luau"], +[16266, "src/Rosetta/archive/wad2/init.luau"], +[16548, "src/Rosetta/archive/xz/init.luau"], +[16648, "src/Rosetta/archive/yenc/init.luau"], +[16920, "src/Rosetta/archive/z/init.luau"], +[17016, "src/Rosetta/archive/zip/init.luau"], +[17235, "src/Rosetta/archive/zoo/init.luau"], +[17431, "src/Rosetta/archive/zst/init.luau"], +[17495, "src/Rosetta/audio/aac/init.luau"], +[17708, "src/Rosetta/audio/ac3/init.luau"], +[17855, "src/Rosetta/audio/adpcm/init.luau"], +[18001, "src/Rosetta/audio/adx/init.luau"], +[18233, "src/Rosetta/audio/aiff/init.luau"], +[18625, "src/Rosetta/audio/ape/init.luau"], +[18754, "src/Rosetta/audio/au/init.luau"], +[18916, "src/Rosetta/audio/brstm/init.luau"], +[19208, "src/Rosetta/audio/caf/init.luau"], +[19875, "src/Rosetta/audio/flac/init.luau"], +[20024, "src/Rosetta/audio/flac/Meta.luau"], +[20246, "src/Rosetta/audio/flac/Stream.luau"], +[20616, "src/Rosetta/audio/m4a/init.luau"], +[20959, "src/Rosetta/audio/mp3/init.luau"], +[21220, "src/Rosetta/audio/mp3/Index.luau"], +[21411, "src/Rosetta/audio/mp3/Stream.luau"], +[21638, "src/Rosetta/audio/mp3/Tags.luau"], +[21950, "src/Rosetta/audio/mpc/init.luau"], +[22045, "src/Rosetta/audio/opus/init.luau"], +[22424, "src/Rosetta/audio/opus/Encode.luau"], +[22536, "src/Rosetta/audio/qoa/init.luau"], +[22717, "src/Rosetta/audio/tta/init.luau"], +[22836, "src/Rosetta/audio/vag/init.luau"], +[23060, "src/Rosetta/audio/voc/init.luau"], +[23336, "src/Rosetta/audio/vorbis/init.luau"], +[23791, "src/Rosetta/audio/vorbis/Encode.luau"], +[24604, "src/Rosetta/audio/wav/init.luau"], +[25225, "src/Rosetta/audio/wav/Codecs.luau"], +[25404, "src/Rosetta/audio/wavpack/init.luau"], +[25612, "src/Rosetta/cad/step/init.luau"], +[25994, "src/Rosetta/cad/step/Brep.luau"], +[26229, "src/Rosetta/cad/step/Parse.luau"], +[26786, "src/Rosetta/cad/step/Write.luau"], +[27034, "src/Rosetta/codecs/audio/Aac/init.luau"], +[27442, "src/Rosetta/codecs/audio/Aac/Decode.luau"], +[28418, "src/Rosetta/codecs/audio/Aac/Ps.luau"], +[29008, "src/Rosetta/codecs/audio/Aac/Sbr.luau"], +[30075, "src/Rosetta/codecs/audio/Aac/SbrBits.luau"], +[30194, "src/Rosetta/codecs/audio/Aac/SbrDct.luau"], +[31436, "src/Rosetta/codecs/audio/Aac/SbrHf.luau"], +[31928, "src/Rosetta/codecs/audio/Aac/SbrQmf.luau"], +[32045, "src/Rosetta/codecs/audio/Aac/SbrTables.luau"], +[32458, "src/Rosetta/codecs/audio/Aac/Tables.luau"], +[32794, "src/Rosetta/codecs/audio/Ac3/init.luau"], +[32954, "src/Rosetta/codecs/audio/Ac3/Decode.luau"], +[33839, "src/Rosetta/codecs/audio/Ac3/Tables.luau"], +[33941, "src/Rosetta/codecs/audio/Adpcm/init.luau"], +[34695, "src/Rosetta/codecs/audio/Adpcm/Decoder.luau"], +[34998, "src/Rosetta/codecs/audio/Alac/init.luau"], +[35233, "src/Rosetta/codecs/audio/Alac/Decode.luau"], +[35652, "src/Rosetta/codecs/audio/Alac/Encode.luau"], +[36064, "src/Rosetta/codecs/audio/Ape/init.luau"], +[36280, "src/Rosetta/codecs/audio/Ape/Decode.luau"], +[37041, "src/Rosetta/codecs/audio/ApeTag.luau"], +[37139, "src/Rosetta/codecs/audio/Flac/init.luau"], +[37151, "src/Rosetta/codecs/audio/Flac/Encode.luau"], +[38100, "src/Rosetta/codecs/audio/Flac/Frame.luau"], +[38720, "src/Rosetta/codecs/audio/Hively/init.luau"], +[38917, "src/Rosetta/codecs/audio/Hively/Load.luau"], +[39167, "src/Rosetta/codecs/audio/Hively/Player.luau"], +[40126, "src/Rosetta/codecs/audio/Hively/Tables.luau"], +[40346, "src/Rosetta/codecs/audio/Mdct/init.luau"], +[40566, "src/Rosetta/codecs/audio/Mdct/Fft.luau"], +[40820, "src/Rosetta/codecs/audio/MidiRender.luau"], +[41167, "src/Rosetta/codecs/audio/Mpa/init.luau"], +[41182, "src/Rosetta/codecs/audio/Mpa/Analysis.luau"], +[41241, "src/Rosetta/codecs/audio/Mpa/Core.luau"], +[42899, "src/Rosetta/codecs/audio/Mpa/EncTables.luau"], +[43192, "src/Rosetta/codecs/audio/Mpa/Encode2.luau"], +[43577, "src/Rosetta/codecs/audio/Mpa/Encode3.luau"], +[44218, "src/Rosetta/codecs/audio/Mpa/Header.luau"], +[44359, "src/Rosetta/codecs/audio/Mpa/Tables.luau"], +[44586, "src/Rosetta/codecs/audio/Musepack/init.luau"], +[44932, "src/Rosetta/codecs/audio/Musepack/Decode.luau"], +[45826, "src/Rosetta/codecs/audio/Musepack/Tables.luau"], +[46205, "src/Rosetta/codecs/audio/Opus/init.luau"], +[46220, "src/Rosetta/codecs/audio/Opus/Celt.luau"], +[48092, "src/Rosetta/codecs/audio/Opus/CeltEncoder.luau"], +[49157, "src/Rosetta/codecs/audio/Opus/CeltTables.luau"], +[49218, "src/Rosetta/codecs/audio/Opus/Decoder.luau"], +[49682, "src/Rosetta/codecs/audio/Opus/Mdct.luau"], +[50033, "src/Rosetta/codecs/audio/Opus/Packet.luau"], +[50266, "src/Rosetta/codecs/audio/Opus/Silk.luau"], +[52308, "src/Rosetta/codecs/audio/Opus/SilkTables.luau"], +[52682, "src/Rosetta/codecs/audio/Pcm/init.luau"], +[52946, "src/Rosetta/codecs/audio/Pcm/Convert.luau"], +[53243, "src/Rosetta/codecs/audio/Qoa/init.luau"], +[53525, "src/Rosetta/codecs/audio/Resample/init.luau"], +[53920, "src/Rosetta/codecs/audio/SoundFont/init.luau"], +[53975, "src/Rosetta/codecs/audio/SoundFont/Fallback.luau"], +[54119, "src/Rosetta/codecs/audio/SoundFont/Parse.luau"], +[54633, "src/Rosetta/codecs/audio/SoundFont/Synth.luau"], +[55432, "src/Rosetta/codecs/audio/Stream.luau"], +[55594, "src/Rosetta/codecs/audio/Tracker/init.luau"], +[56077, "src/Rosetta/codecs/audio/Tracker/Load.luau"], +[56356, "src/Rosetta/codecs/audio/Tracker/Mixer.luau"], +[56603, "src/Rosetta/codecs/audio/Tracker/Pcm.luau"], +[56732, "src/Rosetta/codecs/audio/Tracker/Player.luau"], +[58721, "src/Rosetta/codecs/audio/Tracker/Tables.luau"], +[58838, "src/Rosetta/codecs/audio/Tta/init.luau"], +[58956, "src/Rosetta/codecs/audio/Tta/Decode.luau"], +[59208, "src/Rosetta/codecs/audio/Vorbis/init.luau"], +[59222, "src/Rosetta/codecs/audio/Vorbis/Codebook.luau"], +[59606, "src/Rosetta/codecs/audio/Vorbis/Packet.luau"], +[60179, "src/Rosetta/codecs/audio/Vorbis/Setup.luau"], +[60601, "src/Rosetta/codecs/audio/Vorbis/Tables.luau"], +[60641, "src/Rosetta/codecs/audio/VorbisComment.luau"], +[60694, "src/Rosetta/codecs/audio/WavPack/init.luau"], +[60917, "src/Rosetta/codecs/audio/WavPack/Block.luau"], +[62372, "src/Rosetta/codecs/audio/WavPack/Tables.luau"], +[62435, "src/Rosetta/codecs/compress/Brotli/init.luau"], +[62522, "src/Rosetta/codecs/compress/Brotli/Decode.luau"], +[63498, "src/Rosetta/codecs/compress/Brotli/Static.luau"], +[64366, "src/Rosetta/codecs/compress/Bzip2/init.luau"], +[64410, "src/Rosetta/codecs/compress/Bzip2/Decode.luau"], +[64923, "src/Rosetta/codecs/compress/Deflate/init.luau"], +[65249, "src/Rosetta/codecs/compress/Deflate/Compress.luau"], +[65731, "src/Rosetta/codecs/compress/Deflate/Inflate.luau"], +[66179, "src/Rosetta/codecs/compress/Explode.luau"], +[66375, "src/Rosetta/codecs/compress/Lz4.luau"], +[66644, "src/Rosetta/codecs/compress/Lzh/init.luau"], +[67248, "src/Rosetta/codecs/compress/Lzma/init.luau"], +[67788, "src/Rosetta/codecs/compress/Lzma/Crc64.luau"], +[67855, "src/Rosetta/codecs/compress/Lzma/Decode.luau"], +[68328, "src/Rosetta/codecs/compress/Lzma/Filters.luau"], +[68504, "src/Rosetta/codecs/compress/Lzw/init.luau"], +[68772, "src/Rosetta/codecs/compress/Lzx.luau"], +[69206, "src/Rosetta/codecs/compress/PackBits.luau"], +[69296, "src/Rosetta/codecs/compress/Quantum.luau"], +[69533, "src/Rosetta/codecs/compress/UnixCompress.luau"], +[69837, "src/Rosetta/codecs/compress/Xxh32.luau"], +[69906, "src/Rosetta/codecs/compress/Zstd/init.luau"], +[69963, "src/Rosetta/codecs/compress/Zstd/Decode.luau"], +[70947, "src/Rosetta/codecs/compress/Zstd/Xxh64.luau"], +[71099, "src/Rosetta/codecs/entropy/Huffman.luau"], +[71386, "src/Rosetta/codecs/entropy/RangeCoder/init.luau"], +[71397, "src/Rosetta/codecs/entropy/RangeCoder/Decoder.luau"], +[71618, "src/Rosetta/codecs/entropy/RangeCoder/Encoder.luau"], +[71862, "src/Rosetta/codecs/font/Bitmap.luau"], +[72063, "src/Rosetta/codecs/font/Cff/init.luau"], +[72704, "src/Rosetta/codecs/font/GlyphNames.luau"], +[72854, "src/Rosetta/codecs/font/TrueType/init.luau"], +[73168, "src/Rosetta/codecs/font/TrueType/Glyf.luau"], +[73560, "src/Rosetta/codecs/font/TrueType/Tables.luau"], +[74062, "src/Rosetta/codecs/image/Bcn/init.luau"], +[74169, "src/Rosetta/codecs/image/Bcn/Decode.luau"], +[74653, "src/Rosetta/codecs/image/Bcn/Encode.luau"], +[75082, "src/Rosetta/codecs/image/Blend.luau"], +[75461, "src/Rosetta/codecs/image/Dct/init.luau"], +[75961, "src/Rosetta/codecs/image/Etc.luau"], +[76259, "src/Rosetta/codecs/image/Half.luau"], +[76328, "src/Rosetta/codecs/image/Jpeg/init.luau"], +[76682, "src/Rosetta/codecs/image/Jpeg/Arith.luau"], +[77090, "src/Rosetta/codecs/image/Jpeg/Color.luau"], +[77455, "src/Rosetta/codecs/image/Jpeg/Decode.luau"], +[78220, "src/Rosetta/codecs/image/Jpeg/Encode.luau"], +[79101, "src/Rosetta/codecs/image/Jpeg/Scan.luau"], +[79570, "src/Rosetta/codecs/image/Jpeg/Tables.luau"], +[79648, "src/Rosetta/codecs/image/Jpeg/Yuv.luau"], +[79715, "src/Rosetta/codecs/image/Miptex.luau"], +[80015, "src/Rosetta/codecs/image/Pixels.luau"], +[80335, "src/Rosetta/codecs/image/Quantize/init.luau"], +[80796, "src/Rosetta/codecs/image/Raster.luau"], +[81493, "src/Rosetta/codecs/image/Texel.luau"], +[81866, "src/Rosetta/codecs/image/Texture.luau"], +[82011, "src/Rosetta/codecs/image/Vp8/init.luau"], +[82142, "src/Rosetta/codecs/image/Vp8/Decode.luau"], +[84098, "src/Rosetta/codecs/image/Vp8/Predict.luau"], +[84361, "src/Rosetta/codecs/image/Vp8/Tables.luau"], +[84611, "src/Rosetta/codecs/image/Vp8/Yuv.luau"], +[84753, "src/Rosetta/codecs/image/Vp8L/init.luau"], +[84857, "src/Rosetta/codecs/image/Vp8L/Decode.luau"], +[85797, "src/Rosetta/codecs/image/Vp8L/Encode.luau"], +[86749, "src/Rosetta/codecs/image/Yuv.luau"], +[87054, "src/Rosetta/codecs/model/Brush.luau"], +[87694, "src/Rosetta/codecs/model/Displacement.luau"], +[87843, "src/Rosetta/codecs/model/DoomMap/init.luau"], +[88288, "src/Rosetta/codecs/model/DoomMap/Udmf.luau"], +[88538, "src/Rosetta/codecs/model/Draco/init.luau"], +[88870, "src/Rosetta/codecs/model/Draco/Attributes.luau"], +[89339, "src/Rosetta/codecs/model/Draco/Connectivity.luau"], +[90528, "src/Rosetta/codecs/model/Draco/Int64.luau"], +[90677, "src/Rosetta/codecs/model/Draco/KdTree.luau"], +[91036, "src/Rosetta/codecs/model/Draco/Predict.luau"], +[91998, "src/Rosetta/codecs/model/Draco/Reader.luau"], +[92472, "src/Rosetta/codecs/model/Mat4.luau"], +[92731, "src/Rosetta/codecs/model/MeshFlatten.luau"], +[93259, "src/Rosetta/codecs/model/Minecraft/init.luau"], +[93811, "src/Rosetta/codecs/model/Minecraft/Colors.luau"], +[93890, "src/Rosetta/codecs/model/Minecraft/Legacy.luau"], +[93997, "src/Rosetta/codecs/model/Minecraft/Packed.luau"], +[94203, "src/Rosetta/codecs/model/Patch.luau"], +[94327, "src/Rosetta/codecs/model/Polygon.luau"], +[94561, "src/Rosetta/codecs/model/Rbx/init.luau"], +[94798, "src/Rosetta/codecs/model/Rbx/Binary.luau"], +[95552, "src/Rosetta/codecs/model/Rig.luau"], +[95795, "src/Rosetta/codecs/model/Sampler.luau"], +[95955, "src/Rosetta/codecs/model/SourceAnim.luau"], +[96176, "src/Rosetta/codecs/model/Vrml/init.luau"], +[96324, "src/Rosetta/codecs/model/Vrml/Build.luau"], +[96898, "src/Rosetta/codecs/model/Vrml/Fields.luau"], +[97061, "src/Rosetta/codecs/model/Vrml/Geometry.luau"], +[97810, "src/Rosetta/codecs/model/Vrml/Parse.luau"], +[98332, "src/Rosetta/codecs/model/Vrml/Write.luau"], +[99059, "src/Rosetta/codecs/model/Vrml/Xml.luau"], +[99291, "src/Rosetta/codecs/text/GodotVariant.luau"], +[99950, "src/Rosetta/codecs/text/Json/init.luau"], +[100219, "src/Rosetta/codecs/text/Json/Decode.luau"], +[100654, "src/Rosetta/codecs/text/Json/Encode.luau"], +[100999, "src/Rosetta/codecs/text/KeyValues/init.luau"], +[101569, "src/Rosetta/codecs/text/KeyValues/Binary.luau"], +[101875, "src/Rosetta/codecs/text/Lexer/init.luau"], +[102007, "src/Rosetta/codecs/text/Nbt/init.luau"], +[102360, "src/Rosetta/codecs/text/Nbt/Binary.luau"], +[103052, "src/Rosetta/codecs/text/Nbt/Snbt.luau"], +[103692, "src/Rosetta/codecs/text/Nbt/Value.luau"], +[103930, "src/Rosetta/codecs/text/Text/init.luau"], +[104021, "src/Rosetta/codecs/text/Url/init.luau"], +[104226, "src/Rosetta/codecs/text/Xml/init.luau"], +[104676, "src/Rosetta/codecs/text/Xml/Parse.luau"], +[105480, "src/Rosetta/codecs/video/Dsp.luau"], +[106318, "src/Rosetta/codecs/video/H263/init.luau"], +[106475, "src/Rosetta/codecs/video/H263/Decoder.luau"], +[107333, "src/Rosetta/codecs/video/H263/Tables.luau"], +[107537, "src/Rosetta/codecs/video/H264/init.luau"], +[107911, "src/Rosetta/codecs/video/H264/Bitstream.luau"], +[108186, "src/Rosetta/codecs/video/H264/Cabac.luau"], +[109317, "src/Rosetta/codecs/video/H264/Cavlc.luau"], +[110085, "src/Rosetta/codecs/video/H264/Deblock.luau"], +[110347, "src/Rosetta/codecs/video/H264/Decoder.luau"], +[111357, "src/Rosetta/codecs/video/H264/Inter.luau"], +[111683, "src/Rosetta/codecs/video/H264/Intra.luau"], +[112090, "src/Rosetta/codecs/video/H264/Mb.luau"], +[113029, "src/Rosetta/codecs/video/H264/Params.luau"], +[113477, "src/Rosetta/codecs/video/H264/Slice.luau"], +[113729, "src/Rosetta/codecs/video/H264/Tables.luau"], +[113771, "src/Rosetta/codecs/video/H264/Transform.luau"], +[113936, "src/Rosetta/codecs/video/Legacy/init.luau"], +[114135, "src/Rosetta/codecs/video/Legacy/Cinepak.luau"], +[114432, "src/Rosetta/codecs/video/Legacy/Flic.luau"], +[114799, "src/Rosetta/codecs/video/Legacy/Msvideo1.luau"], +[114917, "src/Rosetta/codecs/video/Legacy/Picture.luau"], +[115025, "src/Rosetta/codecs/video/Legacy/QtRle.luau"], +[115298, "src/Rosetta/codecs/video/Legacy/Smacker.luau"], +[115693, "src/Rosetta/codecs/video/Legacy/Smc.luau"], +[115870, "src/Rosetta/codecs/video/Mpeg1/init.luau"], +[115883, "src/Rosetta/codecs/video/Mpeg2/init.luau"], +[116251, "src/Rosetta/codecs/video/Mpeg2/Decoder.luau"], +[117778, "src/Rosetta/codecs/video/Mpeg2/Tables.luau"], +[117918, "src/Rosetta/codecs/video/Mpeg2/Vlc.luau"], +[118057, "src/Rosetta/codecs/video/Theora/init.luau"], +[118321, "src/Rosetta/codecs/video/Theora/Decoder.luau"], +[119585, "src/Rosetta/codecs/video/Theora/Header.luau"], +[119949, "src/Rosetta/codecs/video/Video/init.luau"], +[120507, "src/Rosetta/codecs/video/Video/Source.luau"], +[120793, "src/Rosetta/containers/Archive.luau"], +[121060, "src/Rosetta/containers/AudioWrap.luau"], +[121570, "src/Rosetta/containers/Avi/init.luau"], +[122123, "src/Rosetta/containers/Blend.luau"], +[122862, "src/Rosetta/containers/Chunks.luau"], +[122997, "src/Rosetta/containers/Cpio.luau"], +[123425, "src/Rosetta/containers/Demux.luau"], +[123700, "src/Rosetta/containers/Ebml/init.luau"], +[124014, "src/Rosetta/containers/Fat.luau"], +[124702, "src/Rosetta/containers/Iso9660.luau"], +[125207, "src/Rosetta/containers/IsoBmff/init.luau"], +[125378, "src/Rosetta/containers/IsoBmff/Box.luau"], +[125567, "src/Rosetta/containers/IsoBmff/Demux.luau"], +[126413, "src/Rosetta/containers/IsoBmff/Meta.luau"], +[126935, "src/Rosetta/containers/IsoBmff/Mux.luau"], +[127452, "src/Rosetta/containers/IsoBmff/QtPalette.luau"], +[127570, "src/Rosetta/containers/MacFile.luau"], +[127719, "src/Rosetta/containers/MpegEs.luau"], +[127886, "src/Rosetta/containers/MpegPs/init.luau"], +[128107, "src/Rosetta/containers/MpegTs/init.luau"], +[128900, "src/Rosetta/containers/Ogg/init.luau"], +[129325, "src/Rosetta/containers/Ogg/Mux.luau"], +[129514, "src/Rosetta/containers/Ogg/Page.luau"], +[129680, "src/Rosetta/containers/Riff/init.luau"], +[129997, "src/Rosetta/containers/Tar.luau"], +[130411, "src/Rosetta/containers/Zip/init.luau"], +[131043, "src/Rosetta/core/Adler32.luau"], +[131103, "src/Rosetta/core/Base64.luau"], +[131331, "src/Rosetta/core/Bits.luau"], +[131624, "src/Rosetta/core/Bytes.luau"], +[132151, "src/Rosetta/core/Crc16.luau"], +[132203, "src/Rosetta/core/Crc32.luau"], +[132354, "src/Rosetta/core/Err.luau"], +[132436, "src/Rosetta/core/Input.luau"], +[132512, "src/Rosetta/core/Md5.luau"], +[132670, "src/Rosetta/core/Sniff.luau"], +[132699, "src/Rosetta/data/cbor/init.luau"], +[132798, "src/Rosetta/data/cbor/Codec.luau"], +[133367, "src/Rosetta/data/csv/init.luau"], +[133679, "src/Rosetta/data/ini/init.luau"], +[133925, "src/Rosetta/data/json/init.luau"], +[134017, "src/Rosetta/data/msgpack/init.luau"], +[134106, "src/Rosetta/data/msgpack/Codec.luau"], +[134548, "src/Rosetta/data/nbt/init.luau"], +[134607, "src/Rosetta/data/plist/init.luau"], +[134913, "src/Rosetta/data/plist/Binary.luau"], +[135180, "src/Rosetta/data/q3shader/init.luau"], +[135419, "src/Rosetta/data/q3skin/init.luau"], +[135515, "src/Rosetta/data/snbt/init.luau"], +[135578, "src/Rosetta/data/toml/init.luau"], +[135645, "src/Rosetta/data/toml/Decode.luau"], +[136273, "src/Rosetta/data/toml/Encode.luau"], +[136482, "src/Rosetta/data/tres/init.luau"], +[136627, "src/Rosetta/data/vdf/init.luau"], +[136728, "src/Rosetta/data/xml/init.luau"], +[136784, "src/Rosetta/data/yaml/init.luau"], +[136857, "src/Rosetta/data/yaml/Emit.luau"], +[137147, "src/Rosetta/data/yaml/Parse.luau"], +[138440, "src/Rosetta/font/bdf/init.luau"], +[138729, "src/Rosetta/font/bmfont/init.luau"], +[139156, "src/Rosetta/font/bmfont/Parse.luau"], +[139609, "src/Rosetta/font/eot/init.luau"], +[139841, "src/Rosetta/font/fon/init.luau"], +[140124, "src/Rosetta/font/hershey/init.luau"], +[140319, "src/Rosetta/font/pcf/init.luau"], +[140599, "src/Rosetta/font/psf/init.luau"], +[140919, "src/Rosetta/font/ttf/init.luau"], +[140970, "src/Rosetta/font/type1/init.luau"], +[141329, "src/Rosetta/font/type1/Charstring.luau"], +[141607, "src/Rosetta/font/woff/init.luau"], +[141739, "src/Rosetta/font/woff2/init.luau"], +[141796, "src/Rosetta/font/woff2/Rebuild.luau"], +[142336, "src/Rosetta/host/init.luau"], +[142381, "src/Rosetta/host/Love.luau"], +[142524, "src/Rosetta/host/LuaJIT.luau"], +[142574, "src/Rosetta/host/Luau.luau"], +[142597, "src/Rosetta/host/Roblox.luau"], +[142956, "src/Rosetta/image/ani/init.luau"], +[143136, "src/Rosetta/image/art/init.luau"], +[143624, "src/Rosetta/image/blp/init.luau"], +[143882, "src/Rosetta/image/bmp/init.luau"], +[144297, "src/Rosetta/image/dds/init.luau"], +[144780, "src/Rosetta/image/exr/init.luau"], +[145540, "src/Rosetta/image/exr/Codec.luau"], +[145651, "src/Rosetta/image/exr/Piz.luau"], +[146008, "src/Rosetta/image/gif/init.luau"], +[146524, "src/Rosetta/image/gif/Decode.luau"], +[146600, "src/Rosetta/image/hdr/init.luau"], +[146829, "src/Rosetta/image/hdr/Codec.luau"], +[147040, "src/Rosetta/image/icns/init.luau"], +[147371, "src/Rosetta/image/ico/init.luau"], +[147648, "src/Rosetta/image/ico/Dib.luau"], +[147743, "src/Rosetta/image/ilbm/init.luau"], +[148062, "src/Rosetta/image/jpeg/init.luau"], +[148198, "src/Rosetta/image/ktx/init.luau"], +[148858, "src/Rosetta/image/lmp/init.luau"], +[148991, "src/Rosetta/image/pcx/init.luau"], +[149255, "src/Rosetta/image/png/init.luau"], +[149835, "src/Rosetta/image/png/Apng.luau"], +[149915, "src/Rosetta/image/png/Decode.luau"], +[150288, "src/Rosetta/image/png/Encode.luau"], +[150491, "src/Rosetta/image/pnm/init.luau"], +[150869, "src/Rosetta/image/pnm/Codec.luau"], +[151146, "src/Rosetta/image/qoi/init.luau"], +[151268, "src/Rosetta/image/qoi/Codec.luau"], +[151425, "src/Rosetta/image/sgi/init.luau"], +[151710, "src/Rosetta/image/spr/init.luau"], +[152023, "src/Rosetta/image/sunras/init.luau"], +[152269, "src/Rosetta/image/tga/init.luau"], +[152539, "src/Rosetta/image/tga/Codec.luau"], +[152739, "src/Rosetta/image/tiff/init.luau"], +[153566, "src/Rosetta/image/tiff/Pixels.luau"], +[153956, "src/Rosetta/image/tim/init.luau"], +[154198, "src/Rosetta/image/vtf/init.luau"], +[154433, "src/Rosetta/image/webp/init.luau"], +[155043, "src/Rosetta/image/webp/Alpha.luau"], +[155119, "src/Rosetta/image/webp/Anim.luau"], +[155274, "src/Rosetta/image/xbm/init.luau"], +[155435, "src/Rosetta/image/xpm/init.luau"], +[155703, "src/Rosetta/image/xpm/Names.luau"], +[155759, "src/Rosetta/layered/aseprite/init.luau"], +[156497, "src/Rosetta/layered/ora/init.luau"], +[156784, "src/Rosetta/layered/psd/init.luau"], +[157519, "src/Rosetta/layered/psd/Channels.luau"], +[157871, "src/Rosetta/model/3ds/init.luau"], +[157954, "src/Rosetta/model/3ds/Build.luau"], +[158601, "src/Rosetta/model/3ds/Read.luau"], +[159097, "src/Rosetta/model/3ds/Write.luau"], +[159902, "src/Rosetta/model/3mf/init.luau"], +[159984, "src/Rosetta/model/3mf/Read.luau"], +[160572, "src/Rosetta/model/3mf/Write.luau"], +[160977, "src/Rosetta/model/ase/init.luau"], +[161100, "src/Rosetta/model/ase/Build.luau"], +[161674, "src/Rosetta/model/ase/Parse.luau"], +[161743, "src/Rosetta/model/ase/Write.luau"], +[162206, "src/Rosetta/model/b3d/init.luau"], +[162261, "src/Rosetta/model/b3d/Read.luau"], +[162832, "src/Rosetta/model/blend/init.luau"], +[162928, "src/Rosetta/model/blend/Anim.luau"], +[163274, "src/Rosetta/model/blend/Material.luau"], +[163626, "src/Rosetta/model/blend/Mesh.luau"], +[164261, "src/Rosetta/model/blend/Normals.luau"], +[164422, "src/Rosetta/model/blend/Prim.luau"], +[164871, "src/Rosetta/model/blend/Read.luau"], +[165771, "src/Rosetta/model/bsp/init.luau"], +[165962, "src/Rosetta/model/bsp/Lightmap.luau"], +[166028, "src/Rosetta/model/bsp/Quake.luau"], +[166417, "src/Rosetta/model/bsp/Quake3.luau"], +[166646, "src/Rosetta/model/bsp/Tree.luau"], +[167034, "src/Rosetta/model/buildmap/init.luau"], +[167306, "src/Rosetta/model/buildmap/Geometry.luau"], +[167709, "src/Rosetta/model/d3map/init.luau"], +[167991, "src/Rosetta/model/d3map/Parse.luau"], +[168189, "src/Rosetta/model/dae/init.luau"], +[168378, "src/Rosetta/model/dae/Math.luau"], +[168425, "src/Rosetta/model/dae/Read.luau"], +[170275, "src/Rosetta/model/dae/Write.luau"], +[170644, "src/Rosetta/model/fbx/init.luau"], +[170792, "src/Rosetta/model/fbx/Ascii.luau"], +[171062, "src/Rosetta/model/fbx/Binary.luau"], +[171517, "src/Rosetta/model/fbx/Read.luau"], +[172879, "src/Rosetta/model/fbx/Write.luau"], +[173864, "src/Rosetta/model/fbx/Xform.luau"], +[173905, "src/Rosetta/model/gltf/init.luau"], +[174142, "src/Rosetta/model/gltf/Pack.luau"], +[174211, "src/Rosetta/model/gltf/Read.luau"], +[174942, "src/Rosetta/model/gltf/Write.luau"], +[175622, "src/Rosetta/model/godot/init.luau"], +[175713, "src/Rosetta/model/godot/Build.luau"], +[176255, "src/Rosetta/model/godot/Primitives.luau"], +[176530, "src/Rosetta/model/godot/Surface.luau"], +[177015, "src/Rosetta/model/godot/Write.luau"], +[177344, "src/Rosetta/model/iqm/init.luau"], +[177420, "src/Rosetta/model/iqm/Read.luau"], +[177775, "src/Rosetta/model/iqm/Write.luau"], +[178462, "src/Rosetta/model/ldraw/init.luau"], +[178540, "src/Rosetta/model/ldraw/Colors.luau"], +[178858, "src/Rosetta/model/ldraw/Read.luau"], +[179435, "src/Rosetta/model/lwo/init.luau"], +[179511, "src/Rosetta/model/lwo/Build.luau"], +[179973, "src/Rosetta/model/lwo/Parse.luau"], +[180516, "src/Rosetta/model/map/init.luau"], +[180833, "src/Rosetta/model/map/Build.luau"], +[181077, "src/Rosetta/model/map/Parse.luau"], +[181462, "src/Rosetta/model/map/Write.luau"], +[181608, "src/Rosetta/model/mca/init.luau"], +[181950, "src/Rosetta/model/mca/Chunk.luau"], +[182083, "src/Rosetta/model/mca/Lz4Block.luau"], +[182153, "src/Rosetta/model/md2/init.luau"], +[182352, "src/Rosetta/model/md3/init.luau"], +[182580, "src/Rosetta/model/md5/init.luau"], +[182661, "src/Rosetta/model/md5/Read.luau"], +[183094, "src/Rosetta/model/mdl/init.luau"], +[183176, "src/Rosetta/model/mdl/HalfLife.luau"], +[183480, "src/Rosetta/model/mdl/Quake.luau"], +[183698, "src/Rosetta/model/ms3d/init.luau"], +[183770, "src/Rosetta/model/ms3d/Read.luau"], +[184216, "src/Rosetta/model/ms3d/Write.luau"], +[184685, "src/Rosetta/model/obj/init.luau"], +[185503, "src/Rosetta/model/obj/Mtl.luau"], +[185791, "src/Rosetta/model/off/init.luau"], +[186253, "src/Rosetta/model/ply/init.luau"], +[187358, "src/Rosetta/model/ply/Binary.luau"], +[187559, "src/Rosetta/model/pmx/init.luau"], +[187628, "src/Rosetta/model/pmx/Build.luau"], +[187924, "src/Rosetta/model/pmx/Pmd.luau"], +[188259, "src/Rosetta/model/pmx/Read.luau"], +[188663, "src/Rosetta/model/proc/init.luau"], +[189045, "src/Rosetta/model/qb/init.luau"], +[189438, "src/Rosetta/model/rbxm/init.luau"], +[190031, "src/Rosetta/model/rbxmx/init.luau"], +[190707, "src/Rosetta/model/robloxmesh/init.luau"], +[191366, "src/Rosetta/model/robloxmesh/Parse.luau"], +[191823, "src/Rosetta/model/robloxmesh/Write.luau"], +[191932, "src/Rosetta/model/schematic/init.luau"], +[192253, "src/Rosetta/model/schematic/Common.luau"], +[192373, "src/Rosetta/model/schematic/Litematic.luau"], +[192584, "src/Rosetta/model/schematic/Mcedit.luau"], +[192828, "src/Rosetta/model/schematic/Sponge.luau"], +[192957, "src/Rosetta/model/smd/init.luau"], +[193024, "src/Rosetta/model/smd/Read.luau"], +[193293, "src/Rosetta/model/smd/Write.luau"], +[193536, "src/Rosetta/model/sourcemdl/init.luau"], +[193707, "src/Rosetta/model/sourcemdl/Build.luau"], +[194137, "src/Rosetta/model/sourcemdl/Material.luau"], +[194298, "src/Rosetta/model/sourcemdl/Mdl.luau"], +[194825, "src/Rosetta/model/sourcemdl/Phy.luau"], +[194948, "src/Rosetta/model/sourcemdl/Vtx.luau"], +[195130, "src/Rosetta/model/sourcemdl/Vvd.luau"], +[195224, "src/Rosetta/model/stl/init.luau"], +[195674, "src/Rosetta/model/stl/Decode.luau"], +[195748, "src/Rosetta/model/t3d/init.luau"], +[195842, "src/Rosetta/model/t3d/Build.luau"], +[196247, "src/Rosetta/model/t3d/Parse.luau"], +[196415, "src/Rosetta/model/udmf/init.luau"], +[196498, "src/Rosetta/model/usda/init.luau"], +[196707, "src/Rosetta/model/usda/Build.luau"], +[197985, "src/Rosetta/model/usda/Parse.luau"], +[198783, "src/Rosetta/model/usda/Write.luau"], +[199600, "src/Rosetta/model/vbsp/init.luau"], +[200046, "src/Rosetta/model/vbsp/Faces.luau"], +[200270, "src/Rosetta/model/vbsp/Props.luau"], +[200362, "src/Rosetta/model/vmf/init.luau"], +[200687, "src/Rosetta/model/vmf/Build.luau"], +[201111, "src/Rosetta/model/vox/init.luau"], +[201997, "src/Rosetta/model/vox/Grid.luau"], +[202054, "src/Rosetta/model/vrml/init.luau"], +[202120, "src/Rosetta/model/x/init.luau"], +[202250, "src/Rosetta/model/x/Build.luau"], +[202813, "src/Rosetta/model/x/Parse.luau"], +[203110, "src/Rosetta/model/x3d/init.luau"], +[203188, "src/Rosetta/music/669/init.luau"], +[203395, "src/Rosetta/music/ahx/init.luau"], +[203447, "src/Rosetta/music/far/init.luau"], +[203677, "src/Rosetta/music/hmp/init.luau"], +[203942, "src/Rosetta/music/hvl/init.luau"], +[203994, "src/Rosetta/music/it/init.luau"], +[204413, "src/Rosetta/music/it/Itsex.luau"], +[204530, "src/Rosetta/music/med/init.luau"], +[205178, "src/Rosetta/music/midi/init.luau"], +[205322, "src/Rosetta/music/midi/Smf.luau"], +[205734, "src/Rosetta/music/mod/init.luau"], +[206088, "src/Rosetta/music/mtm/init.luau"], +[206311, "src/Rosetta/music/mus/init.luau"], +[206469, "src/Rosetta/music/okt/init.luau"], +[206751, "src/Rosetta/music/ptm/init.luau"], +[206974, "src/Rosetta/music/s3m/init.luau"], +[207211, "src/Rosetta/music/sf2/init.luau"], +[207255, "src/Rosetta/music/stm/init.luau"], +[207487, "src/Rosetta/music/ult/init.luau"], +[207792, "src/Rosetta/music/umx/init.luau"], +[208009, "src/Rosetta/music/xm/init.luau"], +[208571, "src/Rosetta/music/xmi/init.luau"], +[208780, "src/Rosetta/ops/AudioOps.luau"], +[209259, "src/Rosetta/ops/ImageOps/init.luau"], +[209907, "src/Rosetta/ops/ImageOps/Kernels.luau"], +[210547, "src/Rosetta/ops/LayerOps.luau"], +[210640, "src/Rosetta/ops/MeshOps/init.luau"], +[211692, "src/Rosetta/ops/MeshOps/Greedy.luau"], +[211859, "src/Rosetta/ops/MusicOps.luau"], +[212208, "src/Rosetta/playlist/m3u/init.luau"], +[212561, "src/Rosetta/playlist/pls/init.luau"], +[212739, "src/Rosetta/playlist/xspf/init.luau"], +[212942, "src/Rosetta/subtitle/ass/init.luau"], +[213386, "src/Rosetta/subtitle/srt/init.luau"], +[213559, "src/Rosetta/subtitle/vtt/init.luau"], +[213762, "src/Rosetta/vector/gamemaps/init.luau"], +[213949, "src/Rosetta/vector/gamemaps/Expand.luau"], +[214046, "src/Rosetta/vector/ldtk/init.luau"], +[214138, "src/Rosetta/vector/ldtk/Read.luau"], +[214474, "src/Rosetta/vector/ldtk/Write.luau"], +[215122, "src/Rosetta/vector/ogmo/init.luau"], +[215241, "src/Rosetta/vector/ogmo/Read.luau"], +[215646, "src/Rosetta/vector/ogmo/Write.luau"], +[216000, "src/Rosetta/vector/svg/init.luau"], +[216086, "src/Rosetta/vector/svg/Parse.luau"], +[216832, "src/Rosetta/vector/svg/PathData.luau"], +[217200, "src/Rosetta/vector/svg/Render.luau"], +[217617, "src/Rosetta/vector/svg/Style.luau"], +[217989, "src/Rosetta/vector/svg/Write.luau"], +[218189, "src/Rosetta/vector/tiled/init.luau"], +[218369, "src/Rosetta/vector/tiled/Data.luau"], +[218520, "src/Rosetta/vector/tiled/Tmj.luau"], +[219151, "src/Rosetta/vector/tiled/Tmx.luau"], +[219763, "src/Rosetta/video/avi/init.luau"], +[220057, "src/Rosetta/video/fli/init.luau"], +[220208, "src/Rosetta/video/flv/init.luau"], +[220592, "src/Rosetta/video/flv/Amf.luau"], +[220750, "src/Rosetta/video/flv/Mux.luau"], +[221031, "src/Rosetta/video/h264/init.luau"], +[221170, "src/Rosetta/video/mkv/init.luau"], +[221326, "src/Rosetta/video/mkv/Mux.luau"], +[221605, "src/Rosetta/video/mkv/Parse.luau"], +[222326, "src/Rosetta/video/mp4/init.luau"], +[222654, "src/Rosetta/video/mpegps/init.luau"], +[222841, "src/Rosetta/video/mpegts/init.luau"], +[223087, "src/Rosetta/video/ogv/init.luau"], +[223482, "src/Rosetta/video/smk/init.luau"], +[223791, "src/Rosetta/video/smk/Audio.luau"], +[223911, "src/Rosetta/video/y4m/init.luau"] ] diff --git a/docs/API.md b/docs/API.md index f6c8d08..d724f43 100644 --- a/docs/API.md +++ b/docs/API.md @@ -24,7 +24,7 @@ come back as a third value `{ [file name] = buffer }` (or in the caller's `opts. | `F.save(value, dest?, opts?)` | `buffer` / `true` (+ the extra files, see above) | | `F.saveString(value, opts?)` | the encoded bytes as a string | | `F.convert(src, format, opts?)` | load + save (`opts` go to both; `opts.out = path` writes a file) | -| `F.detect(src, opts?)` | the format name (content sniffing first, then the extension); a format's optional `variant(r)` can name the flavour (`"webm"` for a WebM file read by mkv) | +| `F.detect(src, opts?)` | the format name (content sniffing first, then the extension); a format's optional `variant(r)` can name the flavour (`"webm"` for a WebM file read by mkv). Sniffing loads no format module (the generated `Sniffs.luau`); `load` / `open` / `save` load only the format they use | | `F.formats(category?)` | `{ { name, category, extensions, mime, caps } }` without loading any format (also [FORMATS.md](FORMATS.md)) | | `F.format(name)` | the format module itself (`sniff` / `decode` / `encode` / `open` and extras such as `png.info`) | diff --git a/docs/STYLE.md b/docs/STYLE.md index 16e2caf..01d4ef2 100644 --- a/docs/STYLE.md +++ b/docs/STYLE.md @@ -18,7 +18,7 @@ The reference implementation to copy is **PNG**: ``` src/Rosetta/ - init.luau Registry.luau (generated) api (layer 6) + init.luau Registry.luau Sniffs.luau (gen.) api (layer 6) ops/ ops (layer 5.5) editing on the standard types (F.ops.image / mesh / layers / audio / music; ImageOps, ...) // formats (layer 5) image audio video model cad font archive data @@ -156,6 +156,11 @@ Rules: inside a bigger buffer; never assume offset 0). It returns the category's standard type from `Types.luau` (`Types.Image.new(w, h)`, `Types.Scene.new()`, ...), `rgba8` for images unless `opts.native` asks for the source layout. Fill `meta.source = { format = "", ... }` with the source facts (bit depth, colour type, codec, ...). +- `sniff(r)` scores 0..1 and is copied, with the top-level locals, types and loops it reaches, into the generated + `Sniffs.luau`, so detection requires no format module (requires outside `core/` become proxies loaded at sniff time). + A sniff that reaches its module table (`Png.info(r)`), a forward-declared local or a load-time read of a non-core + module is not copied: its module then loads on every detection that gets that far. `tests/detect.luau` checks the + copies against the modules. - `encode(value, opts)` returns a buffer. Validate the value first and return `Err.ARG` for anything wrong. - `open(r, opts)` (audio / video) returns the streaming Decoder / VideoDecoder / Demuxer from `Types.luau`. If a format has `open` but no `decode`, `F.load` decodes the whole stream through it. @@ -312,8 +317,8 @@ t:done() 2. Shared code (a codec two formats need, a container) goes to `codecs//` or `containers/` instead, with its own test in `tests/codecs/` / `tests/containers/`. 3. `deps = { ... }` = the requires outside the folder. -4. `python3 -I tools/gen_registry.py` (regenerates `src/Rosetta/Registry.luau` and `docs/FORMATS.md`; never edit those - by hand; after a merge, just rerun it). +4. `python3 -I tools/gen_registry.py` (regenerates `src/Rosetta/Registry.luau`, `Sniffs.luau` and `docs/FORMATS.md`; + never edit those by hand; after a merge, just rerun it). 5. `tools/fixtures/.py` + `tests//.luau`. 6. `bash tools/test.sh ` while working (both runtimes), then `bash tools/test.sh` (everything + lint). 7. The docs line comes from the contract (`docs/FORMATS.md`); put format notes (limits, spec deviations, bench numbers) diff --git a/src/Rosetta/Registry.luau b/src/Rosetta/Registry.luau index fd33c7f..afbe9c8 100644 --- a/src/Rosetta/Registry.luau +++ b/src/Rosetta/Registry.luau @@ -2,6 +2,8 @@ -- Registry: GENERATED by tools/gen_registry.py from the format folders - do not edit. -- One entry per format: the contract metadata (copied from its init.luau) and load(), which requires the format -- module on first use (a static require, as Roblox needs). Order: category, then name. +-- sniff: where detection finds the format's sniff (tools/sniff_extract.py): 0 Sniffs.luau, 1 Sniffs.luau reaching a +-- codec / container on first call, 2 the format module. variant: the module has variant(r). export type Entry = { name: string, category: string, @@ -10,6 +12,8 @@ export type Entry = { mime: { string }, deps: { string }, caps: { [string]: any }, + sniff: number, + variant: boolean?, load: () -> any, } @@ -22,6 +26,7 @@ local list: { Entry } = { mime = { "application/x-navi-animation" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Riff" }, caps = { decode = true, encode = true, alpha = true, animation = true, frames = true }, + sniff = 0, load = function() return require("@rosetta/image/ani") end, @@ -34,6 +39,7 @@ local list: { Entry } = { mime = { "image/x-build-art" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Pixels", "codecs/image/Quantize" }, caps = { decode = true, encode = true, alpha = true, palette = true, frames = true, depths = { 8 } }, + sniff = 0, load = function() return require("@rosetta/image/art") end, @@ -46,6 +52,7 @@ local list: { Entry } = { mime = { "image/x-blp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Jpeg", "codecs/image/Bcn" }, caps = { decode = true, encode = true, alpha = true, variants = { "blp1", "blp2" }, compressions = { "jpeg", "palette", "dxt1", "dxt3", "dxt5", "bgra" } }, + sniff = 0, load = function() return require("@rosetta/image/blp") end, @@ -58,6 +65,7 @@ local list: { Entry } = { mime = { "image/bmp", "image/x-bmp", "image/x-ms-bmp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, depths = { 1, 2, 4, 8, 16, 24, 32 }, rle = true }, + sniff = 0, load = function() return require("@rosetta/image/bmp") end, @@ -70,6 +78,7 @@ local list: { Entry } = { mime = { "image/vnd-ms.dds", "image/x-dds" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/image/Bcn", "codecs/image/Texel", "codecs/image/Texture" }, caps = { decode = true, encode = true, alpha = true, float = true, mipmaps = true, cubemap = true, compressed = { "bc1", "bc2", "bc3", "bc4", "bc5", "bc6h", "bc7" } }, + sniff = 0, load = function() return require("@rosetta/image/dds") end, @@ -82,6 +91,7 @@ local list: { Entry } = { mime = { "image/x-exr", "image/aces" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/image/Half", "codecs/compress/Deflate" }, caps = { decode = true, encode = true, alpha = true, float = true, hdr = true, depths = { 16, 32 }, multipart = true, tiled = true }, + sniff = 0, load = function() return require("@rosetta/image/exr") end, @@ -94,6 +104,7 @@ local list: { Entry } = { mime = { "image/gif" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Lzw", "codecs/image/Quantize", "Types" }, caps = { decode = true, encode = true, animation = true, alpha = true, palette = true, depths = { 1, 2, 4, 8 } }, + sniff = 0, load = function() return require("@rosetta/image/gif") end, @@ -106,6 +117,7 @@ local list: { Entry } = { mime = { "image/vnd.radiance", "image/x-hdr" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = false, float = true, depths = { 32 } }, + sniff = 0, load = function() return require("@rosetta/image/hdr") end, @@ -118,6 +130,7 @@ local list: { Entry } = { mime = { "image/icns", "image/x-icns" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "containers/Chunks" }, caps = { decode = true, encode = true, alpha = true, frames = true, depths = { 1, 24, 32 } }, + sniff = 0, load = function() return require("@rosetta/image/icns") end, @@ -130,6 +143,7 @@ local list: { Entry } = { mime = { "image/vnd.microsoft.icon", "image/x-icon" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, frames = true, depths = { 1, 4, 8, 16, 24, 32 } }, + sniff = 0, load = function() return require("@rosetta/image/ico") end, @@ -142,6 +156,7 @@ local list: { Entry } = { mime = { "image/x-ilbm", "image/x-iff" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks", "codecs/compress/PackBits", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 1, 2, 3, 4, 5, 6, 7, 8, 24, 32 } }, + sniff = 0, load = function() return require("@rosetta/image/ilbm") end, @@ -154,6 +169,7 @@ local list: { Entry } = { mime = { "image/jpeg" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Jpeg" }, caps = { decode = true, encode = true, lossy = true, alpha = false, depths = { 8, 12 }, progressive = true, arithmetic = true }, + sniff = 0, load = function() return require("@rosetta/image/jpeg") end, @@ -166,6 +182,7 @@ local list: { Entry } = { mime = { "image/ktx2", "image/ktx" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/compress/Deflate", "codecs/compress/Zstd", "codecs/image/Texel", "codecs/image/Texture" }, caps = { decode = true, encode = true, alpha = true, float = true, mipmaps = true, cubemap = true, compressed = { "bc1", "bc2", "bc3", "bc4", "bc5", "bc6h", "bc7", "etc1", "etc2", "eac" } }, + sniff = 0, load = function() return require("@rosetta/image/ktx") end, @@ -178,6 +195,7 @@ local list: { Entry } = { mime = { "image/x-quake-lmp" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Pixels", "codecs/image/Miptex" }, caps = { decode = true, encode = true, alpha = true, depths = { 8 }, variants = { "qpic", "palette", "colormap" } }, + sniff = 0, load = function() return require("@rosetta/image/lmp") end, @@ -190,6 +208,7 @@ local list: { Entry } = { mime = { "image/vnd.zbrush.pcx", "image/x-pcx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 1, 2, 4, 8, 24, 32 } }, + sniff = 0, load = function() return require("@rosetta/image/pcx") end, @@ -202,6 +221,7 @@ local list: { Entry } = { mime = { "image/png", "image/apng" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "codecs/compress/Deflate", "Types", "containers/Chunks" }, caps = { decode = true, encode = true, animation = true, alpha = true, depths = { 1, 2, 4, 8, 16 } }, + sniff = 0, load = function() return require("@rosetta/image/png") end, @@ -214,6 +234,7 @@ local list: { Entry } = { mime = { "image/x-portable-anymap", "image/x-portable-bitmap", "image/x-portable-graymap", "image/x-portable-pixmap", "image/x-portable-arbitrarymap", "image/x-portable-floatmap" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = true, depths = { 1, 8, 16, 32 }, float = true }, + sniff = 0, load = function() return require("@rosetta/image/pnm") end, @@ -226,6 +247,7 @@ local list: { Entry } = { mime = { "image/qoi", "image/x-qoi" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = true, depths = { 8 } }, + sniff = 0, load = function() return require("@rosetta/image/qoi") end, @@ -238,6 +260,7 @@ local list: { Entry } = { mime = { "image/sgi", "image/x-rgb" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types" }, caps = { decode = true, encode = true, alpha = true, depths = { 8, 16 } }, + sniff = 0, load = function() return require("@rosetta/image/sgi") end, @@ -250,6 +273,7 @@ local list: { Entry } = { mime = { "image/x-quake-sprite" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Pixels", "codecs/image/Miptex" }, caps = { decode = true, encode = true, alpha = true, animation = true, variants = { "quake", "halflife", "spr32" } }, + sniff = 0, load = function() return require("@rosetta/image/spr") end, @@ -262,6 +286,7 @@ local list: { Entry } = { mime = { "image/x-sun-raster", "image/x-cmu-raster" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/image/Pixels" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 1, 8, 24, 32 } }, + sniff = 0, load = function() return require("@rosetta/image/sunras") end, @@ -274,6 +299,7 @@ local list: { Entry } = { mime = { "image/x-tga", "image/x-targa" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 8, 15, 16, 24, 32 } }, + sniff = 0, load = function() return require("@rosetta/image/tga") end, @@ -286,6 +312,7 @@ local list: { Entry } = { mime = { "image/tiff" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate", "codecs/compress/Lzw", "codecs/compress/PackBits" }, caps = { decode = true, encode = true, alpha = true, pages = true, depths = { 1, 2, 4, 8, 16, 32 }, float = true }, + sniff = 0, load = function() return require("@rosetta/image/tiff") end, @@ -298,6 +325,7 @@ local list: { Entry } = { mime = { "image/x-tim" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 4, 8, 16, 24 } }, + sniff = 0, load = function() return require("@rosetta/image/tim") end, @@ -310,6 +338,7 @@ local list: { Entry } = { mime = { "image/x-vtf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Bcn", "codecs/image/Texel" }, caps = { decode = true, encode = false, alpha = true, animation = true, versions = { "7.0", "7.1", "7.2", "7.3", "7.4", "7.5" } }, + sniff = 0, load = function() return require("@rosetta/image/vtf") end, @@ -322,6 +351,7 @@ local list: { Entry } = { mime = { "image/webp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Vp8", "codecs/image/Vp8L", "containers/Riff" }, caps = { decode = true, encode = true, animation = true, alpha = true, lossy = true, lossless = true, depths = { 8 } }, + sniff = 0, load = function() return require("@rosetta/image/webp") end, @@ -334,6 +364,7 @@ local list: { Entry } = { mime = { "image/x-xbitmap", "image/x-xbm" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types" }, caps = { decode = true, encode = true, depths = { 1 } }, + sniff = 0, load = function() return require("@rosetta/image/xbm") end, @@ -346,6 +377,7 @@ local list: { Entry } = { mime = { "image/x-xpixmap", "image/x-xpm" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types" }, caps = { decode = true, encode = true, alpha = true, palette = true, depths = { 8 } }, + sniff = 0, load = function() return require("@rosetta/image/xpm") end, @@ -358,6 +390,7 @@ local list: { Entry } = { mime = { "audio/aac", "audio/aacp", "audio/x-aac" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Aac", "codecs/audio/Pcm", "codecs/audio/Stream" }, caps = { decode = true, encode = false, codecs = { "aac" }, streaming = true }, + sniff = 1, load = function() return require("@rosetta/audio/aac") end, @@ -370,6 +403,7 @@ local list: { Entry } = { mime = { "audio/ac3", "audio/x-ac3" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/Ac3" }, caps = { decode = true, encode = false, codecs = { "ac3" }, channels = 6, streaming = true, lossy = true }, + sniff = 1, load = function() return require("@rosetta/audio/ac3") end, @@ -382,6 +416,7 @@ local list: { Entry } = { mime = { "audio/x-adpcm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm", "codecs/audio/Adpcm/Decoder" }, caps = { decode = true, encode = true, streaming = true, lossy = true, headerless = true, codecs = { "ima", "ima_wav", "ms", "ima_qt", "psx" } }, + sniff = 0, load = function() return require("@rosetta/audio/adpcm") end, @@ -394,6 +429,7 @@ local list: { Entry } = { mime = { "audio/x-adx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm", "codecs/audio/Adpcm/Decoder" }, caps = { decode = true, encode = true, streaming = true, lossy = true, loops = true, channels = 8 }, + sniff = 0, load = function() return require("@rosetta/audio/adx") end, @@ -406,6 +442,7 @@ local list: { Entry } = { mime = { "audio/aiff", "audio/x-aiff" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm/Decoder", "containers/Chunks" }, caps = { decode = true, encode = true, streaming = true, depths = { 8, 16, 24, 32 }, float = true, lossy = false }, + sniff = 0, load = function() return require("@rosetta/audio/aiff") end, @@ -418,6 +455,7 @@ local list: { Entry } = { mime = { "audio/ape", "audio/x-ape", "audio/x-monkeys-audio" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/ApeTag", "codecs/audio/Ape" }, caps = { decode = true, encode = false, streaming = true, seek = true, lossless = true, float = true, depths = { 8, 16, 24, 32 } }, + sniff = 0, load = function() return require("@rosetta/audio/ape") end, @@ -430,6 +468,7 @@ local list: { Entry } = { mime = { "audio/basic", "audio/x-au" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm" }, caps = { decode = true, encode = true, streaming = true, depths = { 8, 16, 24, 32 }, float = true, lossy = false }, + sniff = 0, load = function() return require("@rosetta/audio/au") end, @@ -442,6 +481,8 @@ local list: { Entry } = { mime = { "audio/x-brstm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm/Decoder" }, caps = { decode = true, encode = false, streaming = true, lossy = true, loops = true, containers = { "RSTM", "CSTM", "FSTM" } }, + sniff = 0, + variant = true, load = function() return require("@rosetta/audio/brstm") end, @@ -454,6 +495,7 @@ local list: { Entry } = { mime = { "audio/x-caf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Aac", "codecs/audio/Adpcm/Decoder", "codecs/audio/Alac", "codecs/audio/Pcm", "codecs/audio/Stream", "containers/Chunks" }, caps = { decode = true, encode = true, codecs = { "pcm", "alac", "aac", "ulaw", "alaw" }, encodeCodecs = { "pcm", "alac" }, tags = true, streaming = true }, + sniff = 0, load = function() return require("@rosetta/audio/caf") end, @@ -466,6 +508,7 @@ local list: { Entry } = { mime = { "audio/flac", "audio/x-flac" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ogg", "codecs/audio/Pcm", "codecs/audio/VorbisComment", "codecs/audio/Flac/Frame", "codecs/audio/Flac/Encode" }, caps = { decode = true, encode = true, streaming = true, depths = { 4, 8, 12, 16, 20, 24, 32 }, ogg = true, seek = true }, + sniff = 0, load = function() return require("@rosetta/audio/flac") end, @@ -478,6 +521,7 @@ local list: { Entry } = { mime = { "audio/mp4", "audio/x-m4a", "audio/m4a" }, deps = { "core/Err", "core/Bytes", "Types", "containers/IsoBmff", "codecs/audio/Aac", "codecs/audio/Alac", "codecs/audio/Pcm", "codecs/audio/Stream" }, caps = { decode = true, encode = true, codecs = { "aac", "alac" }, encodeCodecs = { "alac" }, tags = true, streaming = true }, + sniff = 1, load = function() return require("@rosetta/audio/m4a") end, @@ -490,6 +534,7 @@ local list: { Entry } = { mime = { "audio/mpeg", "audio/mp3", "audio/mpa" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Resample", "codecs/audio/Mpa/Header", "codecs/audio/Mpa/Core", "codecs/audio/Mpa/Encode3", "codecs/audio/Mpa/Encode2" }, caps = { decode = true, encode = true, streaming = true, seek = true, layers = { 1, 2, 3 }, encodeLayers = { 2, 3 }, channels = 2 }, + sniff = 1, load = function() return require("@rosetta/audio/mp3") end, @@ -502,6 +547,7 @@ local list: { Entry } = { mime = { "audio/x-musepack", "audio/musepack" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/ApeTag", "codecs/audio/Musepack" }, caps = { decode = true, encode = false, codecs = { "musepack" }, versions = { 7, 8 }, streaming = true, lossy = true }, + sniff = 1, load = function() return require("@rosetta/audio/mpc") end, @@ -514,6 +560,7 @@ local list: { Entry } = { mime = { "audio/opus", "audio/ogg" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ogg", "codecs/entropy/RangeCoder/Decoder", "codecs/audio/Pcm", "codecs/audio/Resample", "codecs/audio/VorbisComment", "codecs/audio/Opus/CeltEncoder", "codecs/audio/Opus/Decoder", "codecs/audio/Opus/Packet", "codecs/audio/Opus/Celt", "codecs/audio/Opus/Silk" }, caps = { decode = true, encode = true, streaming = true, seek = true, lossy = true, channels = 255, rates = { 48000 }, encodeModes = { "celt" }, encodeChannels = 2 }, + sniff = 0, load = function() return require("@rosetta/audio/opus") end, @@ -526,6 +573,7 @@ local list: { Entry } = { mime = { "audio/qoa" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/Qoa" }, caps = { decode = true, encode = true, streaming = true, lossy = true, seek = true, channels = 8 }, + sniff = 0, load = function() return require("@rosetta/audio/qoa") end, @@ -538,6 +586,7 @@ local list: { Entry } = { mime = { "audio/x-tta", "audio/tta" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/ApeTag", "codecs/audio/Tta" }, caps = { decode = true, encode = false, streaming = true, seek = true, lossless = true, depths = { 8, 16, 24 } }, + sniff = 0, load = function() return require("@rosetta/audio/tta") end, @@ -550,6 +599,7 @@ local list: { Entry } = { mime = { "audio/x-vag" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Adpcm", "codecs/audio/Adpcm/Decoder" }, caps = { decode = true, encode = true, streaming = true, lossy = true, loops = true, channels = 2 }, + sniff = 0, load = function() return require("@rosetta/audio/vag") end, @@ -562,6 +612,7 @@ local list: { Entry } = { mime = { "audio/x-voc" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm" }, caps = { decode = true, encode = true, streaming = true, depths = { 8, 16 }, lossy = false }, + sniff = 0, load = function() return require("@rosetta/audio/voc") end, @@ -574,6 +625,7 @@ local list: { Entry } = { mime = { "audio/ogg", "audio/vorbis" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ogg", "codecs/audio/Mdct", "codecs/audio/Pcm", "codecs/audio/VorbisComment", "codecs/audio/Vorbis/Tables", "codecs/audio/Vorbis/Setup", "codecs/audio/Vorbis/Packet" }, caps = { decode = true, encode = true, streaming = true, seek = true, lossy = true, channels = 255 }, + sniff = 0, load = function() return require("@rosetta/audio/vorbis") end, @@ -586,6 +638,7 @@ local list: { Entry } = { mime = { "audio/wav", "audio/x-wav", "audio/wave", "audio/vnd.wave" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Riff", "codecs/audio/Pcm", "codecs/audio/Adpcm" }, caps = { decode = true, encode = true, streaming = true, depths = { 8, 16, 24, 32 }, float = true, rf64 = true }, + sniff = 1, load = function() return require("@rosetta/audio/wav") end, @@ -598,6 +651,7 @@ local list: { Entry } = { mime = { "audio/x-wavpack", "audio/wavpack" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Pcm", "codecs/audio/Stream", "codecs/audio/ApeTag", "codecs/audio/WavPack" }, caps = { decode = true, encode = false, streaming = true, seek = true, lossless = true, hybrid = true, float = true, depths = { 8, 12, 16, 20, 24, 32 } }, + sniff = 0, load = function() return require("@rosetta/audio/wavpack") end, @@ -610,6 +664,7 @@ local list: { Entry } = { mime = { "video/x-msvideo", "video/avi" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Avi", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, video = { "mjpeg", "mpeg1", "mpeg2", "rawvideo" }, audio = true, odml = true }, + sniff = 0, load = function() return require("@rosetta/video/avi") end, @@ -622,6 +677,7 @@ local list: { Entry } = { mime = { "video/x-fli", "video/fli", "video/x-flc" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video" }, caps = { decode = true, encode = false, streaming = true, video = { "flic" }, depths = { 8, 15, 16, 24 } }, + sniff = 0, load = function() return require("@rosetta/video/fli") end, @@ -634,6 +690,7 @@ local list: { Entry } = { mime = { "video/x-flv", "video/flv" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source", "codecs/video/H263", "codecs/video/H264", "codecs/audio/Aac" }, caps = { decode = true, encode = true, streaming = true, remux = true, video = { "flv1", "h264" }, audio = true, metadata = true }, + sniff = 0, load = function() return require("@rosetta/video/flv") end, @@ -646,6 +703,7 @@ local list: { Entry } = { mime = { "video/h264" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source", "codecs/video/H264" }, caps = { decode = true, encode = true, streaming = true, video = { "h264" }, depths = { 8 } }, + sniff = 0, load = function() return require("@rosetta/video/h264") end, @@ -658,6 +716,8 @@ local list: { Entry } = { mime = { "video/x-matroska", "video/webm", "audio/x-matroska", "audio/webm" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ebml", "containers/Demux", "containers/Avi", "containers/IsoBmff/QtPalette", "codecs/compress/Deflate", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, remux = true, video = { "vp8", "mjpeg", "mpeg1", "mpeg2", "theora", "rawvideo" }, audio = true, subtitles = true }, + sniff = 0, + variant = true, load = function() return require("@rosetta/video/mkv") end, @@ -670,6 +730,7 @@ local list: { Entry } = { mime = { "video/mp4", "video/quicktime", "video/3gpp" }, deps = { "core/Err", "core/Bytes", "Types", "containers/IsoBmff", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, remux = true, video = { "mjpeg", "mpeg1", "mpeg2", "h264" }, audio = true, fragments = true }, + sniff = 1, load = function() return require("@rosetta/video/mp4") end, @@ -682,6 +743,7 @@ local list: { Entry } = { mime = { "video/mpeg" }, deps = { "core/Err", "core/Bytes", "Types", "containers/MpegPs", "containers/MpegEs", "containers/Demux", "codecs/video/Video" }, caps = { decode = true, encode = false, streaming = true, video = { "mpeg1", "mpeg2" }, audio = true }, + sniff = 0, load = function() return require("@rosetta/video/mpegps") end, @@ -694,6 +756,7 @@ local list: { Entry } = { mime = { "video/mp2t" }, deps = { "core/Err", "core/Bytes", "Types", "containers/MpegTs", "containers/MpegEs", "containers/Demux", "codecs/video/Video" }, caps = { decode = true, encode = false, streaming = true, video = { "mpeg1", "mpeg2", "h264" }, audio = true }, + sniff = 0, load = function() return require("@rosetta/video/mpegts") end, @@ -706,6 +769,7 @@ local list: { Entry } = { mime = { "video/ogg" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Ogg", "containers/Demux", "containers/AudioWrap", "codecs/video/Theora", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, remux = true, video = { "theora" }, audio = true }, + sniff = 0, load = function() return require("@rosetta/video/ogv") end, @@ -718,6 +782,7 @@ local list: { Entry } = { mime = { "video/vnd.radgamettools.smacker" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video", "codecs/audio/Stream", "codecs/video/Legacy/Smacker" }, caps = { decode = true, encode = false, streaming = true, video = { "smackvid" }, audio = { "smackaudio", "pcm_u8", "pcm_s16le" } }, + sniff = 0, load = function() return require("@rosetta/video/smk") end, @@ -730,6 +795,7 @@ local list: { Entry } = { mime = { "video/x-yuv4mpeg" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Demux", "codecs/video/Video", "codecs/video/Video/Source" }, caps = { decode = true, encode = true, streaming = true, video = { "rawvideo" }, depths = { 8, 10, 12, 16 } }, + sniff = 0, load = function() return require("@rosetta/video/y4m") end, @@ -742,6 +808,7 @@ local list: { Entry } = { mime = { "application/x-3ds", "image/x-3ds" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Mat4", "codecs/model/MeshFlatten", "codecs/model/Sampler" }, caps = { decode = true, encode = true, materials = true, textures = true, animation = true, cameras = true, lights = true, instancing = true }, + sniff = 0, load = function() return require("@rosetta/model/3ds") end, @@ -754,6 +821,7 @@ local list: { Entry } = { mime = { "model/3mf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Xml", "containers/Zip" }, caps = { decode = true, encode = true, materials = true, vertexColors = true, textures = true, units = true }, + sniff = 0, load = function() return require("@rosetta/model/3mf") end, @@ -766,6 +834,7 @@ local list: { Entry } = { mime = { "model/x-ase", "text/plain" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Text", "codecs/model/Mat4" }, caps = { decode = true, encode = true, text = true, materials = true, cameras = true, lights = true, vertexColors = true }, + sniff = 1, load = function() return require("@rosetta/model/ase") end, @@ -778,6 +847,7 @@ local list: { Entry } = { mime = { "model/x-b3d" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks", "codecs/model/Mat4" }, caps = { decode = true, encode = false, materials = true, textures = true, skins = true, animation = true, colors = true }, + sniff = 0, load = function() return require("@rosetta/model/b3d") end, @@ -790,6 +860,7 @@ local list: { Entry } = { mime = { "application/x-blender" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Blend", "codecs/compress/Deflate", "codecs/compress/Zstd", "codecs/model/Mat4", "codecs/model/Rig", "codecs/model/Polygon" }, caps = { decode = true, encode = false, materials = true, textures = true, animation = true, skins = true, morphTargets = true, cameras = true, lights = true, polygons = true, compressed = true }, + sniff = 1, load = function() return require("@rosetta/model/blend") end, @@ -802,6 +873,7 @@ local list: { Entry } = { mime = { "model/x-bsp" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Pixels", "codecs/image/Miptex", "codecs/model/Patch" }, caps = { decode = true, encode = false, variants = { "quake", "bsp2", "2psb", "halflife", "quake2", "quake3" }, lightmaps = true, collision = true, visibility = true }, + sniff = 0, load = function() return require("@rosetta/model/bsp") end, @@ -814,6 +886,7 @@ local list: { Entry } = { mime = { "application/x-build-map" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Polygon" }, caps = { decode = true, encode = true, sprites = true, slopes = true }, + sniff = 0, load = function() return require("@rosetta/model/buildmap") end, @@ -826,6 +899,7 @@ local list: { Entry } = { mime = { "text/x-doom3-map" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/Brush", "codecs/model/Patch", "codecs/model/Mat4", "codecs/text/Lexer" }, caps = { decode = true, encode = false, patches = true, variants = { "doom3", "quake4" } }, + sniff = 0, load = function() return require("@rosetta/model/d3map") end, @@ -838,6 +912,7 @@ local list: { Entry } = { mime = { "model/vnd.collada+xml", "model/vnd.collada+zip" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Xml", "core/Base64", "containers/Zip", "codecs/model/Mat4" }, caps = { decode = true, encode = true, materials = true, polygons = true, skins = true, morphTargets = true, animation = true, cameras = true, lights = true, zae = true }, + sniff = 0, load = function() return require("@rosetta/model/dae") end, @@ -850,6 +925,7 @@ local list: { Entry } = { mime = { "application/vnd.autodesk.fbx", "model/fbx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate", "core/Base64", "codecs/model/Mat4" }, caps = { decode = true, encode = true, binary = true, ascii = true, materials = true, animation = true, skins = true, morphTargets = true, cameras = true, lights = true, polygons = true }, + sniff = 2, load = function() return require("@rosetta/model/fbx") end, @@ -862,6 +938,7 @@ local list: { Entry } = { mime = { "model/gltf+json", "model/gltf-binary" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Json", "core/Base64", "core/Sniff", "codecs/model/Draco" }, caps = { decode = true, encode = true, binary = true, materials = true, animation = true, skins = true, morphTargets = true, cameras = true, lights = true, draco = true }, + sniff = 0, load = function() return require("@rosetta/model/gltf") end, @@ -874,6 +951,7 @@ local list: { Entry } = { mime = { "application/x-godot-scene" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/GodotVariant", "codecs/model/Mat4" }, caps = { decode = true, encode = true, text = true, materials = true, cameras = true, lights = true, instances = true }, + sniff = 0, load = function() return require("@rosetta/model/godot") end, @@ -886,6 +964,7 @@ local list: { Entry } = { mime = { "model/x-iqm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Mat4", "codecs/model/Rig", "codecs/model/Sampler" }, caps = { decode = true, encode = true, materials = true, skins = true, animation = true, vertexColors = true }, + sniff = 0, load = function() return require("@rosetta/model/iqm") end, @@ -898,6 +977,7 @@ local list: { Entry } = { mime = { "application/x-ldraw", "application/x-multi-part-ldraw" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types" }, caps = { decode = true, encode = false, materials = true, lines = true, instancing = true }, + sniff = 0, load = function() return require("@rosetta/model/ldraw") end, @@ -910,6 +990,7 @@ local list: { Entry } = { mime = { "image/x-lwo", "model/x-lwo" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks" }, caps = { decode = true, encode = false, materials = true, polygons = true, vertexColors = true, morphTargets = true }, + sniff = 0, load = function() return require("@rosetta/model/lwo") end, @@ -922,6 +1003,7 @@ local list: { Entry } = { mime = { "text/x-quake-map" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Miptex", "codecs/model/Brush", "codecs/model/Patch" }, caps = { decode = true, encode = true, variants = { "quake", "valve220", "quake2", "quake3" }, patches = true }, + sniff = 0, load = function() return require("@rosetta/model/map") end, @@ -934,6 +1016,7 @@ local list: { Entry } = { mime = { "application/x-minecraft-region" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate", "codecs/text/Nbt", "codecs/model/Minecraft", "codecs/compress/Lz4" }, caps = { decode = true, encode = false, voxels = true, blocks = true }, + sniff = 0, load = function() return require("@rosetta/model/mca") end, @@ -946,6 +1029,7 @@ local list: { Entry } = { mime = { "model/x-md2" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/Rig" }, caps = { decode = true, encode = false, morph = true, animation = true }, + sniff = 0, load = function() return require("@rosetta/model/md2") end, @@ -958,6 +1042,7 @@ local list: { Entry } = { mime = { "model/x-md3" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/Mat4", "codecs/model/Rig" }, caps = { decode = true, encode = false, morph = true, animation = true, tags = true }, + sniff = 0, load = function() return require("@rosetta/model/md3") end, @@ -970,6 +1055,7 @@ local list: { Entry } = { mime = { "model/x-md5mesh", "model/x-md5anim" }, deps = { "core/Err", "core/Bytes", "core/Input", "core/Sniff", "Types", "codecs/model/Rig" }, caps = { decode = true, encode = false, skins = true, animation = true }, + sniff = 0, load = function() return require("@rosetta/model/md5") end, @@ -982,6 +1068,7 @@ local list: { Entry } = { mime = { "model/x-mdl" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Pixels", "codecs/model/Mat4", "codecs/model/Rig", "codecs/model/SourceAnim" }, caps = { decode = true, encode = false, variants = { "quake", "halflife" }, morph = true, skins = true, animation = true }, + sniff = 0, load = function() return require("@rosetta/model/mdl") end, @@ -994,6 +1081,7 @@ local list: { Entry } = { mime = { "application/x-ms3d" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Mat4", "codecs/model/MeshFlatten" }, caps = { decode = true, encode = true, materials = true, skins = true, animation = true }, + sniff = 1, load = function() return require("@rosetta/model/ms3d") end, @@ -1006,6 +1094,7 @@ local list: { Entry } = { mime = { "model/obj" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, materials = true, polygons = true, vertexColors = true }, + sniff = 0, load = function() return require("@rosetta/model/obj") end, @@ -1018,6 +1107,7 @@ local list: { Entry } = { mime = { "model/off", "text/plain" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/MeshFlatten" }, caps = { decode = true, encode = true, polygons = true, points = true, colors = true, binary = false }, + sniff = 0, load = function() return require("@rosetta/model/off") end, @@ -1030,6 +1120,7 @@ local list: { Entry } = { mime = { "model/ply", "application/ply" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/MeshFlatten" }, caps = { decode = true, encode = true, ascii = true, binary = true, polygons = true, points = true, colors = true }, + sniff = 0, load = function() return require("@rosetta/model/ply") end, @@ -1042,6 +1133,7 @@ local list: { Entry } = { mime = { "model/x-pmx", "model/x-pmd" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Text" }, caps = { decode = true, encode = false, materials = true, skins = true, morphTargets = true, pmd = true }, + sniff = 0, load = function() return require("@rosetta/model/pmx") end, @@ -1054,6 +1146,7 @@ local list: { Entry } = { mime = { "model/x-doom3-proc" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/Lexer" }, caps = { decode = true, encode = false, portals = true }, + sniff = 0, load = function() return require("@rosetta/model/proc") end, @@ -1066,6 +1159,7 @@ local list: { Entry } = { mime = { "model/x-qubicle" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, voxels = true, truecolor = true }, + sniff = 0, load = function() return require("@rosetta/model/qb") end, @@ -1078,6 +1172,8 @@ local list: { Entry } = { mime = { "application/x-roblox-rbxm", "application/x-roblox-rbxl" }, deps = { "core/Err", "core/Bytes", "core/Md5", "codecs/compress/Lz4", "codecs/compress/Zstd", "codecs/model/Rbx", "codecs/model/Rbx/Binary" }, caps = { decode = true, encode = true, tree = true, compression = { "none", "lz4", "zstd" } }, + sniff = 0, + variant = true, load = function() return require("@rosetta/model/rbxm") end, @@ -1090,6 +1186,8 @@ local list: { Entry } = { mime = { "application/x-roblox-rbxmx", "application/x-roblox-rbxlx" }, deps = { "core/Err", "core/Bytes", "core/Base64", "core/Md5", "codecs/text/Xml", "codecs/model/Rbx" }, caps = { decode = true, encode = true, tree = true }, + sniff = 0, + variant = true, load = function() return require("@rosetta/model/rbxmx") end, @@ -1102,6 +1200,7 @@ local list: { Entry } = { mime = { "application/x-roblox-mesh" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Mat4", "codecs/model/MeshFlatten", "codecs/model/Draco" }, caps = { decode = true, encode = true, skinning = true, lods = true, versions = { "1.00", "1.01", "2.00", "3.00", "3.01", "4.00", "4.01", "5.00", "6.00", "7.00" } }, + sniff = 0, load = function() return require("@rosetta/model/robloxmesh") end, @@ -1114,6 +1213,8 @@ local list: { Entry } = { mime = { "application/x-minecraft-schematic" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Nbt", "codecs/model/Minecraft" }, caps = { decode = true, encode = true, voxels = true, blocks = true, variants = { "schem", "schematic", "litematic" } }, + sniff = 1, + variant = true, load = function() return require("@rosetta/model/schematic") end, @@ -1126,6 +1227,7 @@ local list: { Entry } = { mime = { "model/x-smd", "text/plain" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/Mat4", "codecs/model/MeshFlatten", "codecs/model/Rig" }, caps = { decode = true, encode = true, skins = true, animation = true }, + sniff = 0, load = function() return require("@rosetta/model/smd") end, @@ -1138,6 +1240,7 @@ local list: { Entry } = { mime = { "model/x-source-mdl" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "codecs/image/Half", "codecs/model/Mat4", "codecs/model/Rig", "codecs/model/SourceAnim", "codecs/text/KeyValues" }, caps = { decode = true, encode = false, skins = true, morph = true, animation = true, lods = true }, + sniff = 0, load = function() return require("@rosetta/model/sourcemdl") end, @@ -1150,6 +1253,7 @@ local list: { Entry } = { mime = { "model/stl", "application/sla" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/MeshFlatten" }, caps = { decode = true, encode = true, ascii = true, binary = true, colors = true, indexed = false }, + sniff = 0, load = function() return require("@rosetta/model/stl") end, @@ -1162,6 +1266,7 @@ local list: { Entry } = { mime = { "text/x-unreal-t3d" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/Text", "codecs/model/Brush" }, caps = { decode = true, encode = false, text = true, brushes = true, actors = true }, + sniff = 0, load = function() return require("@rosetta/model/t3d") end, @@ -1174,6 +1279,7 @@ local list: { Entry } = { mime = { "text/x-udmf" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/model/DoomMap" }, caps = { decode = true, encode = false, maps = true }, + sniff = 0, load = function() return require("@rosetta/model/udmf") end, @@ -1186,6 +1292,7 @@ local list: { Entry } = { mime = { "model/vnd.usda", "model/vnd.usdz+zip" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Zip", "codecs/model/Mat4" }, caps = { decode = true, encode = true, materials = true, animation = true, cameras = true, lights = true, polygons = true, vertexColors = true, usdz = "read", usdc = false }, + sniff = 0, load = function() return require("@rosetta/model/usda") end, @@ -1198,6 +1305,7 @@ local list: { Entry } = { mime = { "model/x-vbsp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Lzma", "codecs/text/KeyValues", "codecs/model/Mat4", "codecs/model/Displacement", "containers/Zip", "containers/Archive" }, caps = { decode = true, encode = false, versions = { 19, 20, 21 }, displacements = true, staticProps = true, pak = true }, + sniff = 0, load = function() return require("@rosetta/model/vbsp") end, @@ -1210,6 +1318,7 @@ local list: { Entry } = { mime = { "model/x-vmf" }, deps = { "core/Err", "core/Bytes", "core/Input", "core/Sniff", "Types", "codecs/text/KeyValues", "codecs/model/Brush", "codecs/model/Displacement", "codecs/model/Mat4" }, caps = { decode = true, encode = true, displacements = true, roundTrip = true }, + sniff = 0, load = function() return require("@rosetta/model/vmf") end, @@ -1222,6 +1331,7 @@ local list: { Entry } = { mime = { "model/x-vox" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, voxels = true, sceneGraph = true, materials = true }, + sniff = 0, load = function() return require("@rosetta/model/vox") end, @@ -1234,6 +1344,7 @@ local list: { Entry } = { mime = { "model/vrml", "x-world/x-vrml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Vrml" }, caps = { decode = true, encode = true, materials = true, polygons = true, animation = true, cameras = true, lights = true, lines = true, points = true }, + sniff = 0, load = function() return require("@rosetta/model/vrml") end, @@ -1246,6 +1357,7 @@ local list: { Entry } = { mime = { "model/x-directx", "text/x-directx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate", "codecs/model/Mat4", "codecs/model/Rig" }, caps = { decode = true, encode = false, text = true, binary = true, compressed = true, materials = true, skins = true, animation = true, polygons = true, vertexColors = true }, + sniff = 0, load = function() return require("@rosetta/model/x") end, @@ -1258,6 +1370,7 @@ local list: { Entry } = { mime = { "model/x3d+xml", "model/x3d-vrml", "model/x3d+fastinfoset" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/model/Vrml" }, caps = { decode = true, encode = true, materials = true, polygons = true, animation = true, cameras = true, lights = true, lines = true, points = true, xml = true, classic = true }, + sniff = 0, load = function() return require("@rosetta/model/x3d") end, @@ -1270,6 +1383,7 @@ local list: { Entry } = { mime = { "model/step", "application/step", "application/p21" }, deps = { "core/Err", "core/Bytes", "Types", "core/Sniff" }, caps = { decode = true, encode = true, complexEntities = true, sections = true, brep = "plugin", tessellate = "plugin" }, + sniff = 0, load = function() return require("@rosetta/cad/step") end, @@ -1282,6 +1396,7 @@ local list: { Entry } = { mime = { "application/x-font-bdf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/font/Bitmap" }, caps = { decode = true, encode = true, bitmap = true }, + sniff = 0, load = function() return require("@rosetta/font/bdf") end, @@ -1294,6 +1409,7 @@ local list: { Entry } = { mime = { "application/x-bmfont" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, bitmap = true, variants = { "text", "xml", "binary" }, extraFiles = true }, + sniff = 0, load = function() return require("@rosetta/font/bmfont") end, @@ -1306,6 +1422,7 @@ local list: { Entry } = { mime = { "application/vnd.ms-fontobject" }, deps = { "core/Err", "core/Bytes", "codecs/text/Text", "codecs/font/TrueType" }, caps = { decode = true, encode = true, variants = { "1.0", "2.1", "2.2" } }, + sniff = 0, load = function() return require("@rosetta/font/eot") end, @@ -1318,6 +1435,7 @@ local list: { Entry } = { mime = { "application/x-font-fnt" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Text", "codecs/font/Bitmap" }, caps = { decode = true, encode = false, bitmap = true, variants = { "fnt2", "fnt3", "ne", "pe" } }, + sniff = 0, load = function() return require("@rosetta/font/fon") end, @@ -1330,6 +1448,7 @@ local list: { Entry } = { mime = { "application/x-hershey-font" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Raster" }, caps = { decode = true, encode = false, strokes = true }, + sniff = 0, load = function() return require("@rosetta/font/hershey") end, @@ -1342,6 +1461,7 @@ local list: { Entry } = { mime = { "application/x-font-pcf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/font/Bitmap" }, caps = { decode = true, encode = false, bitmap = true }, + sniff = 0, load = function() return require("@rosetta/font/pcf") end, @@ -1354,6 +1474,7 @@ local list: { Entry } = { mime = { "application/x-font-linux-psf" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/font/Bitmap" }, caps = { decode = true, encode = true, bitmap = true, variants = { "psf1", "psf2" } }, + sniff = 0, load = function() return require("@rosetta/font/psf") end, @@ -1366,6 +1487,7 @@ local list: { Entry } = { mime = { "font/ttf", "font/otf", "font/collection" }, deps = { "core/Err", "core/Bytes", "codecs/font/TrueType" }, caps = { decode = true, encode = false, outlines = { "truetype", "cff" }, collection = true, kerning = true }, + sniff = 0, load = function() return require("@rosetta/font/ttf") end, @@ -1378,6 +1500,7 @@ local list: { Entry } = { mime = { "application/x-font-type1" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Raster", "codecs/font/GlyphNames" }, caps = { decode = true, encode = false, outlines = { "type1" }, variants = { "pfb", "pfa" } }, + sniff = 0, load = function() return require("@rosetta/font/type1") end, @@ -1390,6 +1513,7 @@ local list: { Entry } = { mime = { "font/woff" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Deflate", "codecs/font/TrueType" }, caps = { decode = true, encode = false, outlines = { "truetype", "cff" } }, + sniff = 0, load = function() return require("@rosetta/font/woff") end, @@ -1402,6 +1526,7 @@ local list: { Entry } = { mime = { "font/woff2" }, deps = { "core/Err", "core/Bytes", "codecs/font/TrueType", "codecs/compress/Brotli" }, caps = { decode = true, encode = false, outlines = { "truetype", "cff" }, transforms = { "glyf", "loca", "hmtx" } }, + sniff = 0, load = function() return require("@rosetta/font/woff2") end, @@ -1414,6 +1539,7 @@ local list: { Entry } = { mime = { "application/x-7z-compressed" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "Types", "codecs/compress/Lzma", "codecs/compress/Deflate", "codecs/compress/Bzip2", "codecs/compress/Zstd", "containers/Archive", "codecs/text/Text" }, caps = { decode = true, encode = false, methods = { "copy", "lzma", "lzma2", "deflate", "bcj", "delta" }, encrypted = false }, + sniff = 0, load = function() return require("@rosetta/archive/7z") end, @@ -1426,6 +1552,7 @@ local list: { Entry } = { mime = { "application/x-amiga-disk-format" }, deps = { "core/Err", "core/Bytes", "containers/Archive" }, caps = { decode = true, encode = false, variants = { "ofs", "ffs" } }, + sniff = 0, load = function() return require("@rosetta/archive/adf") end, @@ -1438,6 +1565,7 @@ local list: { Entry } = { mime = { "application/applefile", "multipart/appledouble" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/MacFile" }, caps = { decode = true, encode = true, forks = true, variants = { "applesingle", "appledouble" } }, + sniff = 0, load = function() return require("@rosetta/archive/applesingle") end, @@ -1450,6 +1578,7 @@ local list: { Entry } = { mime = { "application/x-archive", "application/vnd.debian.binary-package" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Deflate", "codecs/compress/Lzma", "codecs/compress/Zstd", "codecs/compress/Bzip2", "containers/Archive", "containers/Tar" }, caps = { decode = true, encode = true, variants = { "gnu", "bsd" }, deb = true }, + sniff = 0, load = function() return require("@rosetta/archive/ar") end, @@ -1462,6 +1591,7 @@ local list: { Entry } = { mime = { "application/x-arj" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "codecs/compress/Lzh", "containers/Archive" }, caps = { decode = true, encode = false, methods = { "store", "arj1", "arj2", "arj3", "arj4" } }, + sniff = 0, load = function() return require("@rosetta/archive/arj") end, @@ -1474,6 +1604,7 @@ local list: { Entry } = { mime = { "application/mac-binhex40" }, deps = { "core/Err", "core/Bytes", "core/Crc16", "containers/Archive", "containers/MacFile" }, caps = { decode = true, encode = true, forks = true }, + sniff = 0, load = function() return require("@rosetta/archive/binhex") end, @@ -1486,6 +1617,7 @@ local list: { Entry } = { mime = { "application/x-brotli" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Brotli", "containers/Archive" }, caps = { decode = true, encode = false, stream = true }, + sniff = 1, load = function() return require("@rosetta/archive/br") end, @@ -1498,6 +1630,7 @@ local list: { Entry } = { mime = { "application/x-bzip2" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "codecs/compress/Bzip2" }, caps = { decode = true, encode = false, stream = true }, + sniff = 0, load = function() return require("@rosetta/archive/bz2") end, @@ -1510,6 +1643,7 @@ local list: { Entry } = { mime = { "application/vnd.ms-cab-compressed" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Deflate", "codecs/compress/Lzx", "codecs/compress/Quantum", "containers/Archive" }, caps = { decode = true, encode = true, methods = { "store", "mszip", "lzx", "quantum" } }, + sniff = 0, load = function() return require("@rosetta/archive/cab") end, @@ -1522,6 +1656,7 @@ local list: { Entry } = { mime = { "application/x-cpio" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/Cpio" }, caps = { decode = true, encode = true, variants = { "newc", "crc", "odc", "bin" } }, + sniff = 0, load = function() return require("@rosetta/archive/cpio") end, @@ -1534,6 +1669,7 @@ local list: { Entry } = { mime = { "application/x-d64" }, deps = { "core/Err", "core/Bytes", "containers/Archive" }, caps = { decode = true, encode = true, variants = { "d64", "d71", "d81" } }, + sniff = 0, load = function() return require("@rosetta/archive/d64") end, @@ -1546,6 +1682,7 @@ local list: { Entry } = { mime = { "application/x-fat-image" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/Fat" }, caps = { decode = true, encode = true, variants = { "fat12", "fat16", "fat32" } }, + sniff = 1, load = function() return require("@rosetta/archive/fat") end, @@ -1558,6 +1695,7 @@ local list: { Entry } = { mime = { "application/x-build-grp" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "containers/Archive" }, caps = { decode = true, encode = true }, + sniff = 0, load = function() return require("@rosetta/archive/grp") end, @@ -1570,6 +1708,7 @@ local list: { Entry } = { mime = { "application/gzip" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "codecs/compress/Deflate", "containers/Archive", "containers/Tar" }, caps = { decode = true, encode = true, stream = true }, + sniff = 0, load = function() return require("@rosetta/archive/gzip") end, @@ -1582,6 +1721,7 @@ local list: { Entry } = { mime = { "application/x-iso9660-image" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/Iso9660" }, caps = { decode = true, encode = false, extensions = { "joliet", "rockridge", "eltorito" } }, + sniff = 0, load = function() return require("@rosetta/archive/iso") end, @@ -1594,6 +1734,7 @@ local list: { Entry } = { mime = { "application/x-lzh-compressed" }, deps = { "core/Err", "core/Bytes", "core/Crc16", "codecs/compress/Lzh", "containers/Archive" }, caps = { decode = true, encode = true, methods = { "lh0", "lh1", "lh4", "lh5", "lh6", "lh7", "lhx", "lzs", "lz5", "lz4", "lhd" } }, + sniff = 0, load = function() return require("@rosetta/archive/lha") end, @@ -1606,6 +1747,7 @@ local list: { Entry } = { mime = { "application/x-lz4" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Lz4", "codecs/compress/Xxh32", "containers/Archive" }, caps = { decode = true, encode = true, stream = true, legacy = true }, + sniff = 0, load = function() return require("@rosetta/archive/lz4") end, @@ -1618,6 +1760,7 @@ local list: { Entry } = { mime = { "application/x-macbinary" }, deps = { "core/Err", "core/Bytes", "core/Crc16", "containers/Archive", "containers/MacFile" }, caps = { decode = true, encode = true, forks = true, variants = { "I", "II", "III" } }, + sniff = 0, load = function() return require("@rosetta/archive/macbinary") end, @@ -1630,6 +1773,7 @@ local list: { Entry } = { mime = { "application/x-mpq" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "codecs/compress/Deflate", "codecs/compress/Bzip2", "codecs/compress/Lzma", "codecs/compress/Explode" }, caps = { decode = true, encode = false, versions = { 1, 2, 3, 4 }, methods = { "zlib", "implode", "bzip2", "lzma", "sparse" }, encryption = true }, + sniff = 0, load = function() return require("@rosetta/archive/mpq") end, @@ -1642,6 +1786,7 @@ local list: { Entry } = { mime = { "application/x-pak" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "containers/Archive" }, caps = { decode = true, encode = true, variants = { "quake", "sin" } }, + sniff = 0, load = function() return require("@rosetta/archive/pak") end, @@ -1654,6 +1799,7 @@ local list: { Entry } = { mime = { "application/x-rpm" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Deflate", "codecs/compress/Lzma", "codecs/compress/Zstd", "codecs/compress/Bzip2", "containers/Archive", "containers/Cpio" }, caps = { decode = true, encode = false, compressors = { "gzip", "bzip2", "xz", "lzma", "zstd" } }, + sniff = 0, load = function() return require("@rosetta/archive/rpm") end, @@ -1666,6 +1812,7 @@ local list: { Entry } = { mime = { "application/x-tar" }, deps = { "core/Err", "core/Bytes", "containers/Archive", "containers/Tar" }, caps = { decode = true, encode = true, variants = { "ustar", "pax", "gnu" } }, + sniff = 1, load = function() return require("@rosetta/archive/tar") end, @@ -1678,6 +1825,7 @@ local list: { Entry } = { mime = { "application/x-unitypackage" }, deps = { "core/Err", "core/Bytes", "core/Md5", "codecs/compress/Deflate", "containers/Archive", "containers/Tar" }, caps = { decode = true, encode = true }, + sniff = 1, load = function() return require("@rosetta/archive/unitypackage") end, @@ -1690,6 +1838,7 @@ local list: { Entry } = { mime = { "text/x-uuencode" }, deps = { "core/Err", "core/Bytes", "core/Base64", "containers/Archive" }, caps = { decode = true, encode = true, variants = { "uu", "xx", "base64" } }, + sniff = 0, load = function() return require("@rosetta/archive/uu") end, @@ -1702,6 +1851,7 @@ local list: { Entry } = { mime = { "application/x-vpk" }, deps = { "core/Err", "core/Bytes", "core/Input", "core/Crc32", "core/Md5", "containers/Archive" }, caps = { decode = true, encode = true, versions = { 1, 2 }, multipart = true }, + sniff = 0, load = function() return require("@rosetta/archive/vpk") end, @@ -1714,6 +1864,7 @@ local list: { Entry } = { mime = { "application/x-wolf3d-vswap" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Archive", "codecs/image/Pixels" }, caps = { decode = true, encode = false, images = true, sounds = true }, + sniff = 0, load = function() return require("@rosetta/archive/vswap") end, @@ -1726,6 +1877,7 @@ local list: { Entry } = { mime = { "application/x-doom" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Archive", "codecs/image/Pixels", "codecs/model/DoomMap" }, caps = { decode = true, encode = true, images = true, maps = true, variants = { "iwad", "pwad" } }, + sniff = 0, load = function() return require("@rosetta/archive/wad") end, @@ -1738,6 +1890,7 @@ local list: { Entry } = { mime = { "application/x-quake-wad" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types", "containers/Archive", "codecs/image/Pixels", "codecs/image/Miptex" }, caps = { decode = true, encode = true, images = true, variants = { "wad2", "wad3" } }, + sniff = 0, load = function() return require("@rosetta/archive/wad2") end, @@ -1750,6 +1903,7 @@ local list: { Entry } = { mime = { "application/x-xz", "application/x-lzma" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Lzma", "containers/Archive" }, caps = { decode = true, encode = false, stream = true, filters = { "lzma2", "lzma", "delta", "x86", "powerpc", "arm", "armthumb", "sparc", "arm64" } }, + sniff = 0, load = function() return require("@rosetta/archive/xz") end, @@ -1762,6 +1916,7 @@ local list: { Entry } = { mime = { "application/x-yenc" }, deps = { "core/Err", "core/Bytes", "core/Crc32", "containers/Archive" }, caps = { decode = true, encode = true, multipart = true }, + sniff = 0, load = function() return require("@rosetta/archive/yenc") end, @@ -1774,6 +1929,7 @@ local list: { Entry } = { mime = { "application/x-compress" }, deps = { "core/Err", "core/Bytes", "codecs/compress/UnixCompress", "containers/Archive" }, caps = { decode = true, encode = true, stream = true, bits = { 9, 16 } }, + sniff = 0, load = function() return require("@rosetta/archive/z") end, @@ -1786,6 +1942,7 @@ local list: { Entry } = { mime = { "application/zip", "application/x-zip-compressed" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Zip" }, caps = { decode = true, encode = true, methods = { "store", "deflate" }, zip64 = true }, + sniff = 0, load = function() return require("@rosetta/archive/zip") end, @@ -1798,6 +1955,7 @@ local list: { Entry } = { mime = { "application/x-zoo" }, deps = { "core/Err", "core/Bytes", "core/Crc16", "codecs/compress/Lzw", "codecs/compress/Lzh", "containers/Archive" }, caps = { decode = true, encode = false, methods = { "store", "lzw", "lzh" } }, + sniff = 0, load = function() return require("@rosetta/archive/zoo") end, @@ -1810,6 +1968,7 @@ local list: { Entry } = { mime = { "application/zstd" }, deps = { "core/Err", "core/Bytes", "codecs/compress/Zstd", "containers/Archive" }, caps = { decode = true, encode = false, stream = true }, + sniff = 1, load = function() return require("@rosetta/archive/zst") end, @@ -1822,6 +1981,7 @@ local list: { Entry } = { mime = { "application/cbor", "application/cbor-seq" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, binary = true, ordered = true, tags = true }, + sniff = 0, load = function() return require("@rosetta/data/cbor") end, @@ -1834,6 +1994,7 @@ local list: { Entry } = { mime = { "text/csv", "text/tab-separated-values" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Json", "core/Sniff" }, caps = { decode = true, encode = true, header = true }, + sniff = 0, load = function() return require("@rosetta/data/csv") end, @@ -1846,6 +2007,7 @@ local list: { Entry } = { mime = { "text/plain" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Json", "core/Sniff" }, caps = { decode = true, encode = true, ordered = true }, + sniff = 0, load = function() return require("@rosetta/data/ini") end, @@ -1858,6 +2020,7 @@ local list: { Entry } = { mime = { "application/json", "application/x-ndjson" }, deps = { "core/Err", "core/Bytes", "codecs/text/Json", "core/Sniff" }, caps = { decode = true, encode = true, ordered = true, streaming = true }, + sniff = 0, load = function() return require("@rosetta/data/json") end, @@ -1870,6 +2033,7 @@ local list: { Entry } = { mime = { "application/msgpack", "application/x-msgpack" }, deps = { "core/Err", "core/Bytes", "Types" }, caps = { decode = true, encode = true, binary = true, ordered = true }, + sniff = 0, load = function() return require("@rosetta/data/msgpack") end, @@ -1882,6 +2046,7 @@ local list: { Entry } = { mime = { "application/x-minecraft-nbt" }, deps = { "core/Err", "core/Bytes", "codecs/text/Nbt" }, caps = { decode = true, encode = true, binary = true, ordered = true, typed = true }, + sniff = 1, load = function() return require("@rosetta/data/nbt") end, @@ -1894,6 +2059,7 @@ local list: { Entry } = { mime = { "application/x-plist", "application/x-bplist" }, deps = { "core/Err", "core/Bytes", "Types", "core/Base64", "codecs/text/Xml", "codecs/text/Json" }, caps = { decode = true, encode = true, binary = "read", ordered = true }, + sniff = 0, load = function() return require("@rosetta/data/plist") end, @@ -1906,6 +2072,7 @@ local list: { Entry } = { mime = { "text/x-quake3-shader" }, deps = { "core/Err", "core/Bytes" }, caps = { decode = true, encode = true }, + sniff = 0, load = function() return require("@rosetta/data/q3shader") end, @@ -1918,6 +2085,7 @@ local list: { Entry } = { mime = { "text/x-quake3-skin" }, deps = { "core/Err", "core/Bytes" }, caps = { decode = true, encode = true }, + sniff = 0, load = function() return require("@rosetta/data/q3skin") end, @@ -1930,6 +2098,7 @@ local list: { Entry } = { mime = { "text/x-minecraft-snbt" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "codecs/text/Nbt" }, caps = { decode = true, encode = true, ordered = true, typed = true }, + sniff = 0, load = function() return require("@rosetta/data/snbt") end, @@ -1942,6 +2111,7 @@ local list: { Entry } = { mime = { "application/toml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Json", "codecs/text/Text" }, caps = { decode = true, encode = true, ordered = true, dates = true }, + sniff = 0, load = function() return require("@rosetta/data/toml") end, @@ -1954,6 +2124,7 @@ local list: { Entry } = { mime = { "application/x-godot-resource" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/GodotVariant" }, caps = { decode = true, encode = true, ordered = true }, + sniff = 0, load = function() return require("@rosetta/data/tres") end, @@ -1966,6 +2137,7 @@ local list: { Entry } = { mime = { "text/x-vdf" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "codecs/text/KeyValues" }, caps = { decode = true, encode = true, ordered = true, binary = true }, + sniff = 1, load = function() return require("@rosetta/data/vdf") end, @@ -1978,6 +2150,7 @@ local list: { Entry } = { mime = { "application/xml", "text/xml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Xml", "core/Sniff" }, caps = { decode = true, encode = true, namespaces = true, streaming = true }, + sniff = 0, load = function() return require("@rosetta/data/xml") end, @@ -1990,6 +2163,7 @@ local list: { Entry } = { mime = { "application/yaml", "application/x-yaml", "text/yaml" }, deps = { "core/Err", "core/Bytes", "Types", "core/Base64", "codecs/text/Text" }, caps = { decode = true, encode = true, ordered = true, multiDocument = true, anchors = true }, + sniff = 0, load = function() return require("@rosetta/data/yaml") end, @@ -2002,6 +2176,7 @@ local list: { Entry } = { mime = { "application/x-wolf3d-gamemaps" }, deps = { "core/Err", "core/Bytes", "core/Input", "Types" }, caps = { decode = true, encode = false, tilemap = true }, + sniff = 0, load = function() return require("@rosetta/vector/gamemaps") end, @@ -2014,6 +2189,7 @@ local list: { Entry } = { mime = { "application/x-ldtk+json" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "Types", "codecs/text/Json" }, caps = { decode = true, encode = true, levels = true, worlds = true, intGrid = true, entities = true }, + sniff = 0, load = function() return require("@rosetta/vector/ldtk") end, @@ -2026,6 +2202,7 @@ local list: { Entry } = { mime = { "application/x-ogmo+json" }, deps = { "core/Err", "core/Bytes", "core/Sniff", "core/Base64", "Types", "codecs/text/Json" }, caps = { decode = true, encode = true, projects = true, entities = true, decals = true }, + sniff = 0, load = function() return require("@rosetta/vector/ogmo") end, @@ -2038,6 +2215,7 @@ local list: { Entry } = { mime = { "image/svg+xml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Xml", "codecs/image/Raster", "codecs/image/Blend", "core/Sniff" }, caps = { decode = true, encode = true, rasterize = true, text = false }, + sniff = 0, load = function() return require("@rosetta/vector/svg") end, @@ -2050,6 +2228,7 @@ local list: { Entry } = { mime = { "application/x-tiled-tmx", "application/x-tiled-tmj" }, deps = { "core/Err", "core/Bytes", "core/Base64", "Types", "codecs/text/Xml", "codecs/text/Json", "codecs/compress/Deflate", "core/Sniff" }, caps = { decode = true, encode = true, tilesets = true, infinite = true }, + sniff = 0, load = function() return require("@rosetta/vector/tiled") end, @@ -2062,6 +2241,7 @@ local list: { Entry } = { mime = { "image/x-aseprite" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/compress/Deflate" }, caps = { decode = true, encode = true, layers = true, groups = true, animation = true, depths = { 8, 16, 32 } }, + sniff = 0, load = function() return require("@rosetta/layered/aseprite") end, @@ -2074,6 +2254,7 @@ local list: { Entry } = { mime = { "image/openraster" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Zip", "codecs/text/Xml", "codecs/image/Blend" }, caps = { decode = true, encode = true, layers = true, groups = true, depths = { 8 } }, + sniff = 0, load = function() return require("@rosetta/layered/ora") end, @@ -2086,6 +2267,7 @@ local list: { Entry } = { mime = { "image/vnd.adobe.photoshop" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/image/Blend", "codecs/compress/Deflate", "codecs/compress/PackBits", "codecs/text/Text" }, caps = { decode = true, encode = true, layers = true, groups = true, depths = { 1, 8, 16, 32 } }, + sniff = 0, load = function() return require("@rosetta/layered/psd") end, @@ -2098,6 +2280,7 @@ local list: { Entry } = { mime = { "text/x-ssa", "text/x-ass" }, deps = { "core/Err", "core/Bytes", "Types", "core/Sniff" }, caps = { decode = true, encode = true, styles = true }, + sniff = 0, load = function() return require("@rosetta/subtitle/ass") end, @@ -2110,6 +2293,7 @@ local list: { Entry } = { mime = { "application/x-subrip", "text/srt" }, deps = { "core/Err", "core/Bytes", "Types", "core/Sniff" }, caps = { decode = true, encode = true, styles = false }, + sniff = 0, load = function() return require("@rosetta/subtitle/srt") end, @@ -2122,6 +2306,7 @@ local list: { Entry } = { mime = { "text/vtt" }, deps = { "core/Err", "core/Bytes", "Types", "core/Sniff" }, caps = { decode = true, encode = true, styles = true }, + sniff = 0, load = function() return require("@rosetta/subtitle/vtt") end, @@ -2134,6 +2319,7 @@ local list: { Entry } = { mime = { "audio/x-669" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 8, 8 } }, + sniff = 0, load = function() return require("@rosetta/music/669") end, @@ -2146,6 +2332,7 @@ local list: { Entry } = { mime = { "audio/x-ahx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Hively" }, caps = { decode = true, encode = false, render = true, channels = { 4, 4 }, subsongs = true }, + sniff = 0, load = function() return require("@rosetta/music/ahx") end, @@ -2158,6 +2345,7 @@ local list: { Entry } = { mime = { "audio/x-far" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 16, 16 } }, + sniff = 0, load = function() return require("@rosetta/music/far") end, @@ -2170,6 +2358,7 @@ local list: { Entry } = { mime = { "audio/x-hmp" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/MidiRender" }, caps = { decode = true, encode = false, render = true, hmi = true }, + sniff = 0, load = function() return require("@rosetta/music/hmp") end, @@ -2182,6 +2371,7 @@ local list: { Entry } = { mime = { "audio/x-hvl" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Hively" }, caps = { decode = true, encode = false, render = true, channels = { 4, 16 }, subsongs = true }, + sniff = 0, load = function() return require("@rosetta/music/hvl") end, @@ -2194,6 +2384,7 @@ local list: { Entry } = { mime = { "audio/it", "audio/x-it" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker" }, caps = { decode = true, encode = false, render = true, channels = { 1, 64 }, compressedSamples = true }, + sniff = 0, load = function() return require("@rosetta/music/it") end, @@ -2206,6 +2397,7 @@ local list: { Entry } = { mime = { "audio/x-med" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 1, 64 } }, + sniff = 0, load = function() return require("@rosetta/music/med") end, @@ -2218,6 +2410,7 @@ local list: { Entry } = { mime = { "audio/midi", "audio/x-midi" }, deps = { "core/Err", "core/Bytes", "codecs/audio/MidiRender", "Types" }, caps = { decode = true, encode = true, formats = { 0, 1, 2 }, render = true, streaming = true, rmid = true }, + sniff = 0, load = function() return require("@rosetta/music/midi") end, @@ -2230,6 +2423,7 @@ local list: { Entry } = { mime = { "audio/x-mod", "audio/mod" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker" }, caps = { decode = true, encode = true, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return require("@rosetta/music/mod") end, @@ -2242,6 +2436,7 @@ local list: { Entry } = { mime = { "audio/x-mtm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return require("@rosetta/music/mtm") end, @@ -2254,6 +2449,7 @@ local list: { Entry } = { mime = { "audio/x-mus" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/MidiRender" }, caps = { decode = true, encode = false, render = true }, + sniff = 0, load = function() return require("@rosetta/music/mus") end, @@ -2266,6 +2462,7 @@ local list: { Entry } = { mime = { "audio/x-okt" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 4, 8 } }, + sniff = 0, load = function() return require("@rosetta/music/okt") end, @@ -2278,6 +2475,7 @@ local list: { Entry } = { mime = { "audio/x-ptm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return require("@rosetta/music/ptm") end, @@ -2290,6 +2488,7 @@ local list: { Entry } = { mime = { "audio/s3m", "audio/x-s3m" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker" }, caps = { decode = true, encode = false, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return require("@rosetta/music/s3m") end, @@ -2302,6 +2501,7 @@ local list: { Entry } = { mime = { "audio/x-soundfont" }, deps = { "core/Err", "core/Bytes", "codecs/audio/SoundFont" }, caps = { decode = true, encode = false, sm24 = true, sf3 = false }, + sniff = 1, load = function() return require("@rosetta/music/sf2") end, @@ -2314,6 +2514,7 @@ local list: { Entry } = { mime = { "audio/x-stm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 4, 4 } }, + sniff = 0, load = function() return require("@rosetta/music/stm") end, @@ -2326,6 +2527,7 @@ local list: { Entry } = { mime = { "audio/x-ult" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Tracker/Load" }, caps = { decode = true, encode = false, render = true, channels = { 1, 32 } }, + sniff = 0, load = function() return require("@rosetta/music/ult") end, @@ -2338,6 +2540,7 @@ local list: { Entry } = { mime = { "audio/x-umx" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker" }, caps = { decode = true, encode = false, render = true, container = true }, + sniff = 0, load = function() return require("@rosetta/music/umx") end, @@ -2350,6 +2553,7 @@ local list: { Entry } = { mime = { "audio/xm", "audio/x-xm" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/audio/Tracker", "codecs/audio/Adpcm" }, caps = { decode = true, encode = true, render = true, channels = { 1, 64 } }, + sniff = 0, load = function() return require("@rosetta/music/xm") end, @@ -2362,6 +2566,7 @@ local list: { Entry } = { mime = { "audio/x-xmidi" }, deps = { "core/Err", "core/Bytes", "Types", "containers/Chunks", "codecs/audio/MidiRender" }, caps = { decode = true, encode = false, render = true, songs = true }, + sniff = 0, load = function() return require("@rosetta/music/xmi") end, @@ -2374,6 +2579,7 @@ local list: { Entry } = { mime = { "audio/x-mpegurl", "audio/mpegurl", "application/vnd.apple.mpegurl", "application/x-mpegurl" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Url", "codecs/text/Text", "core/Sniff" }, caps = { decode = true, encode = true, hls = true }, + sniff = 0, load = function() return require("@rosetta/playlist/m3u") end, @@ -2386,6 +2592,7 @@ local list: { Entry } = { mime = { "audio/x-scpls", "audio/scpls" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Url", "codecs/text/Text", "core/Sniff" }, caps = { decode = true, encode = true }, + sniff = 1, load = function() return require("@rosetta/playlist/pls") end, @@ -2398,6 +2605,7 @@ local list: { Entry } = { mime = { "application/xspf+xml" }, deps = { "core/Err", "core/Bytes", "Types", "codecs/text/Url", "codecs/text/Xml" }, caps = { decode = true, encode = true }, + sniff = 0, load = function() return require("@rosetta/playlist/xspf") end, diff --git a/src/Rosetta/Sniffs.luau b/src/Rosetta/Sniffs.luau new file mode 100644 index 0000000..9df7fe1 --- /dev/null +++ b/src/Rosetta/Sniffs.luau @@ -0,0 +1,3384 @@ +--!strict +--!optimize 2 +-- Sniffs: GENERATED by tools/gen_registry.py from the format folders - do not edit. +-- Each format's sniff (format path -> sniff(r)), copied from its init.luau with the top-level locals and types it +-- reaches (tools/sniff_extract.py), so detection requires no format module. Requires outside core/ are proxies that +-- require on first use. Formats whose sniff needs their module (Registry sniff = 2) are not here. +local S: { [string]: (any) -> number } = {} + +local function lazy(load: () -> any): any + local proxy = {} + return setmetatable(proxy, { + __index = function(_, k: any): any + local m = load() + setmetatable(proxy, { __index = m }) + return m[k] + end, + }) +end + +do -- image/ani +local Bytes = require("@rosetta/core/Bytes") +S["image/ani"] = function(r: Bytes.Reader): number + return if r:peek(4) == "RIFF" and r:peek(4, 8) == "ACON" then 1 else 0 +end +end + +do -- image/art +local Bytes = require("@rosetta/core/Bytes") +local readu8, readu16, readu32, readi16 = buffer.readu8, buffer.readu16, buffer.readu32, buffer.readi16 +local function header(b: buffer, o: number, limit: number): (number?, number?, number?, number?, boolean?) + local p = o + local prefixed = false + if limit - p >= 8 and buffer.readstring(b, p, 8) == "BUILDART" then + p += 8 + prefixed = true + end + if limit - p < 16 or readu32(b, p) ~= 1 then + return nil, nil, nil, nil, nil + end + local first, last = readu32(b, p + 8), readu32(b, p + 12) + if last < first or last - first >= 65536 then + return nil, nil, nil, nil, nil + end + return p + 16, first, last, readu32(b, p + 4), prefixed +end +S["image/art"] = function(r: Bytes.Reader): number + local at, first, last = header(r.buf, r.base, r.limit) + if not at or not first or not last then + return 0 + end + local n = last - first + 1 + local p = at :: number + if r.limit - p < n * 8 then + return 0 + end + local total = 0 + for i = 0, n - 1 do + local w, h = readi16(r.buf, p + i * 2), readi16(r.buf, p + n * 2 + i * 2) + if w < 0 or h < 0 then + return 0 + end + total += w * h + end + local size = p + n * 8 + total - r.base + local have = r.limit - r.base + return if size == have then 0.9 elseif size < have and have - size < 4096 then 0.5 else 0 +end +end + +do -- image/blp +local Bytes = require("@rosetta/core/Bytes") +S["image/blp"] = function(r: Bytes.Reader): number + local m = r:peek(4) + return if m == "BLP1" or m == "BLP2" then 1 elseif m == "BLP0" then 0.8 else 0 +end +end + +do -- image/bmp +local Bytes = require("@rosetta/core/Bytes") +S["image/bmp"] = function(r: Bytes.Reader): number + if r:peek(2) ~= "BM" then + return 0 + end + local n = r:peekU8(14) + math.max(r:peekU8(15), 0) * 256 + if r:peekU8(16) == 0 and r:peekU8(17) == 0 and (n == 12 or n == 16 or n == 40 or n == 52 or n == 56 or n == 64 or n == 108 or n == 124) then + return 0.9 + end + return 0.2 +end +end + +do -- image/dds +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +local MAGIC = "DDS " +S["image/dds"] = function(r: Bytes.Reader): number + return math.max(Sniff.magic(r, MAGIC .. "\124\0\0\0"), Sniff.magic(r, MAGIC, 0, 0.6)) +end +end + +do -- image/exr +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +local MAGIC = "\118\47\49\1" +S["image/exr"] = function(r: Bytes.Reader): number + return Sniff.magic(r, MAGIC) +end +end + +do -- image/gif +local Bytes = require("@rosetta/core/Bytes") +S["image/gif"] = function(r: Bytes.Reader): number + local s = r:peek(6) + return if s == "GIF89a" or s == "GIF87a" then 1 else 0 +end +end + +do -- image/hdr +local Bytes = require("@rosetta/core/Bytes") +S["image/hdr"] = function(r: Bytes.Reader): number + local s = r:peek(10) + if s == "#?RADIANCE" then + return 1 + end + if string.sub(s, 1, 6) == "#?RGBE" then + return 1 + end + if string.sub(s, 1, 2) == "#?" and string.match(s, "^#%?%u") then + return 0.5 + end + return 0 +end +end + +do -- image/icns +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["image/icns"] = function(r: Bytes.Reader): number + return Sniff.magic(r, "icns") +end +end + +do -- image/ico +local Bytes = require("@rosetta/core/Bytes") +local readu8 = buffer.readu8 +S["image/ico"] = function(r: Bytes.Reader): number + if r:remaining() < 22 then + return 0 + end + local b, o = r.buf, r.pos + local typ = buffer.readu16(b, o + 2) + local count = buffer.readu16(b, o + 4) + if buffer.readu16(b, o) ~= 0 or (typ ~= 1 and typ ~= 2) or count == 0 then + return 0 + end + -- the first entry: reserved byte 0, a size and offset inside the file + local size, off = buffer.readu32(b, o + 14), buffer.readu32(b, o + 18) + if readu8(b, o + 9) ~= 0 or size == 0 or off < 6 + count * 16 then + return 0 + end + return 0.8 +end +end + +do -- image/ilbm +local Bytes = require("@rosetta/core/Bytes") +S["image/ilbm"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "FORM" then + return 0 + end + local t = r:peek(4, 8) + return if t == "ILBM" or t == "PBM " then 1 else 0 +end +end + +do -- image/jpeg +local Bytes = require("@rosetta/core/Bytes") +S["image/jpeg"] = function(r: Bytes.Reader): number + local s = r:peek(3) + return if s == "\255\216\255" then 1 else 0 +end +end + +do -- image/ktx +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +local ID1 = "\171KTX 11\187\r\n\26\n" +local ID2 = "\171KTX 20\187\r\n\26\n" +S["image/ktx"] = function(r: Bytes.Reader): number + return math.max(Sniff.magic(r, ID2), Sniff.magic(r, ID1)) +end +end + +do -- image/lmp +local Bytes = require("@rosetta/core/Bytes") +local function kindOf(r: Bytes.Reader): string? + local n = r:remaining() + if n == 768 then + return "palette" + elseif n == 16385 or n == 16384 then + return "colormap" + end + if n < 9 then + return nil + end + local w, h = buffer.readu32(r.buf, r.pos), buffer.readu32(r.buf, r.pos + 4) + if w > 0 and h > 0 and w <= 4096 and h <= 4096 and 8 + w * h == n then + return "qpic" + end + return nil +end +S["image/lmp"] = function(r: Bytes.Reader): number + local k = kindOf(r) + return if k == "qpic" then 0.3 elseif k then 0.05 else 0 +end +end + +do -- image/pcx +local Bytes = require("@rosetta/core/Bytes") +S["image/pcx"] = function(r: Bytes.Reader): number + if r:size() < 128 then + return 0 + end + local m, v, e, bpp = r:peekU8(0), r:peekU8(1), r:peekU8(2), r:peekU8(3) + if m ~= 10 or (v ~= 0 and v ~= 2 and v ~= 3 and v ~= 4 and v ~= 5) or e > 1 then + return 0 + end + return if bpp == 1 or bpp == 2 or bpp == 4 or bpp == 8 then 0.8 else 0 +end +end + +do -- image/png +local Bytes = require("@rosetta/core/Bytes") +local SIGNATURE = "\137PNG\r\n\26\n" +S["image/png"] = function(r: Bytes.Reader): number + return if r:peek(8) == SIGNATURE then 1 else 0 +end +end + +do -- image/pnm +local Bytes = require("@rosetta/core/Bytes") +S["image/pnm"] = function(r: Bytes.Reader): number + if r:remaining() < 3 then + return 0 + end + local a, b, c = r:peekU8(0), r:peekU8(1), r:peekU8(2) + if a ~= 80 then -- 'P' + return 0 + end + local ws = c == 32 or (c >= 9 and c <= 13) + if b >= 49 and b <= 55 and ws then -- P1..P7 + return 0.9 + end + if (b == 70 or b == 102) and ws then -- PF / Pf + return 0.9 + end + return 0 +end +end + +do -- image/qoi +local Bytes = require("@rosetta/core/Bytes") +S["image/qoi"] = function(r: Bytes.Reader): number + return if r:peek(4) == "qoif" then 1 else 0 +end +end + +do -- image/sgi +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["image/sgi"] = function(r: Bytes.Reader): number + if Sniff.magic(r, "\1\218") == 0 or r:size() < 512 then + return 0 + end + local st, bpc = r:peekU8(2), r:peekU8(3) + return if st <= 1 and (bpc == 1 or bpc == 2) then 1 else 0 +end +end + +do -- image/spr +local Bytes = require("@rosetta/core/Bytes") +S["image/spr"] = function(r: Bytes.Reader): number + if r:remaining() < 36 or r:peek(4) ~= "IDSP" then + return 0 + end + local v = buffer.readi32(r.buf, r.pos + 4) + return if v == 1 or v == 2 or v == 32 then 1 else 0.3 +end +end + +do -- image/sunras +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +local MAGIC = "\89\166\106\149" +S["image/sunras"] = function(r: Bytes.Reader): number + return Sniff.magic(r, MAGIC) +end +end + +do -- image/tga +local Bytes = require("@rosetta/core/Bytes") +local TYPES = { [1] = true, [2] = true, [3] = true, [9] = true, [10] = true, [11] = true } +local FOOTER = "TRUEVISION-XFILE.\0" +local readu8 = buffer.readu8 +type Header = { + idLen: number, + cmapType: number, + imageType: number, + cmapFirst: number, + cmapLen: number, + cmapBits: number, + width: number, + height: number, + depth: number, + desc: number, +} +local function header(r: Bytes.Reader): Header? + if r.limit - r.base < 18 then + return nil + end + local b, o = r.buf, r.base + local function u16(q: number): number + return readu8(b, o + q) + readu8(b, o + q + 1) * 256 + end + local h: Header = { + idLen = readu8(b, o), + cmapType = readu8(b, o + 1), + imageType = readu8(b, o + 2), + cmapFirst = u16(3), + cmapLen = u16(5), + cmapBits = readu8(b, o + 7), + width = u16(12), + height = u16(14), + depth = readu8(b, o + 16), + desc = readu8(b, o + 17), + } + return h +end +local function implausible(h: Header): string? + local t = h.imageType + if not TYPES[t] then + return "image type " .. t + end + if h.cmapType > 1 then + return "colour map type " .. h.cmapType + end + local mapped = t == 1 or t == 9 + if mapped and (h.cmapType ~= 1 or (h.depth ~= 8 and h.depth ~= 16)) then + return "colour-mapped image without a colour map" + end + if h.cmapType == 1 and h.cmapLen > 0 and h.cmapBits ~= 15 and h.cmapBits ~= 16 and h.cmapBits ~= 24 and h.cmapBits ~= 32 then + return "colour map entry size " .. h.cmapBits + end + if (t == 2 or t == 10) and h.depth ~= 15 and h.depth ~= 16 and h.depth ~= 24 and h.depth ~= 32 then + return "pixel depth " .. h.depth + end + if (t == 3 or t == 11) and h.depth ~= 8 and h.depth ~= 16 then + return "grey pixel depth " .. h.depth + end + if h.width == 0 or h.height == 0 then + return "zero size" + end + if h.desc >= 64 then + return "interleaving / reserved descriptor bits" + end + return nil +end +S["image/tga"] = function(r: Bytes.Reader): number + local h = header(r) + if not h or implausible(h) then + return 0 + end + local n = r.limit - r.base + if n >= 44 and buffer.readstring(r.buf, r.limit - 18, 18) == FOOTER then + return 0.9 + end + return 0.2 +end +end + +do -- image/tiff +local Bytes = require("@rosetta/core/Bytes") +S["image/tiff"] = function(r: Bytes.Reader): number + local s = r:peek(4) + if s == "II*\0" or s == "MM\0*" or s == "II+\0" or s == "MM\0+" then + return 1 + end + return 0 +end +end + +do -- image/tim +local Bytes = require("@rosetta/core/Bytes") +S["image/tim"] = function(r: Bytes.Reader): number + if r:remaining() < 20 or r:peek(4) ~= "\16\0\0\0" then + return 0 + end + local flags = r:peekU8(4) + if flags > 0x0F or (flags % 8) > 3 or r:peek(3, 5) ~= "\0\0\0" then + return 0 + end + return 0.8 +end +end + +do -- image/vtf +local Bytes = require("@rosetta/core/Bytes") +S["image/vtf"] = function(r: Bytes.Reader): number + return if r:peek(4) == "VTF\0" and r:peekU8(4) == 7 then 1 else 0 +end +end + +do -- image/webp +local Bytes = require("@rosetta/core/Bytes") +S["image/webp"] = function(r: Bytes.Reader): number + if r:peek(4) == "RIFF" and r:peek(4, 8) == "WEBP" then + return 1 + end + return 0 +end +end + +do -- image/xbm +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["image/xbm"] = function(r: Bytes.Reader): number + local s = Sniff.text(r, 256, true) + if string.match(s, "^#define%s+[%w_]*_?width%s+%d+") or string.match(s, "^/%*.-%*/%s*#define%s+[%w_]*width%s+%d+") then + return 0.9 + end + return 0 +end +end + +do -- image/xpm +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["image/xpm"] = function(r: Bytes.Reader): number + local s = Sniff.text(r, 64, true) + if string.sub(s, 1, 9) == "/* XPM */" or string.sub(s, 1, 6) == "! XPM2" then + return 1 + end + return 0 +end +end + +do -- audio/aac +local Bytes = require("@rosetta/core/Bytes") +local Aac = lazy(function() + return require("@rosetta/codecs/audio/Aac") +end) +local readu8 = buffer.readu8 +local function id3Size(b: buffer, p: number, limit: number): number + if p + 10 > limit or buffer.readstring(b, p, 3) ~= "ID3" then + return 0 + end + local s = 0 + for i = 6, 9 do + s = s * 128 + bit32.band(readu8(b, p + i), 127) + end + local footer = if bit32.band(readu8(b, p + 5), 0x10) ~= 0 then 10 else 0 + return 10 + s + footer +end +S["audio/aac"] = function(r: Bytes.Reader): number + local b, p, limit = r.buf, r.pos, r.limit + p += id3Size(b, p, limit) + local h = Aac.adts(b, p, limit) + if not h then + return 0 + end + local h2 = Aac.adts(b, p + h.frameSize, limit) + if h2 and h2.sfIndex == h.sfIndex and h2.channelConfig == h.channelConfig then + return 0.9 + end + return if p + h.frameSize >= limit then 0.7 else 0.4 +end +end + +do -- audio/ac3 +local Bytes = require("@rosetta/core/Bytes") +local Ac3 = lazy(function() + return require("@rosetta/codecs/audio/Ac3") +end) +S["audio/ac3"] = function(r: Bytes.Reader): number + local b, p, limit = r.buf, r.pos, r.limit + local h = Ac3.header(b, p, limit) + if not h then + return 0 + end + local h2 = Ac3.header(b, p + h.frameSize, limit) + if h2 and h2.sampleRate == h.sampleRate then + return 0.9 + end + return if p + h.frameSize >= limit then 0.6 else 0.3 +end +end + +do -- audio/adpcm +local Bytes = require("@rosetta/core/Bytes") +S["audio/adpcm"] = function(_r: Bytes.Reader): number + return 0 +end +end + +do -- audio/adx +local Bytes = require("@rosetta/core/Bytes") +S["audio/adx"] = function(r: Bytes.Reader): number + if r:peekU8(0) ~= 0x80 or r:peekU8(1) ~= 0 then + return 0 + end + local off = r:peekU8(2) * 256 + r:peekU8(3) + return if r:peek(6, off - 2) == "(c)CRI" then 1 else 0 +end +end + +do -- audio/aiff +local Bytes = require("@rosetta/core/Bytes") +S["audio/aiff"] = function(r: Bytes.Reader): number + if r:remaining() < 12 or r:peek(4) ~= "FORM" then + return 0 + end + local form = buffer.readstring(r.buf, r.pos + 8, 4) + return if form == "AIFF" or form == "AIFC" then 1 else 0 +end +end + +do -- audio/ape +local Bytes = require("@rosetta/core/Bytes") +S["audio/ape"] = function(r: Bytes.Reader): number + local head = r:peek(4) + if head == "MAC " or head == "MACF" then -- MACF: float samples + return 1 + end + if string.sub(head, 1, 3) == "ID3" then + local sz = 0 + for i = 6, 9 do + local v = r:peekU8(i) + if v < 0 then + return 0 + end + sz = sz * 128 + bit32.band(v, 127) + end + local footer = bit32.band(math.max(r:peekU8(5), 0), 0x10) ~= 0 + local id = r:peek(4, 10 + sz + (if footer then 10 else 0)) + return if id == "MAC " or id == "MACF" then 1 else 0 + end + return 0 +end +end + +do -- audio/au +local Bytes = require("@rosetta/core/Bytes") +S["audio/au"] = function(r: Bytes.Reader): number + return if r:peek(4) == ".snd" then 1 else 0 +end +end + +do -- audio/brstm +local Bytes = require("@rosetta/core/Bytes") +S["audio/brstm"] = function(r: Bytes.Reader): number + local m = r:peek(4) + if m ~= "RSTM" and m ~= "CSTM" and m ~= "FSTM" then + return 0 + end + local bom = r:peek(2, 4) + return if bom == "\254\255" or bom == "\255\254" then 1 else 0 +end +end + +do -- audio/caf +local Bytes = require("@rosetta/core/Bytes") +S["audio/caf"] = function(r: Bytes.Reader): number + local h = r:peek(8) + if #h == 8 and string.sub(h, 1, 4) == "caff" and string.byte(h, 5) == 0 and string.byte(h, 6) == 1 then + return 1 + end + return 0 +end +end + +do -- audio/flac +local Bytes = require("@rosetta/core/Bytes") +S["audio/flac"] = function(r: Bytes.Reader): number + local head = r:peek(4) + if head == "fLaC" then + return 1 + end + if head == "OggS" then + -- the first page's packet: 0x7F "FLAC" (the Ogg FLAC mapping) + local nseg = r:peekU8(26) + if nseg > 0 and r:peek(5, 27 + nseg) == "\127FLAC" then + return 1 + end + return 0 + end + if string.sub(head, 1, 3) == "ID3" then + -- an ID3v2 tag, then fLaC (mp3 files start with ID3 too) + local sz = 0 + for i = 6, 9 do + local v = r:peekU8(i) + if v < 0 then + return 0 + end + sz = sz * 128 + bit32.band(v, 127) + end + local footer = bit32.band(math.max(r:peekU8(5), 0), 0x10) ~= 0 + return if r:peek(4, 10 + sz + (if footer then 10 else 0)) == "fLaC" then 1 else 0 + end + return 0 +end +end + +do -- audio/m4a +local Bytes = require("@rosetta/core/Bytes") +local IsoBmff = lazy(function() + return require("@rosetta/containers/IsoBmff") +end) +local AUDIO_BRANDS: { [string]: number } = { ["M4A "] = 1, ["M4B "] = 1, ["M4P "] = 1, ["M4V "] = 0.3 } +S["audio/m4a"] = function(r: Bytes.Reader): number + local brand = IsoBmff.sniff(r) + if brand == nil then + return 0 + end + if AUDIO_BRANDS[brand] then + return AUDIO_BRANDS[brand] + end + if brand == "avif" or brand == "avis" or brand == "heic" or brand == "heix" or brand == "mif1" or brand == "msf1" or brand == "crx " then + return 0 + end + return 0.4 -- an MP4 / MOV that may hold audio; a video format claims it more strongly +end +end + +do -- audio/mp3 +local Bytes = require("@rosetta/core/Bytes") +local Header = lazy(function() + return require("@rosetta/codecs/audio/Mpa/Header") +end) +local Tags = lazy(function() + return require("@rosetta/audio/mp3/Tags") +end) +S["audio/mp3"] = function(r: Bytes.Reader): number + local b, p, lim = r.buf, r.pos, r.limit + local id3 = false + for _ = 1, 4 do -- (ffmpeg writes a tag even when the input had one: tags can follow each other) + local n = if p + 3 <= lim and buffer.readstring(b, p, 3) == "ID3" then Tags.id3v2Size(b, p, lim) else 0 + if n <= 0 then + break + end + id3 = true + p += n + end + if p + 4 > lim or not Header.valid(b, p) then + return if id3 then 0.5 else 0 + end + local fb = Header.frameBytes(b, p, 0) + if fb > 0 then + fb += Header.padding(b, p) + if p + fb + 4 <= lim and Header.compare(b, p, p + fb) then + return 0.9 + end + if p + fb == lim then + return 0.6 + end + end + return if id3 then 0.7 else 0.25 +end +end + +do -- audio/mpc +local Bytes = require("@rosetta/core/Bytes") +local Musepack = lazy(function() + return require("@rosetta/codecs/audio/Musepack") +end) +local function id3v2(b: buffer, p: number, limit: number): number + if p + 10 > limit or buffer.readstring(b, p, 3) ~= "ID3" then + return 0 + end + local n = 10 + for i = 6, 9 do + n += bit32.band(buffer.readu8(b, p + i), 127) * 128 ^ (9 - i) + end + return n + (if bit32.band(buffer.readu8(b, p + 5), 0x10) ~= 0 then 10 else 0) +end +S["audio/mpc"] = function(r: Bytes.Reader): number + local b, p, limit = r.buf, r.pos, r.limit + p += id3v2(b, p, limit) + local v = Musepack.magic(b, p, limit) + if v == 8 then + return 1 + end + return if v == 7 then 0.9 else 0 +end +end + +do -- audio/opus +local Bytes = require("@rosetta/core/Bytes") +S["audio/opus"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "OggS" then + return 0 + end + local nseg = r:peekU8(26) + if nseg < 1 then + return 0 + end + return if r:peek(8, 27 + nseg) == "OpusHead" then 1 else 0 +end +end + +do -- audio/qoa +local Bytes = require("@rosetta/core/Bytes") +S["audio/qoa"] = function(r: Bytes.Reader): number + return if r:peek(4) == "qoaf" then 1 else 0 +end +end + +do -- audio/tta +local Bytes = require("@rosetta/core/Bytes") +local function id3Size(r: Bytes.Reader): number + if r:peek(3) ~= "ID3" then + return 0 + end + local sz = 0 + for i = 6, 9 do + local v = r:peekU8(i) + if v < 0 then + return 0 + end + sz = sz * 128 + bit32.band(v, 127) + end + local footer = bit32.band(math.max(r:peekU8(5), 0), 0x10) ~= 0 + return 10 + sz + (if footer then 10 else 0) +end +S["audio/tta"] = function(r: Bytes.Reader): number + return if r:peek(4, id3Size(r)) == "TTA1" then 1 else 0 +end +end + +do -- audio/vag +local Bytes = require("@rosetta/core/Bytes") +S["audio/vag"] = function(r: Bytes.Reader): number + local m = r:peek(4) + return if m == "VAGp" or m == "VAGi" or m == "KVAG" then 1 else 0 +end +end + +do -- audio/voc +local Bytes = require("@rosetta/core/Bytes") +local MAGIC = "Creative Voice File\26" +S["audio/voc"] = function(r: Bytes.Reader): number + return if r:peek(20) == MAGIC then 1 else 0 +end +end + +do -- audio/vorbis +local Bytes = require("@rosetta/core/Bytes") +S["audio/vorbis"] = function(r: Bytes.Reader): number + if r:remaining() < 35 or r:peek(4) ~= "OggS" then + return 0 + end + local b, p = r.buf, r.pos + local nseg = buffer.readu8(b, p + 26) + local d = p + 27 + nseg + if d + 7 > r.limit then + return 0 + end + return if buffer.readu8(b, d) == 1 and buffer.readstring(b, d + 1, 6) == "vorbis" then 1 else 0 +end +end + +do -- audio/wav +local Bytes = require("@rosetta/core/Bytes") +local Riff = lazy(function() + return require("@rosetta/containers/Riff") +end) +S["audio/wav"] = function(r: Bytes.Reader): number + return if Riff.sniff(r) == "WAVE" then 1 else 0 +end +end + +do -- audio/wavpack +local Bytes = require("@rosetta/core/Bytes") +S["audio/wavpack"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "wvpk" then + return 0 + end + local v = r:peekU8(9) + return if v == 4 then 1 else 0.5 +end +end + +do -- video/avi +local Bytes = require("@rosetta/core/Bytes") +S["video/avi"] = function(r: Bytes.Reader): number + if r:peek(4) == "RIFF" and r:peek(4, 8) == "AVI " then + return 1 + end + return 0 +end +end + +do -- video/fli +local Bytes = require("@rosetta/core/Bytes") +local FLI, FLC, DTA = 0xAF11, 0xAF12, 0xAF44 +S["video/fli"] = function(r: Bytes.Reader): number + local s = r:peek(18) + if #s < 18 then + return 0 + end + local magic = string.byte(s, 5) + string.byte(s, 6) * 256 + if magic ~= FLI and magic ~= FLC and magic ~= DTA then + return 0 + end + local w = string.byte(s, 9) + string.byte(s, 10) * 256 + local h = string.byte(s, 11) + string.byte(s, 12) * 256 + if w > 4096 or h > 4096 then + return 0 + end + return 0.9 +end +end + +do -- video/flv +local Bytes = require("@rosetta/core/Bytes") +S["video/flv"] = function(r: Bytes.Reader): number + if r:remaining() >= 9 and r:peek(3) == "FLV" then + return if r:peekU8(3) == 1 then 1 else 0.6 + end + return 0 +end +end + +do -- video/h264 +local Bytes = require("@rosetta/core/Bytes") +S["video/h264"] = function(r: Bytes.Reader): number + local s = r:peek(5) + if not s or #s < 4 then + return 0 + end + local hdr + if string.byte(s, 1) == 0 and string.byte(s, 2) == 0 and string.byte(s, 3) == 1 then + hdr = string.byte(s, 4) + elseif #s >= 5 and string.byte(s, 1) == 0 and string.byte(s, 2) == 0 and string.byte(s, 3) == 0 and string.byte(s, 4) == 1 then + hdr = string.byte(s, 5) + else + return 0 + end + if hdr >= 128 then + return 0 + end + local t = hdr % 32 + if t == 7 then + return 0.8 + elseif t == 9 or t == 6 or t == 8 then + return 0.5 + elseif t == 5 then + return 0.4 + end + return 0 +end +end + +do -- video/mkv +local Bytes = require("@rosetta/core/Bytes") +S["video/mkv"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "\26\69\223\163" then + return 0 + end + local head = r:peek(math.min(64, r:remaining())) + if string.find(head, "webm", 1, true) or string.find(head, "matroska", 1, true) then + return 1 + end + return 0.5 +end +end + +do -- video/mp4 +local Bytes = require("@rosetta/core/Bytes") +local IsoBmff = lazy(function() + return require("@rosetta/containers/IsoBmff") +end) +local IMAGE_BRANDS = { avif = true, avis = true, heic = true, heix = true, mif1 = true, msf1 = true, ["crx "] = true } +local AUDIO_BRANDS = { ["M4A "] = true, ["M4B "] = true, ["M4P "] = true } +S["video/mp4"] = function(r: Bytes.Reader): number + local brand = IsoBmff.sniff(r) + if brand == nil or IMAGE_BRANDS[brand] then + return 0 + end + if AUDIO_BRANDS[brand] then + return 0.2 + end + if brand == "M4V " then + return 0.9 + end + return if brand == "" then 0.6 else 0.8 +end +end + +do -- video/mpegps +local Bytes = require("@rosetta/core/Bytes") +S["video/mpegps"] = function(r: Bytes.Reader): number + if r:peek(4) == "\0\0\1\186" then + return 0.9 + end + if r:peek(4) == "\0\0\1\179" then + return 0.5 -- an MPEG-1 / 2 video elementary stream (sequence header) + end + return 0 +end +end + +do -- video/mpegts +local Bytes = require("@rosetta/core/Bytes") +local SIZES = { 188, 192 } +local function packetSize(r: Bytes.Reader): (number, number) + local n = r:remaining() + local head = r:peek(2048 + 2 * 192) + local lim = math.min(n, 2048) + local start = 0 + while start < lim do + local f = string.find(head, "G", start + 1, true) -- 0x47 + if not f or f > lim then + break + end + start = f - 1 + for _, size in SIZES do + local hits, need = 0, math.min(3, (n - start - 1) // size + 1) + for k = 0, 2 do + local at = start + k * size + if at < n and string.byte(head, at + 1) == 0x47 then + hits += 1 + end + end + if hits >= need and (need >= 2 or start == 0) then + if size == 192 and start >= 4 then + return 192, start - 4 + elseif size == 188 then + return 188, start + end + end + end + start += 1 + end + return 0, 0 +end +S["video/mpegts"] = function(r: Bytes.Reader): number + local s, off = packetSize(r) + if s == 0 then + return 0 + end + if off > 0 then + return 0.6 + end + return if r:remaining() >= 3 * s then 0.9 else 0.5 +end +end + +do -- video/ogv +local Bytes = require("@rosetta/core/Bytes") +S["video/ogv"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "OggS" then + return 0 + end + local b, p, lim = r.buf, r.pos, r.limit + for _ = 1, 8 do + if p + 27 > lim or buffer.readstring(b, p, 4) ~= "OggS" or buffer.readu8(b, p + 5) % 4 < 2 then + return 0 + end + local nseg = buffer.readu8(b, p + 26) + local d = p + 27 + nseg + if d + 7 <= lim and buffer.readu8(b, d) == 0x80 and buffer.readstring(b, d + 1, 6) == "theora" then + return 1 + end + if d > lim then + return 0 + end + local size = 0 + for i = 0, nseg - 1 do + size += buffer.readu8(b, p + 27 + i) + end + p = d + size + end + return 0 +end +end + +do -- video/smk +local Bytes = require("@rosetta/core/Bytes") +S["video/smk"] = function(r: Bytes.Reader): number + local s = r:peek(4) + if s ~= "SMK2" and s ~= "SMK4" then + return 0 + end + return 1 +end +end + +do -- video/y4m +local Bytes = require("@rosetta/core/Bytes") +local MAGIC = "YUV4MPEG2 " +S["video/y4m"] = function(r: Bytes.Reader): number + return if r:peek(10) == MAGIC then 1 else 0 +end +end + +do -- model/3ds +local Bytes = require("@rosetta/core/Bytes") +S["model/3ds"] = function(r: Bytes.Reader): number + local h = r:peek(8) + if #h < 8 or string.byte(h, 1) ~= 0x4D or string.byte(h, 2) ~= 0x4D then + return 0 + end + local b1, b2, b3, b4, c1, c2 = string.byte(h, 3, 8) + local size = b1 + b2 * 256 + b3 * 65536 + b4 * 16777216 + local child = c1 + c2 * 256 + if size < 16 or not (child == 0x0002 or child == 0x3D3D or child == 0xB000) then + return 0 + end + return if size == r.limit - r.pos then 0.95 else 0.7 +end +end + +do -- model/3mf +local Bytes = require("@rosetta/core/Bytes") +S["model/3mf"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "PK\3\4" then + return 0 + end + local n = r:size() + local tail = buffer.readstring(r.buf, r.base + math.max(0, n - 65536), math.min(n, 65536)) + if string.find(tail, "3D/[^/]*%.model") or string.find(tail, "3dmodel.model", 1, true) then + return 0.95 + end + local head = r:peek(256) + if string.find(head, "3D/", 1, true) then + return 0.7 + end + return 0 +end +end + +do -- model/ase +local Bytes = require("@rosetta/core/Bytes") +local Text = lazy(function() + return require("@rosetta/codecs/text/Text") +end) +local MAGIC = "*3DSMAX_ASCIIEXPORT" +local function utf16(r: Bytes.Reader): (boolean?, boolean) + local h = r:peek(2) + if h == "\255\254" then + return true, false + elseif h == "\254\255" then + return true, true + elseif #h == 2 and string.byte(h, 2) == 0 and string.byte(h, 1) == 42 then + return true, false + elseif #h == 2 and string.byte(h, 1) == 0 and string.byte(h, 2) == 42 then + return true, true + end + return nil, false +end +local function text(r: Bytes.Reader, n: number?): string + local wide, be = utf16(r) + local len = r.limit - r.pos + if n then + len = math.min(len, n) + end + if wide then + local skip = if r:peek(2) == "\255\254" or r:peek(2) == "\254\255" then 2 else 0 + return Text.utf16(r.buf, r.pos + skip, len - skip, be) + end + return Text.toUtf8(buffer.readstring(r.buf, r.pos, len)) +end +S["model/ase"] = function(r: Bytes.Reader): number + local h = string.match(text(r, 256), "^%s*(%*[%w_]+)") + if h == MAGIC then + return 1 + end + return 0 +end +end + +do -- model/b3d +local Bytes = require("@rosetta/core/Bytes") +S["model/b3d"] = function(r: Bytes.Reader): number + if r:peek(4) == "BB3D" then + return if r:peek(4, 8) ~= "" then 1 else 0.8 + end + return 0 +end +end + +do -- model/blend +local Bytes = require("@rosetta/core/Bytes") +local Deflate = lazy(function() + return require("@rosetta/codecs/compress/Deflate") +end) +local Zstd = lazy(function() + return require("@rosetta/codecs/compress/Zstd") +end) +S["model/blend"] = function(r: Bytes.Reader): number + local head = r:peek(7) + if head == "BLENDER" then + return 1 + end + local n = r.limit - r.base + if string.sub(head, 1, 3) == "\31\139\8" then + local inner = Deflate.peek(r.buf, r.base, n, 7) + return if inner and buffer.tostring(inner) == "BLENDER" then 1 else 0 + end + if string.sub(head, 1, 4) == Zstd.MAGIC then + if n > 4 * 2 ^ 20 then + return 0.5 + end + local out = Zstd.decompress(r.buf, r.base, n, { verify = false }) + return if out and buffer.len(out) >= 7 and buffer.readstring(out, 0, 7) == "BLENDER" then 1 else 0 + end + return 0 +end +end + +do -- model/bsp +local Bytes = require("@rosetta/core/Bytes") +S["model/bsp"] = function(r: Bytes.Reader): number + if r:remaining() < 64 then + return 0 + end + local m = r:peek(4) + local v = buffer.readi32(r.buf, r.pos + (if m == "IBSP" then 4 else 0)) + if m == "BSP2" or m == "2PSB" then + v = 29 + end + if m == "IBSP" then + return if v == 38 or v == 46 or v == 47 then 1 else 0.3 + end + if v == 29 or v == 30 then + local size = r:remaining() + for i = 0, 14 do + local o, n = buffer.readi32(r.buf, r.pos + 4 + i * 8), buffer.readi32(r.buf, r.pos + 8 + i * 8) + if o < 0 or n < 0 or o + n > size then + return 0 + end + end + return 0.6 + end + return 0 +end +end + +do -- model/buildmap +local Bytes = require("@rosetta/core/Bytes") +local SECTOR_SIZE, WALL_SIZE, SPRITE_SIZE = 40, 32, 44 +local HEADER = 22 -- version, posx, posy, posz, ang, cursectnum, then u16 numsectors at 20 +local readu16 = buffer.readu16 +local function layout(b: buffer, o: number, limit: number): (number?, number?, number?, number?) + if limit - o < HEADER then + return nil, nil, nil, nil + end + local ns = readu16(b, o + 20) + local p = o + HEADER + ns * SECTOR_SIZE + if p + 2 > limit then + return nil, nil, nil, nil + end + local nw = readu16(b, p) + p += 2 + nw * WALL_SIZE + if p + 2 > limit then + return nil, nil, nil, nil + end + local nsp = readu16(b, p) + p += 2 + nsp * SPRITE_SIZE + return ns, nw, nsp, p +end +S["model/buildmap"] = function(r: Bytes.Reader): number + local b, o, limit = r.buf, r.base, r.limit + if limit - o < HEADER then + return 0 + end + local v = buffer.readu32(b, o) + if v ~= 7 and v ~= 8 and v ~= 9 then + return 0 + end + local ns, _, _, stop = layout(b, o, limit) + if not ns or not stop or stop > limit then + return 0 + end + return if stop == limit then 0.9 else 0.5 +end +end + +do -- model/d3map +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["model/d3map"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 512, true) + for _ = 1, 16 do + local rest = string.match(head, "^//[^\n]*\n%s*(.*)$") + if not rest then + break + end + head = rest + end + return if string.match(head, "^Version%s+[123]%s") then 1 else 0 +end +end + +do -- model/dae +local Bytes = require("@rosetta/core/Bytes") +S["model/dae"] = function(r: Bytes.Reader): number + local head = r:peek(2048) + if string.sub(head, 1, 4) == "PK\3\4" then + local nlen = string.byte(head, 27) or 0 + local name = string.lower(string.sub(head, 31, 30 + nlen)) + if string.find(name, "%.dae$") or name == "manifest.xml" then + return 0.95 + end + return 0 + end + -- UTF-16 files: drop the zero bytes + if string.find(string.sub(head, 1, 4), "\0", 1, true) then + head = string.gsub(head, "%z", "") + end + if string.find(head, " sectors then + return 0 + end + used += 1 + if used == 1 then + local p = r.base + off * 4096 + if p + 5 > r.limit then + return 0 + end + local c = buffer.readu8(b, p + 4) % 128 + if COMPRESSION[c] == nil then + return 0 + end + end + end + end + return if used > 0 then 0.8 else 0.2 +end +end + +do -- model/md2 +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["model/md2"] = function(r: Bytes.Reader): number + if r:remaining() < 68 then + return 0 + end + return if Sniff.magic(r, "IDP2") == 1 and r:peekU8(4) == 8 then 1 else 0 +end +end + +do -- model/md3 +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["model/md3"] = function(r: Bytes.Reader): number + if r:remaining() < 108 then + return 0 + end + return if Sniff.magic(r, "IDP3") == 1 and r:peekU8(4) == 15 then 1 else 0 +end +end + +do -- model/md5 +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["model/md5"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 512, true) + head = string.gsub(head, "^//[^\n]*\n%s*", "") + return if string.match(head, "^MD5Version%s+%d+") then 1 else 0 +end +end + +do -- model/mdl +local Bytes = require("@rosetta/core/Bytes") +S["model/mdl"] = function(r: Bytes.Reader): number + local m = r:peek(4) + local v = r:peekU8(4) + if (m == "IDPO" and v == 6) or (m == "IDST" and v == 10) then + return 1 + end + return 0 +end +end + +do -- model/ms3d +local Bytes = require("@rosetta/core/Bytes") +local Read = lazy(function() + return require("@rosetta/model/ms3d/Read") +end) +S["model/ms3d"] = function(r: Bytes.Reader): number + local h = r:peek(14) + if string.sub(h, 1, 10) ~= Read.MAGIC then + return 0 + end + local v = string.byte(h, 11) + return if v == 3 or v == 4 then 1 else 0.6 +end +end + +do -- model/obj +local Bytes = require("@rosetta/core/Bytes") +S["model/obj"] = function(r: Bytes.Reader): number + local head = r:peek(512) + if string.find(head, "\0", 1, true) then + return 0 + end + if string.find(head, "^%s*v%s+[%-%d%.]") or string.find(head, "\n%s*v%s+[%-%d%.]") then + return 0.6 + end + if string.find(head, "^#") and (string.find(head, "\nmtllib ") or string.find(head, "\no ") or string.find(head, "\ng ")) then + return 0.4 + end + return 0 +end +end + +do -- model/off +local Bytes = require("@rosetta/core/Bytes") +S["model/off"] = function(r: Bytes.Reader): number + local head = r:peek(512) + for _ = 1, 16 do + local rest = string.match(head, "^%s*#[^\n]*\n(.*)$") + if not rest then + break + end + head = rest + end + local kw = string.match(head, "^%s*(%w+)") + if kw and string.match(kw, "^S?T?C?N?4?n?OFF$") then + return 0.9 + end + return 0 +end +end + +do -- model/ply +local Bytes = require("@rosetta/core/Bytes") +S["model/ply"] = function(r: Bytes.Reader): number + local h = r:peek(4) + return if h == "ply\n" or h == "ply\r" then 1 else 0 +end +end + +do -- model/pmx +local Bytes = require("@rosetta/core/Bytes") +S["model/pmx"] = function(r: Bytes.Reader): number + local head = r:peek(8) + if string.sub(head, 1, 4) == "PMX " then + return 1 + end + if string.sub(head, 1, 7) == "Pmd\0\0\128\63" then + return 1 + end + return 0 +end +end + +do -- model/proc +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["model/proc"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 64, true) + if string.match(head, "^mapProcFile%d%d%d") then + return 1 + end + if string.match(head, '^"?PROC"?%s+"?%d') then + return 0.9 + end + return 0 +end +end + +do -- model/qb +local Bytes = require("@rosetta/core/Bytes") +S["model/qb"] = function(r: Bytes.Reader): number + if r:remaining() < 24 or r:peek(4) ~= "\1\1\0\0" then + return 0 + end + local b, p = r.buf, r.pos + local fmt, z, comp, mask = buffer.readu32(b, p + 4), buffer.readu32(b, p + 8), buffer.readu32(b, p + 12), buffer.readu32(b, p + 16) + if fmt > 1 or z > 1 or comp > 1 or mask > 1 then + return 0 + end + return 0.9 +end +end + +do -- model/rbxm +local Bytes = require("@rosetta/core/Bytes") +local MAGIC = "]*%?>", "") + if match(head, "^%s*]") then + return if find(head, "version=", 1, true) then 1 else 0.8 + end + return 0 +end +end + +do -- model/robloxmesh +local Bytes = require("@rosetta/core/Bytes") +S["model/robloxmesh"] = function(r: Bytes.Reader): number + return if string.match(r:peek(13), "^version [1-7]%.%d%d[\r\n]") then 1 else 0 +end +end + +do -- model/schematic +local Bytes = require("@rosetta/core/Bytes") +local Nbt = lazy(function() + return require("@rosetta/codecs/text/Nbt") +end) +local LITEMATIC_HINTS = { "Regions", "EnclosingSize", "RegionCount", "TotalVolume", "MinecraftDataVersion" } +local SPONGE_HINTS = { "BlockData", "PaletteMax" } -- v1 / v2 fields (some writers leave the root unnamed) +local function hinted(head: string, hints: { string }): boolean + for _, h in hints do + if string.find(head, string.char(0, #h) .. h, 1, true) then + return true + end + end + return false +end +S["model/schematic"] = function(r: Bytes.Reader): number + local p = Nbt.peek(r.buf, r.base, r.limit - r.base) + if not p or p.rootType ~= "compound" or p.endian ~= "big" then + return 0 + end + if p.name == "Schematic" or (p.firstName == "Schematic" and p.firstType == "compound") then + return 1 + end + local head = buffer.tostring(p.head) + return if hinted(head, LITEMATIC_HINTS) or hinted(head, SPONGE_HINTS) then 1 else 0 +end +end + +do -- model/smd +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["model/smd"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 256, true) + head = string.gsub(head, "^//[^\n]*\n%s*", "") + if string.match(head, "^version%s+1%s") and string.find(head, "nodes", 1, true) then + return 0.9 + end + return 0 +end +end + +do -- model/sourcemdl +local Bytes = require("@rosetta/core/Bytes") +S["model/sourcemdl"] = function(r: Bytes.Reader): number + if r.limit - r.base < 8 or r:peek(4) ~= "IDST" then + return 0 + end + local v = buffer.readi32(r.buf, r.base + 4) + return if v >= 44 and v <= 49 then 1 else 0 +end +end + +do -- model/stl +local Bytes = require("@rosetta/core/Bytes") +local function lower5(s: string): boolean + return string.lower(s) == "solid" +end +S["model/stl"] = function(r: Bytes.Reader): number + local size = r:remaining() + if size >= 84 then + local c = r:peek(4, 80) + local n = string.byte(c, 1) + string.byte(c, 2) * 256 + string.byte(c, 3) * 65536 + string.byte(c, 4) * 16777216 + if 84 + 50 * n == size then + return 0.9 + end + end + local head = r:peek(512) + local s = string.match(head, "^%s*(%a+)") + if s and lower5(s) then + local l = string.lower(head) + return if string.find(l, "facet", 1, true) or string.find(l, "endsolid", 1, true) then 0.9 else 0.5 + end + return 0 +end +end + +do -- model/t3d +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["model/t3d"] = function(r: Bytes.Reader): number + local h = Sniff.text(r, 512) + local first = string.match(h, "^%s*(Begin%s+%a+)") + if first == nil then + return 0 + end + local kind = string.lower(string.match(first, "%a+$") or "") + if kind == "map" or kind == "actor" or kind == "level" or kind == "brush" or kind == "polylist" then + return 0.9 + end + return 0.3 +end +end + +do -- model/udmf +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["model/udmf"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 1024, true) + for _ = 1, 32 do + local rest = string.match(head, "^//[^\n]*\n%s*(.*)$") or string.match(head, "^/%*.-%*/%s*(.*)$") + if not rest then + break + end + head = rest + end + if string.match(head, "^[Nn][Aa][Mm][Ee][Ss][Pp][Aa][Cc][Ee]%s*=%s*\"") then + return 0.9 + end + return 0 +end +end + +do -- model/usda +local Bytes = require("@rosetta/core/Bytes") +local function isUsdz(r: Bytes.Reader): boolean + if r:peek(4) ~= "PK\3\4" then + return false + end + local lo, hi = r:peekU8(26), r:peekU8(27) + if lo < 0 or hi < 0 then + return false + end + local nameLen = lo + hi * 256 + local name = string.lower(r:peek(30 + nameLen)) + name = string.sub(name, 31) + return string.find(name, "%.usd[ac]?$") ~= nil +end +S["model/usda"] = function(r: Bytes.Reader): number + local head = r:peek(8) + if string.sub(head, 1, 5) == "#usda" or string.sub(head, 1, 8) == "\239\187\191#usda" then + return 1 + end + if head == "PXR-USDC" then + return 0.9 -- USDC magic, so the error says it is unsupported + end + if isUsdz(r) then + return 0.95 + end + return 0 +end +end + +do -- model/vbsp +local Bytes = require("@rosetta/core/Bytes") +local HEADER = 8 + 64 * 16 + 4 +S["model/vbsp"] = function(r: Bytes.Reader): number + if r:remaining() < HEADER or r:peek(4) ~= "VBSP" then + return 0 + end + local v = buffer.readi32(r.buf, r.pos + 4) + return if v >= 19 and v <= 21 then 1 else 0.5 +end +end + +do -- model/vmf +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["model/vmf"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 512, true) + if string.find(head, "%z") then + return 0 + end + if string.match(head, "^versioninfo%s*{") or string.match(head, '^"versioninfo"%s*{') then + return 0.9 + end + if string.match(head, "^world%s*{") or string.match(head, "^visgroups%s*{") then + return 0.6 + end + return 0 +end +end + +do -- model/vox +local Bytes = require("@rosetta/core/Bytes") +S["model/vox"] = function(r: Bytes.Reader): number + return if r:peek(4) == "VOX " and r:peek(4, 8) == "MAIN" then 1 elseif r:peek(4) == "VOX " then 0.8 else 0 +end +end + +do -- model/vrml +local Bytes = require("@rosetta/core/Bytes") +S["model/vrml"] = function(r: Bytes.Reader): number + local head = r:peek(16) + if string.sub(head, 1, 3) == "\239\187\191" then + head = string.sub(head, 4) + end + return if string.sub(head, 1, 10) == "#VRML V2.0" then 1 elseif string.sub(head, 1, 6) == "#VRML " then 0.6 else 0 +end +end + +do -- model/x +local Bytes = require("@rosetta/core/Bytes") +local ENCODINGS = { ["txt "] = "text", ["bin "] = "binary", tzip = "text", bzip = "binary" } +S["model/x"] = function(r: Bytes.Reader): number + if r:peek(4) ~= "xof " then + return 0 + end + return if ENCODINGS[r:peek(4, 8)] then 1 else 0.5 +end +end + +do -- model/x3d +local Bytes = require("@rosetta/core/Bytes") +S["model/x3d"] = function(r: Bytes.Reader): number + local head = r:peek(1024) + if string.sub(head, 1, 3) == "\239\187\191" then + head = string.sub(head, 4) + end + if string.sub(head, 1, 5) == "#X3D " then + return 1 + end + if string.sub(head, 1, 4) == "\224\0\0\1" and string.find(head, "x3d", 1, true) then + return 0.9 + end + if string.find(head, "]") or string.find(head, "", 1, true) or (string.find(head, "", 1, true)) then + return if string.find(r:peek(512), "= 64 then + local lfanew = string.byte(h, 61) + string.byte(h, 62) * 256 + string.byte(h, 63) * 65536 + local sig = r:peek(2, lfanew) + return if sig == "NE" then 0.6 elseif sig == "PE" then 0.2 else 0 + end + if isFnt(h) and #h >= 6 then + local size = string.byte(h, 3) + string.byte(h, 4) * 256 + string.byte(h, 5) * 65536 + string.byte(h, 6) * 16777216 + return if size == r:size() then 0.9 elseif size <= r:size() and size > 118 then 0.3 else 0 + end + return 0 +end +end + +do -- font/hershey +local Bytes = require("@rosetta/core/Bytes") +local function header(line: string): (number?, number?) + if #line < 10 then + return nil, nil + end + local id = tonumber((string.gsub(string.sub(line, 1, 5), "^%s+", ""))) + local n = tonumber((string.gsub(string.sub(line, 6, 8), "^%s+", ""))) + if not id or not n or n < 1 or string.find(string.sub(line, 1, 8), "[^%d ]") then + return nil, nil + end + return id, n +end +S["font/hershey"] = function(r: Bytes.Reader): number + local head = r:peek(256) + local line = string.match(head, "^([^\r\n]*)") + local id, n = header(line or "") + if not id or not n then + return 0 + end + local body = string.sub(line :: string, 9) + if string.find(body, "[^ -~]") then + return 0 + end + return if #body == math.min(2 * n, 64) or #body == 2 * n then 0.7 else 0.3 +end +end + +do -- font/pcf +local Bytes = require("@rosetta/core/Bytes") +S["font/pcf"] = function(r: Bytes.Reader): number + return if r:peek(4) == "\1fcp" then 1 else 0 +end +end + +do -- font/psf +local Bytes = require("@rosetta/core/Bytes") +S["font/psf"] = function(r: Bytes.Reader): number + local h = r:peek(4) + if h == "\114\181\74\134" then + return 1 + end + if string.sub(h, 1, 2) == "\54\4" and #h >= 4 and string.byte(h, 3) <= 7 and string.byte(h, 4) > 0 then + return 0.9 + end + return 0 +end +end + +do -- font/ttf +local Bytes = require("@rosetta/core/Bytes") +S["font/ttf"] = function(r: Bytes.Reader): number + local m = r:peek(4) + if m == "\0\1\0\0" or m == "OTTO" or m == "ttcf" or m == "true" then + return 0.9 + end + return 0 +end +end + +do -- font/type1 +local Bytes = require("@rosetta/core/Bytes") +S["font/type1"] = function(r: Bytes.Reader): number + local h = r:peek(64) + if string.sub(h, 1, 2) == "\128\1" then + h = string.sub(h, 7) + end + if string.sub(h, 1, 14) == "%!PS-AdobeFont" or string.sub(h, 1, 10) == "%!FontType" then + return 1 + end + return 0 +end +end + +do -- font/woff +local Bytes = require("@rosetta/core/Bytes") +S["font/woff"] = function(r: Bytes.Reader): number + return if r:peek(4) == "wOFF" then 1 else 0 +end +end + +do -- font/woff2 +local Bytes = require("@rosetta/core/Bytes") +S["font/woff2"] = function(r: Bytes.Reader): number + return if r:peek(4) == "wOF2" then 1 else 0 +end +end + +do -- archive/7z +local Bytes = require("@rosetta/core/Bytes") +local MAGIC = "7z\188\175\39\28" +S["archive/7z"] = function(r: Bytes.Reader): number + return if r:peek(6) == MAGIC then 1 else 0 +end +end + +do -- archive/adf +local Bytes = require("@rosetta/core/Bytes") +local BS = 512 +S["archive/adf"] = function(r: Bytes.Reader): number + local n = r:size() + if n < 4 * BS or n % BS ~= 0 then + return 0 + end + local h = r:peek(4) + if string.sub(h, 1, 3) ~= "DOS" or string.byte(h, 4) > 5 then + return 0 + end + return if n == 901120 or n == 1802240 then 0.95 else 0.6 +end +end + +do -- archive/applesingle +local Bytes = require("@rosetta/core/Bytes") +S["archive/applesingle"] = function(r: Bytes.Reader): number + local h = r:peek(8) + if #h < 8 then + return 0 + end + local magic = string.sub(h, 1, 4) + local ver = string.sub(h, 5, 8) + if (magic == "\0\5\22\0" or magic == "\0\5\22\7") and (ver == "\0\1\0\0" or ver == "\0\2\0\0") then + return 1 + end + return 0 +end +end + +do -- archive/ar +local Bytes = require("@rosetta/core/Bytes") +local MAGIC = "!\n" +S["archive/ar"] = function(r: Bytes.Reader): number + if r:peek(8) == MAGIC then + return if r:peek(13, 68) == "debian-binary" then 1 else 0.9 + end + return if r:peek(8) == "!\n" then 0.5 else 0 +end +end + +do -- archive/arj +local Bytes = require("@rosetta/core/Bytes") +S["archive/arj"] = function(r: Bytes.Reader): number + local h = r:peek(4) + if #h == 4 and string.byte(h, 1) == 0x60 and string.byte(h, 2) == 0xEA then + local size = string.byte(h, 3) + string.byte(h, 4) * 256 + return if size > 0 and size <= 2600 then 0.9 else 0 + end + return 0 +end +end + +do -- archive/binhex +local Bytes = require("@rosetta/core/Bytes") +local BANNER = "(This file must be converted with BinHex" +S["archive/binhex"] = function(r: Bytes.Reader): number + local head = r:peek(2048) + local at = string.find(head, BANNER, 1, true) + if not at then + return 0 + end + return if at == 1 then 1 else 0.8 +end +end + +do -- archive/br +local Err = require("@rosetta/core/Err") +local Bytes = require("@rosetta/core/Bytes") +local Brotli = lazy(function() + return require("@rosetta/codecs/compress/Brotli") +end) +local SNIFF_WHOLE = 262144 -- streams up to this size are decoded whole by sniff +local SNIFF_PREFIX = 65536 +S["archive/br"] = function(r: Bytes.Reader): number + local n = r:remaining() + if n == 0 then + return 0 + end + if n <= SNIFF_WHOLE then + local out, consumed = Brotli.decompress(r.buf, r.pos, n, { maxBytes = 2 ^ 26 }) + if out and consumed == r.limit then + return if buffer.len(out) > 0 then 0.3 else 0.05 + end + return 0 + end + local _, err = Brotli.decompress(r.buf, r.pos, SNIFF_PREFIX, { maxBytes = 2 ^ 22 }) + if err and (err.code == Err.TRUNCATED or err.code == Err.LIMIT) then + return 0.05 + end + return 0 +end +end + +do -- archive/bz2 +local Bytes = require("@rosetta/core/Bytes") +S["archive/bz2"] = function(r: Bytes.Reader): number + local h = r:peek(10) + if #h < 10 or string.sub(h, 1, 3) ~= "BZh" then + return 0 + end + local lv = string.byte(h, 4) + if lv < 0x31 or lv > 0x39 then + return 0 + end + local magic = string.sub(h, 5, 10) + if magic == "\x31\x41\x59\x26\x53\x59" or magic == "\x17\x72\x45\x38\x50\x90" then + return 1 + end + return 0 +end +end + +do -- archive/cab +local Bytes = require("@rosetta/core/Bytes") +S["archive/cab"] = function(r: Bytes.Reader): number + if r:peek(8) == "MSCF\0\0\0\0" then + return 1 + end + return 0 +end +end + +do -- archive/cpio +local Bytes = require("@rosetta/core/Bytes") +S["archive/cpio"] = function(r: Bytes.Reader): number + local m = r:peek(6) + if m == "070701" or m == "070702" or m == "070707" then + return 1 + end + local b2 = r:peek(2) + if (b2 == "\199\113" or b2 == "\113\199") and r:remaining() >= 26 then + return 0.5 + end + return 0 +end +end + +do -- archive/d64 +local Bytes = require("@rosetta/core/Bytes") +type Geometry = { kind: string, tracks: number, offsets: { number }, spt: { number }, dirTrack: number, total: number } +local function geometry(kind: string, tracks: number): Geometry + local offsets, spt = {}, {} + local o = 0 + for t = 1, tracks do + local n + if kind == "d81" then + n = 40 + else + local s = if kind == "d71" and t > 35 then t - 35 else t + n = if s <= 17 then 21 elseif s <= 24 then 19 elseif s <= 30 then 18 else 17 + end + offsets[t], spt[t] = o, n + o += n * 256 + end + return { kind = kind, tracks = tracks, offsets = offsets, spt = spt, dirTrack = if kind == "d81" then 40 else 18, total = o } +end +local function detect(len: number): Geometry? + for _, g in { { "d64", 35 }, { "d64", 40 }, { "d64", 42 }, { "d71", 70 }, { "d81", 80 } } :: { { any } } do + local geo = geometry(g[1] :: string, g[2] :: number) + local sectors = geo.total // 256 + if len == geo.total or (g[1] ~= "d81" and len == geo.total + sectors) then + return geo + end + end + return nil +end +S["archive/d64"] = function(r: Bytes.Reader): number + local geo = detect(r:size()) + if not geo then + return 0 + end + -- the BAM / header sector: dir track link and DOS version byte + local h = r:sub(geo.offsets[geo.dirTrack], 256) + local t, s, v = h:u8(), h:u8(), h:u8() + if geo.kind == "d81" then + return if t == 40 and s == 3 and v == 0x44 then 0.9 else 0.3 + end + return if t == 18 and s == 1 and (v == 0x41 or v == 0) then 0.9 else 0.3 +end +end + +do -- archive/fat +local Bytes = require("@rosetta/core/Bytes") +local Fat = lazy(function() + return require("@rosetta/containers/Fat") +end) +S["archive/fat"] = function(r: Bytes.Reader): number + if r:remaining() < 512 then + return 0 + end + local v = Fat.open(r.buf, r.base + r.pos, r.limit - r.base - r.pos) + if not v then + return 0 + end + return if v.partition then 0.6 else 0.8 +end +end + +do -- archive/grp +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +local MAGIC = "KenSilverman" +S["archive/grp"] = function(r: Bytes.Reader): number + return Sniff.magic(r, MAGIC) +end +end + +do -- archive/gzip +local Bytes = require("@rosetta/core/Bytes") +S["archive/gzip"] = function(r: Bytes.Reader): number + return if r:peek(3) == "\31\139\8" then 1 else 0 +end +end + +do -- archive/iso +local Bytes = require("@rosetta/core/Bytes") +S["archive/iso"] = function(r: Bytes.Reader): number + return if r:peek(5, 16 * 2048 + 1) == "CD001" then 1 else 0 +end +end + +do -- archive/lha +local Bytes = require("@rosetta/core/Bytes") +local METHODS: { [string]: boolean } = { + ["-lh0-"] = true, ["-lz4-"] = true, ["-lhd-"] = true, ["-lh1-"] = true, ["-lh4-"] = true, ["-lh5-"] = true, + ["-lh6-"] = true, ["-lh7-"] = true, ["-lhx-"] = true, ["-lzs-"] = true, ["-lz5-"] = true, ["-lh2-"] = true, + ["-lh3-"] = true, ["-pm0-"] = true, ["-pm1-"] = true, ["-pm2-"] = true, ["-lk7-"] = true, +} +local function isHeader(s: string): boolean + if #s < 22 then + return false + end + local m = string.sub(s, 3, 7) + local level = string.byte(s, 21) + return METHODS[m] == true and level <= 3 +end +S["archive/lha"] = function(r: Bytes.Reader): number + if isHeader(r:peek(22)) then + return 0.95 + end + return 0 +end +end + +do -- archive/lz4 +local Bytes = require("@rosetta/core/Bytes") +S["archive/lz4"] = function(r: Bytes.Reader): number + local m = r:peek(4) + if m == "\4\34\77\24" then + return 1 + elseif m == "\2\33\76\24" then + return 0.9 + elseif #m == 4 and string.byte(m, 1) >= 0x50 and string.byte(m, 1) <= 0x5F and string.sub(m, 2) == "\42\77\24" then + -- a skippable frame (zstd shares the magic): an LZ4 frame after it + local h = r:peek(4, 4) + if #h == 4 then + local n = string.byte(h, 1) + string.byte(h, 2) * 256 + string.byte(h, 3) * 65536 + string.byte(h, 4) * 16777216 + if r:peek(4, 8 + n) == "\4\34\77\24" then + return 1 + end + end + end + return 0 +end +end + +do -- archive/macbinary +local Bytes = require("@rosetta/core/Bytes") +local Crc16 = require("@rosetta/core/Crc16") +local function version(b: buffer, o: number, len: number): string? + if len < 128 then + return nil + end + local u8 = function(i: number): number + return buffer.readu8(b, o + i) + end + if u8(0) ~= 0 or u8(74) ~= 0 then + return nil + end + local nameLen = u8(1) + if nameLen < 1 or nameLen > 63 then + return nil + end + local function be32(i: number): number + return u8(i) * 16777216 + u8(i + 1) * 65536 + u8(i + 2) * 256 + u8(i + 3) + end + local dlen, rlen = be32(83), be32(87) + if dlen > 0x7FFFFFFF or rlen > 0x7FFFFFFF then + return nil + end + local crc = u8(124) * 256 + u8(125) + if crc == Crc16.ccitt(b, o, 124) and (crc ~= 0 or u8(122) >= 129) then + return if buffer.readstring(b, o + 102, 4) == "mBIN" then "III" else "II" + end + if buffer.readstring(b, o + 102, 4) == "mBIN" then + return nil -- III with a bad CRC + end + -- MacBinary I: byte 82 zero, bytes 99..125 zero, the forks within the file + if u8(82) ~= 0 then + return nil + end + for i = 99, 125 do + if u8(i) ~= 0 then + return nil + end + end + local need = 128 + math.ceil(dlen / 128) * 128 + rlen + return if need <= len + 127 then "I" else nil +end +S["archive/macbinary"] = function(r: Bytes.Reader): number + local n = math.min(r:remaining(), 128) + if n < 128 then + return 0 + end + local v = version(r.buf, r.base + r.pos, r.limit - r.base - r.pos) + return if v == "III" then 0.95 elseif v == "II" then 0.8 elseif v == "I" then 0.3 else 0 +end +end + +do -- archive/mpq +local Bytes = require("@rosetta/core/Bytes") +S["archive/mpq"] = function(r: Bytes.Reader): number + local m = r:peek(4) + if m == "MPQ\x1A" or m == "MPQ\x1B" then + return 1 + end + -- a prefixed archive (an installer stub): the header on a 512-byte boundary in the first 64 KB + for at = 512, math.min(65536, r:remaining() - 32), 512 do + if r:peek(4, at) == "MPQ\x1A" then + return 0.6 + end + end + return 0 +end +end + +do -- archive/pak +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["archive/pak"] = function(r: Bytes.Reader): number + if r:remaining() < 12 then + return 0 + end + return math.max(Sniff.magic(r, "PACK", 0, 0.9), Sniff.magic(r, "SPAK", 0, 0.9)) +end +end + +do -- archive/rpm +local Bytes = require("@rosetta/core/Bytes") +local LEAD_MAGIC = "\237\171\238\219" +S["archive/rpm"] = function(r: Bytes.Reader): number + return if r:peek(4) == LEAD_MAGIC then 1 else 0 +end +end + +do -- archive/tar +local Bytes = require("@rosetta/core/Bytes") +local Tar = lazy(function() + return require("@rosetta/containers/Tar") +end) +S["archive/tar"] = function(r: Bytes.Reader): number + if r:remaining() < 512 then + return 0 + end + if not Tar.valid(r.buf, r.pos) then + return 0 + end + return if r:peek(5, 257) == "ustar" then 0.95 else 0.6 +end +end + +do -- archive/unitypackage +local Bytes = require("@rosetta/core/Bytes") +local Deflate = lazy(function() + return require("@rosetta/codecs/compress/Deflate") +end) +local Tar = lazy(function() + return require("@rosetta/containers/Tar") +end) +local function guidOf(name: string): (string?, string?) + local n = string.gsub(name, "^%./", "") + local guid, rest = string.match(n, "^(%x+)/?(.*)$") + if guid and #guid == 32 then + return string.lower(guid), rest + end + return nil, nil +end +S["archive/unitypackage"] = function(r: Bytes.Reader): number + if r:peek(3) ~= "\31\139\8" then + return 0 + end + local head = Deflate.peek(r.buf, r.pos, r.limit - r.pos, 512) + if not head or buffer.len(head) < 512 or not Tar.valid(head, 0) then + return 0 + end + local z = 0 + while z < 100 and buffer.readu8(head, z) ~= 0 do + z += 1 + end + return if guidOf(buffer.readstring(head, 0, z)) then 1 else 0 -- ties with archive/gzip go to the extension +end +end + +do -- archive/uu +local Bytes = require("@rosetta/core/Bytes") +S["archive/uu"] = function(r: Bytes.Reader): number + local head = r:peek(4096) + if string.match(head, "^begin%-base64 [0-7]+ [^\r\n]") or string.match(head, "^begin [0-7]+ [^\r\n]") then + return 0.9 + end + if string.match(head, "\nbegin%-base64 [0-7]+ [^\r\n]") or string.match(head, "\nbegin [0-7][0-7][0-7]+ [^\r\n]") then + return 0.5 + end + return 0 +end +end + +do -- archive/vpk +local Bytes = require("@rosetta/core/Bytes") +S["archive/vpk"] = function(r: Bytes.Reader): number + if r:remaining() < 12 or r:peek(4) ~= "\x34\x12\xAA\x55" then + return 0 + end + local v = r:peekU8(4) + return if v == 1 or v == 2 then 1 else 0.5 +end +end + +do -- archive/vswap +local Bytes = require("@rosetta/core/Bytes") +local readu8, readu16, readi16, writeu32 = buffer.readu8, buffer.readu16, buffer.readi16, buffer.writeu32 +local function header(r: Bytes.Reader): (number?, number, number) + if r:remaining() < 6 then + return nil, 0, 0 + end + local n, ss, so = readu16(r.buf, r.base), readu16(r.buf, r.base + 2), readu16(r.buf, r.base + 4) + if n == 0 or ss > so or so > n or 6 + n * 6 > r:remaining() then + return nil, 0, 0 + end + return n, ss, so +end +S["archive/vswap"] = function(r: Bytes.Reader): number + local n = header(r) + if not n then + return 0 + end + local size = r.limit - r.base + local b = r.buf + local last = 6 + n * 6 + local nonzero = 0 + for i = 0, n - 1 do + local o = buffer.readu32(b, r.base + 6 + i * 4) + local l = readu16(b, r.base + 6 + n * 4 + i * 2) + if o ~= 0 then + if o < last or o + l > size then + return 0 + end + last = o + nonzero += 1 + end + end + return if nonzero > 0 then 0.6 else 0 +end +end + +do -- archive/wad +local Bytes = require("@rosetta/core/Bytes") +S["archive/wad"] = function(r: Bytes.Reader): number + if r:remaining() < 12 then + return 0 + end + local m = r:peek(4) + if m ~= "IWAD" and m ~= "PWAD" then + return 0 + end + return 0.9 +end +end + +do -- archive/wad2 +local Bytes = require("@rosetta/core/Bytes") +S["archive/wad2"] = function(r: Bytes.Reader): number + if r:remaining() < 12 then + return 0 + end + local m = r:peek(4) + return if m == "WAD2" or m == "WAD3" then 0.9 else 0 +end +end + +do -- archive/xz +local Bytes = require("@rosetta/core/Bytes") +local XZ_MAGIC = "\253" .. "7zXZ\0" +local function aloneScore(r: Bytes.Reader): number + local h = r:peek(14) + if #h < 14 then + return 0 + end + local d = string.byte(h, 1) + if d >= 225 or string.byte(h, 14) ~= 0 then + return 0 + end + local dict = string.byte(h, 2) + string.byte(h, 3) * 256 + string.byte(h, 4) * 65536 + string.byte(h, 5) * 16777216 + local okDict = false + for n = 12, 31 do + if dict == 2 ^ n or (n < 31 and dict == 2 ^ n + 2 ^ (n - 1)) then + okDict = true + break + end + end + if not okDict then + return 0 + end + local s = string.sub(h, 6, 13) + if s ~= string.rep("\255", 8) and (string.byte(h, 11) ~= 0 or string.byte(h, 12) ~= 0 or string.byte(h, 13) ~= 0) then + return 0 + end + return if d == 0x5D then 0.4 else 0.2 +end +S["archive/xz"] = function(r: Bytes.Reader): number + if r:peek(6) == XZ_MAGIC then + return 1 + end + return aloneScore(r) +end +end + +do -- archive/yenc +local Bytes = require("@rosetta/core/Bytes") +S["archive/yenc"] = function(r: Bytes.Reader): number + local head = r:peek(4096) + if string.match(head, "^=ybegin ") then + return 0.95 + end + return if string.find(head, "\n=ybegin [^\n]*name=") then 0.6 else 0 +end +end + +do -- archive/z +local Bytes = require("@rosetta/core/Bytes") +S["archive/z"] = function(r: Bytes.Reader): number + if r:peek(2) ~= "\31\157" then + return 0 + end + local f = r:peekU8(2) + return if f >= 0 and bit32.band(f, 0x60) == 0 and bit32.band(f, 0x1F) >= 9 and bit32.band(f, 0x1F) <= 16 then 1 else 0.3 +end +end + +do -- archive/zip +local Bytes = require("@rosetta/core/Bytes") +S["archive/zip"] = function(r: Bytes.Reader): number + local s = r:peek(4) + -- ZIP-based formats (docx, jar, 3mf, ...) score higher in their own sniff + if s == "PK\3\4" or s == "PK\5\6" then + return 0.6 + end + if string.sub(s, 1, 2) == "MZ" then + return 0 -- a self-extractor opens with Zip.decode / opts.format = "zip" + end + return 0 +end +end + +do -- archive/zoo +local Bytes = require("@rosetta/core/Bytes") +local TAG = 0xFDC4A7DC +S["archive/zoo"] = function(r: Bytes.Reader): number + local h = r:peek(24) + if #h < 24 then + return 0 + end + local tag = string.byte(h, 21) + string.byte(h, 22) * 256 + string.byte(h, 23) * 65536 + string.byte(h, 24) * 16777216 + if tag ~= TAG then + return 0 + end + return if string.sub(h, 1, 4) == "ZOO " then 1 else 0.8 +end +end + +do -- archive/zst +local Bytes = require("@rosetta/core/Bytes") +local Zstd = lazy(function() + return require("@rosetta/codecs/compress/Zstd") +end) +S["archive/zst"] = function(r: Bytes.Reader): number + local m = r:peek(4) + if m == Zstd.MAGIC then + return 1 + end + -- a skippable frame (0x184D2A50 .. 0x184D2A5F) is usually followed by a zstd frame + if #m == 4 and string.sub(m, 2, 4) == "\42\77\24" and bit32.band(string.byte(m, 1), 0xF0) == 0x50 then + return 0.5 + end + return 0 +end +end + +do -- data/cbor +local Bytes = require("@rosetta/core/Bytes") +S["data/cbor"] = function(r: Bytes.Reader): number + return if r:peek(3) == "\217\217\247" then 1 else 0 +end +end + +do -- data/csv +local Bytes = require("@rosetta/core/Bytes") +local find, sub, byte, gsub = string.find, string.sub, string.byte, string.gsub +S["data/csv"] = function(r: Bytes.Reader): number + local head = r:peek(1024) + if find(head, "%z") then + return 0 + end + local l1, l2 = string.match(head, "^([^\r\n]*)\r?\n([^\r\n]*)") + if not l1 or l1 == "" then + return 0 + end + for _, d in { ",", "\t", ";" } do + local _, c1 = gsub(l1, d, "") + local _, c2 = gsub(l2 :: string, d, "") + if c1 > 0 and c1 == c2 then + return 0.15 + end + end + return 0 +end +end + +do -- data/ini +local Bytes = require("@rosetta/core/Bytes") +S["data/ini"] = function(r: Bytes.Reader): number + local head = r:peek(512) + if string.find(head, "%z") then + return 0 + end + local first = string.match(head, "^[%s]*([^\r\n]*)") + while first and string.match(first, "^[;#]") do + head = string.match(head, "^[^\n]*\n(.*)$") or "" + first = string.match(head, "^[%s]*([^\r\n]*)") + end + if first and string.match(first, "^%[[^%]]+%]%s*$") then + return 0.2 + end + return 0 +end +end + +do -- data/json +local Sniff = require("@rosetta/core/Sniff") +local Bytes = require("@rosetta/core/Bytes") +S["data/json"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 64) + local first = string.match(head, "^[ \t\r\n]*(.)") + if first == "{" then + local nxt = string.match(head, "^[^{]*{[ \t\r\n]*(.)") + return if nxt == nil or nxt == '"' or nxt == "}" then 0.6 else 0.1 + elseif first == "[" then + -- past any nested '[': a JSON value must start (TOML / INI "[section]" and "[[table]]" do not) + local nxt = string.match(head, "^[ \t\r\n]*[%[ \t\r\n]*(.)") + if nxt == nil or string.find('{"-0123456789tfn]', nxt, 1, true) then + return 0.3 + end + return 0 + end + return 0 +end +end + +do -- data/msgpack +local Bytes = require("@rosetta/core/Bytes") +S["data/msgpack"] = function(_r: Bytes.Reader): number + return 0 -- no magic: by extension or opts.format only +end +end + +do -- data/nbt +local Bytes = require("@rosetta/core/Bytes") +local Nbt = lazy(function() + return require("@rosetta/codecs/text/Nbt") +end) +S["data/nbt"] = function(r: Bytes.Reader): number + local p = Nbt.peek(r.buf, r.base, r.limit - r.base) + if not p or p.rootType ~= "compound" then + return 0 + end + if p.compression ~= "none" then + return if p.firstType then 1 else 0.5 -- gzip wrapped NBT: ties with archive/gzip go to the extension + end + return if p.firstType and p.firstName then 0.6 else 0.2 +end +end + +do -- data/plist +local Bytes = require("@rosetta/core/Bytes") +S["data/plist"] = function(r: Bytes.Reader): number + local head = r:peek(256) + if string.sub(head, 1, 6) == "bplist" then + return 1 + end + if string.find(head, " 0 and good == lines and paths > 0 then 0.5 else 0 +end +end + +do -- data/snbt +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["data/snbt"] = function(r: Bytes.Reader): number + -- SNBT has what JSON never has: unquoted keys, typed numbers (1b, 2.5f), [I; arrays, single-quoted strings + local head = Sniff.text(r, 512, true) + local first = string.sub(head, 1, 1) + if first ~= "{" and first ~= "[" then + return 0 + end + if string.find(head, "[{,]%s*[%a_][%w_%-%.%+]*%s*:") or string.find(head, "%d[bBsSlLfFdD]%s*[,}%]]") + or string.find(head, "%[[BIL]%s*;") or string.find(head, "[:,%[]%s*'") + then + return 0.7 + end + return 0 +end +end + +do -- data/toml +local Bytes = require("@rosetta/core/Bytes") +S["data/toml"] = function(r: Bytes.Reader): number + local head = r:peek(512) + if string.find(head, "%z") then + return 0 + end + for line in string.gmatch(head, "[^\n]+") do + local l = string.match(line, "^[ \t]*(.-)[ \t\r]*$") :: string + if l ~= "" and string.sub(l, 1, 1) ~= "#" then + if string.match(l, "^%[%[?[%w_%-%.\"' ]+%]%]?$") or string.match(l, "^[%w_%-%.\"']+[ \t]*=[ \t]*[\"'%[{%dtf%+%-in]") then + return 0.2 + end + return 0 + end + end + return 0 +end +end + +do -- data/tres +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["data/tres"] = function(r: Bytes.Reader): number + local h = Sniff.text(r, 256) + if string.match(h, "^%s*%[gd_resource[%s%]]") then + return 1 + end + return 0 +end +end + +do -- data/vdf +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +local KeyValues = lazy(function() + return require("@rosetta/codecs/text/KeyValues") +end) +S["data/vdf"] = function(r: Bytes.Reader): number + local n = r:remaining() + if KeyValues.isBinary(r.buf, r.pos, n) then + return 0.3 + end + local head = Sniff.text(r, 256, true) + if string.find(head, "%z") then + return 0 + end + head = string.gsub(head, "^//[^\n]*\n%s*", "") + if string.match(head, '^"[^"\n]+"%s*{') or string.match(head, '^"[^"\n]+"%s*%[[^%]\n]*%]%s*{') then + return 0.6 + end + if string.match(head, "^#base%s") or string.match(head, "^#include%s") then + return 0.5 + end + if string.match(head, '^[%w_]+%s*\n%s*{%s*\n%s*"') then + return 0.3 + end + return 0 +end +end + +do -- data/xml +local Sniff = require("@rosetta/core/Sniff") +local Bytes = require("@rosetta/core/Bytes") +S["data/xml"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 64) + if string.match(head, "^<%?xml[ \t\r\n]") or string.sub(head, 1, 4) == "\255\254<\0" or string.sub(head, 1, 4) == "\254\255\0<" then + return 0.5 + end + if string.match(head, "^[ \t\r\n]*<[%a!]") then + return 0.3 + end + return 0 +end +end + +do -- data/yaml +local Bytes = require("@rosetta/core/Bytes") +S["data/yaml"] = function(r: Bytes.Reader): number + local head = r:peek(256) + if string.find(head, "%z") then + return 0 + end + if string.match(head, "^%%YAML ") then + return 0.9 + end + if string.match(head, "^%-%-%-[ \r\n]") then + return 0.5 + end + local line = string.match(head, "^[ \t\r\n]*([^\r\n]*)") + if line and (string.match(line, "^[%w_%-\"']+[%w_%- \"']*:[ ]") or string.match(line, "^[%w_%-]+:$") or string.match(line, "^%- ")) then + return 0.2 + end + return 0 +end +end + +do -- vector/gamemaps +local Bytes = require("@rosetta/core/Bytes") +local MAGIC = "TED5v1.0" +S["vector/gamemaps"] = function(r: Bytes.Reader): number + if r:peek(8) == MAGIC then + return 1 + end + -- MAPHEAD: the RLEW tag 0xABCD, then 100 offsets (0 / -1 when absent) + if r:remaining() >= 402 and r:remaining() <= 1024 and buffer.readu16(r.buf, r.base) == 0xABCD then + local first = buffer.readi32(r.buf, r.base + 2) + if first > 0 then + return 0.7 + end + end + return 0 +end +end + +do -- vector/ldtk +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["vector/ldtk"] = function(r: Bytes.Reader): number + local h = Sniff.text(r, 1024) + if not string.match(h, "^%s*{") then + return 0 + end + if string.find(h, "\"fileType\"%s*:%s*\"LDtk Project JSON\"") then + return 1 + end + if string.find(h, "\"jsonVersion\"", 1, true) and string.find(h, "\"worldLayout\"", 1, true) then + return 0.8 + end + return 0 +end +end + +do -- vector/ogmo +local Bytes = require("@rosetta/core/Bytes") +local Sniff = require("@rosetta/core/Sniff") +S["vector/ogmo"] = function(r: Bytes.Reader): number + local h = Sniff.text(r, 2048) + if not string.match(h, "^%s*{") or not string.find(h, "\"ogmoVersion\"", 1, true) then + return 0 + end + if string.find(h, "\"layerGridDefaultSize\"", 1, true) or string.find(h, "\"levelPaths\"", 1, true) then + return 1 + end + return 0.9 +end +end + +do -- vector/svg +local Sniff = require("@rosetta/core/Sniff") +local Bytes = require("@rosetta/core/Bytes") +S["vector/svg"] = function(r: Bytes.Reader): number + local h = Sniff.text(r, 4096) + if not string.match(h, "^%s*<") then + return 0 + end + if string.find(h, ":]") or string.find(h, "<%w+:svg[%s>]") then + return 0.95 + end + return 0 +end +end + +do -- vector/tiled +local Sniff = require("@rosetta/core/Sniff") +local Bytes = require("@rosetta/core/Bytes") +local function head(r: Bytes.Reader): string + local h = Sniff.text(r, 1024) + return h +end +S["vector/tiled"] = function(r: Bytes.Reader): number + local h = head(r) + if string.match(h, "^%s*<") then + if string.find(h, "]") or string.find(h, "]") then + return 0.9 + end + return 0 + end + if string.match(h, "^%s*{") then + -- Tiled writes its keys sorted: "type" comes last, so look at the tail too + local n = r:remaining() + local tail = if n > 1024 then r:peek(1024, n - 1024) else "" + for _, part in { h, tail } do + if string.find(part, "\"type\"%s*:%s*\"map\"") or string.find(part, "\"type\"%s*:%s*\"tileset\"") then + return 0.8 + end + end + if string.find(h, "\"tilewidth\"", 1, true) and (string.find(h, "\"orientation\"", 1, true) or string.find(h, "\"tilesets\"", 1, true)) then + return 0.6 + end + end + return 0 +end +end + +do -- layered/aseprite +local Bytes = require("@rosetta/core/Bytes") +S["layered/aseprite"] = function(r: Bytes.Reader): number + if r:peekU8(4) == 0xE0 and r:peekU8(5) == 0xA5 then + local d = r:peekU8(12) + if (d == 32 or d == 16 or d == 8) and r:peekU8(13) == 0 then + return 1 + end + return 0.5 + end + return 0 +end +end + +do -- layered/ora +local Bytes = require("@rosetta/core/Bytes") +local MIME = "image/openraster" +S["layered/ora"] = function(r: Bytes.Reader): number + -- a zip whose first (stored) entry is "mimetype" holding image/openraster + if r:peek(4) == "PK\3\4" and r:peek(8, 30) == "mimetype" and r:peek(#MIME, 38) == MIME then + return 1 + end + return 0 +end +end + +do -- layered/psd +local Bytes = require("@rosetta/core/Bytes") +S["layered/psd"] = function(r: Bytes.Reader): number + local h = r:peek(6) + if string.sub(h, 1, 4) == "8BPS" and (string.sub(h, 5, 6) == "\0\1" or string.sub(h, 5, 6) == "\0\2") then + return 1 + end + return 0 +end +end + +do -- subtitle/ass +local Sniff = require("@rosetta/core/Sniff") +local Bytes = require("@rosetta/core/Bytes") +S["subtitle/ass"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 64) + if string.match(head, "^%s*%[[Ss]cript [Ii]nfo%]") then + return 1 + end + return 0 +end +end + +do -- subtitle/srt +local Sniff = require("@rosetta/core/Sniff") +local Bytes = require("@rosetta/core/Bytes") +local TIMING = "^%s*(%d+):(%d%d?):(%d%d?)[,.](%d+)%s*%-%->%s*(%d+):(%d%d?):(%d%d?)[,.](%d+)%s*(.-)%s*$" +local function frac(digits: string): number + return (tonumber(digits) :: number) / 10 ^ #digits +end +local function timing(line: string): (number?, number?, string?) + local h1, m1, s1, f1, h2, m2, s2, f2, rest = string.match(line, TIMING) + if not h1 then + return nil, nil, nil + end + local a = tonumber(h1) :: number * 3600 + tonumber(m1) :: number * 60 + tonumber(s1) :: number + frac(f1 :: string) + local b = tonumber(h2) :: number * 3600 + tonumber(m2) :: number * 60 + tonumber(s2) :: number + frac(f2 :: string) + return a, b, rest +end +S["subtitle/srt"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 512) + head = string.gsub(head, "\r", "\n") + local first, second = string.match(head, "^%s*([^\n]*)\n([^\n]*)") + if first and string.match(first, "^%d+%s*$") and second and timing(second) then + return 0.9 + end + if first and timing(first) then + return 0.6 + end + return 0 +end +end + +do -- subtitle/vtt +local Sniff = require("@rosetta/core/Sniff") +local Bytes = require("@rosetta/core/Bytes") +S["subtitle/vtt"] = function(r: Bytes.Reader): number + local head = Sniff.text(r, 10) + if string.sub(head, 1, 6) == "WEBVTT" then + local c = string.sub(head, 7, 7) + if c == "" or c == " " or c == "\t" or c == "\n" or c == "\r" then + return 1 + end + end + return 0 +end +end + +do -- music/669 +local Bytes = require("@rosetta/core/Bytes") +local function validHeader(r: Bytes.Reader): boolean + if r:size() < 497 then + return false + end + local magic = r:peek(2) + if magic ~= "if" and magic ~= "JN" then + return false + end + local nsmp, npat, restart = r:peekU8(110), r:peekU8(111), r:peekU8(112) + if nsmp > 64 or restart >= 128 or npat > 128 then + return false + end + local bad = 0 + for i = 2, 109 do + local c = r:peekU8(i) + if c > 0 and c <= 31 then + bad += 1 + if bad > 40 then + return false + end + end + end + for i = 0, 127 do + local o, t, b = r:peekU8(113 + i), r:peekU8(241 + i), r:peekU8(369 + i) + if (o >= 128 and o < 0xFE) or (o < 128 and t == 0) or t > 15 or b >= 64 then + return false + end + end + return true +end +S["music/669"] = function(r: Bytes.Reader): number + return if validHeader(r) then 0.6 else 0 +end +end + +do -- music/ahx +local Bytes = require("@rosetta/core/Bytes") +S["music/ahx"] = function(r: Bytes.Reader): number + local m = r:peek(4) + return if m and #m == 4 and string.sub(m, 1, 3) == "THX" and string.byte(m, 4) < 3 then 1 else 0 +end +end + +do -- music/far +local Bytes = require("@rosetta/core/Bytes") +S["music/far"] = function(r: Bytes.Reader): number + if r:size() >= 98 and r:peek(4) == "FAR\xFE" and r:peek(3, 44) == "\r\n\x1A" and r:peekU8(47) + r:peekU8(48) * 256 >= 98 then + return 1 + end + return 0 +end +end + +do -- music/hmp +local Bytes = require("@rosetta/core/Bytes") +local HMI_MAGIC = "HMI-MIDISONG061595" +S["music/hmp"] = function(r: Bytes.Reader): number + return if r:peek(8) == "HMIMIDIP" or r:peek(18) == HMI_MAGIC then 1 else 0 +end +end + +do -- music/hvl +local Bytes = require("@rosetta/core/Bytes") +S["music/hvl"] = function(r: Bytes.Reader): number + local m = r:peek(4) + return if m and #m == 4 and string.sub(m, 1, 3) == "HVL" and string.byte(m, 4) <= 1 then 1 else 0 +end +end + +do -- music/it +local Bytes = require("@rosetta/core/Bytes") +S["music/it"] = function(r: Bytes.Reader): number + return if r:peek(4) == "IMPM" then 1 else 0 +end +end + +do -- music/med +local Bytes = require("@rosetta/core/Bytes") +local function validHeader(r: Bytes.Reader): boolean + if r:size() < 52 or r:peek(3) ~= "MMD" then + return false + end + local v = r:peekU8(3) + if v < 0x30 or v > 0x33 then + return false + end + local h = r:sub(8, 44) + local songOff = h:u32be() + h:skip(4) + local blockOff = h:u32be() + h:skip(4) + local smpOff = h:u32be() + return songOff >= 52 and songOff + 63 * 8 + 284 <= r:size() and blockOff >= 52 and (smpOff == 0 or smpOff >= 52) +end +S["music/med"] = function(r: Bytes.Reader): number + return if validHeader(r) then 1 else 0 +end +end + +do -- music/midi +local Bytes = require("@rosetta/core/Bytes") +S["music/midi"] = function(r: Bytes.Reader): number + if r:peek(4) == "MThd" then + return 1 + end + if r:peek(4) == "RIFF" and r:peek(4, 8) == "RMID" then + return 1 + end + return 0 +end +end + +do -- music/mod +local Bytes = require("@rosetta/core/Bytes") +local FIXED: { [string]: number } = { + ["M.K."] = 4, + ["M!K!"] = 4, + ["M&K!"] = 4, + ["N.T."] = 4, + ["FLT4"] = 4, + ["FLT8"] = 8, + ["CD81"] = 8, + ["OKTA"] = 8, + ["OCTA"] = 8, + ["EXO4"] = 4, + ["EXO8"] = 8, +} +local function signatureChannels(sig: string): number? + local fixed = FIXED[sig] + if fixed then + return fixed + end + local d = string.match(sig, "^(%d)CHN$") + if d then + local n = tonumber(d) :: number + return if n >= 1 then n else nil + end + local dd = string.match(sig, "^(%d%d)C[HN]$") + if dd then + local n = tonumber(dd) :: number + return if n >= 1 and n <= 32 then n else nil + end + local t = string.match(sig, "^TDZ(%d)$") + if t then + local n = tonumber(t) :: number + return if n >= 1 then n else nil + end + return nil +end +S["music/mod"] = function(r: Bytes.Reader): number + if r:size() < 1084 then + return 0 + end + local sig = r:peek(4, 1080) + if signatureChannels(sig) then + return 0.8 + end + return 0 +end +end + +do -- music/mtm +local Bytes = require("@rosetta/core/Bytes") +S["music/mtm"] = function(r: Bytes.Reader): number + if r:size() >= 66 and r:peek(3) == "MTM" and r:peekU8(3) < 0x20 and r:peekU8(33) >= 1 and r:peekU8(33) <= 32 then + return 1 + end + return 0 +end +end + +do -- music/mus +local Bytes = require("@rosetta/core/Bytes") +S["music/mus"] = function(r: Bytes.Reader): number + return if r:peek(4) == "MUS\x1a" then 1 else 0 +end +end + +do -- music/okt +local Bytes = require("@rosetta/core/Bytes") +S["music/okt"] = function(r: Bytes.Reader): number + return if r:peek(8) == "OKTASONG" then 1 else 0 +end +end + +do -- music/ptm +local Bytes = require("@rosetta/core/Bytes") +local function validHeader(r: Bytes.Reader): boolean + if r:size() < 608 or r:peek(4, 44) ~= "PTMF" or r:peekU8(28) ~= 26 or r:peekU8(30) > 2 then + return false + end + local h = r:sub(32, 10) + local nord, nsmp, npat, nch, flags = h:u16le(), h:u16le(), h:u16le(), h:u16le(), h:u16le() + return flags == 0 and nch >= 1 and nch <= 32 and nord >= 1 and nord <= 256 and nsmp >= 1 and nsmp <= 255 and npat >= 1 and npat <= 128 +end +S["music/ptm"] = function(r: Bytes.Reader): number + return if validHeader(r) then 1 else 0 +end +end + +do -- music/s3m +local Bytes = require("@rosetta/core/Bytes") +S["music/s3m"] = function(r: Bytes.Reader): number + if r:size() >= 48 and r:peek(4, 44) == "SCRM" then + return 1 + end + return 0 +end +end + +do -- music/sf2 +local Bytes = require("@rosetta/core/Bytes") +local SoundFont = lazy(function() + return require("@rosetta/codecs/audio/SoundFont") +end) +S["music/sf2"] = function(r: Bytes.Reader): number + return if SoundFont.sniff(r) then 1 else 0 +end +end + +do -- music/stm +local Bytes = require("@rosetta/core/Bytes") +local function validHeader(r: Bytes.Reader): boolean + if r:size() < 48 then + return false + end + local eof, ftype, major, minor = r:peekU8(28), r:peekU8(29), r:peekU8(30), r:peekU8(31) + local npat, gv = r:peekU8(33), r:peekU8(34) + if ftype ~= 2 or (eof ~= 0x1A and eof ~= 2) or major ~= 2 or (minor ~= 0 and minor ~= 10 and minor ~= 20 and minor ~= 21) then + return false + end + if npat > 64 or (gv > 64 and gv ~= 0x58) then + return false + end + for i = 20, 27 do + local c = r:peekU8(i) + if c < 0x20 or c >= 0x7F then + return false + end + end + return true +end +S["music/stm"] = function(r: Bytes.Reader): number + return if validHeader(r) then 0.7 else 0 +end +end + +do -- music/ult +local Bytes = require("@rosetta/core/Bytes") +S["music/ult"] = function(r: Bytes.Reader): number + local v = r:peekU8(14) + if r:size() >= 48 and r:peek(14) == "MAS_UTrack_V00" and v >= 0x31 and v <= 0x34 then + return 1 + end + return 0 +end +end + +do -- music/umx +local Bytes = require("@rosetta/core/Bytes") +local MAGIC = "\xC1\x83\x2A\x9E" +type Header = { version: number, nameCount: number, nameOffset: number, exportCount: number, exportOffset: number, importCount: number, importOffset: number } +local function header(r: Bytes.Reader): Header? + if r:size() < 36 or r:peek(4) ~= MAGIC then + return nil + end + local h = r:sub(4, 32) + local version = h:u16le() + h:skip(6) + local hd: Header = { + version = version, + nameCount = h:u32le(), + nameOffset = h:u32le(), + exportCount = h:u32le(), + exportOffset = h:u32le(), + importCount = h:u32le(), + importOffset = h:u32le(), + } + if h.err or hd.nameOffset < 36 or hd.exportOffset < 36 or hd.importOffset < 36 then + return nil + end + if hd.nameCount == 0 or hd.exportCount == 0 or hd.importCount == 0 or hd.nameCount > 2 ^ 20 or hd.exportCount > 2 ^ 20 or hd.importCount > 2 ^ 20 then + return nil + end + return hd +end +local function index(r: Bytes.Reader): number + local b = r:u8() + local neg = b >= 0x80 + local v = b % 64 + if bit32.band(b, 0x40) ~= 0 then + local shift = 6 + repeat + b = r:u8() + v += (b % 128) * 2 ^ shift + shift += 7 + until b < 0x80 or shift >= 32 + end + return if neg then -v else v +end +local function names(r: Bytes.Reader, h: Header): { string } + local list = {} + local nr = r:sub(h.nameOffset) + for _ = 1, math.min(h.nameCount, 65536) do + if nr:remaining() < 5 then + break + end + if h.version >= 64 then + index(nr) + end + table.insert(list, string.lower(nr:cstring(1024))) + nr:skip(4) + end + return list +end +S["music/umx"] = function(r: Bytes.Reader): number + local h = header(r) + if not h then + return 0 + end + return if table.find(names(r, h), "music") then 1 else 0.3 +end +end + +do -- music/xm +local Bytes = require("@rosetta/core/Bytes") +local MAGIC = "Extended Module: " +S["music/xm"] = function(r: Bytes.Reader): number + return if r:peek(17) == MAGIC then 1 else 0 +end +end + +do -- music/xmi +local Bytes = require("@rosetta/core/Bytes") +S["music/xmi"] = function(r: Bytes.Reader): number + local id, kind = r:peek(4), r:peek(4, 8) + if id == "FORM" and (kind == "XDIR" or kind == "XMID") then + return 1 + end + return if id == "CAT " and kind == "XMID" then 0.9 else 0 +end +end + +do -- playlist/m3u +local Sniff = require("@rosetta/core/Sniff") +local Bytes = require("@rosetta/core/Bytes") +S["playlist/m3u"] = function(r: Bytes.Reader): number + local s = Sniff.text(r, 512) + s = (string.match(s, "^%s*(.*)$") :: string) + if string.sub(s, 1, 7) == "#EXTM3U" then + return 0.95 + end + if string.find(s, "^#EXTINF:") or string.find(s, "^#EXT%-X%-") then + return 0.8 + end + return 0 +end +end + +do -- playlist/pls +local Sniff = require("@rosetta/core/Sniff") +local Bytes = require("@rosetta/core/Bytes") +local Text = lazy(function() + return require("@rosetta/codecs/text/Text") +end) +S["playlist/pls"] = function(r: Bytes.Reader): number + local s = Sniff.text(r, 64) + local first = string.match(s, "^%s*([^\r\n]*)") + return if first and string.lower(Text.trim(first)) == "[playlist]" then 0.95 else 0 +end +end + +do -- playlist/xspf +local Bytes = require("@rosetta/core/Bytes") +local NS = "http://xspf.org/ns/0/" +S["playlist/xspf"] = function(r: Bytes.Reader): number + local s = r:peek(1024) + local i = string.find(s, "<%w*:?playlist[%s>]") + if i and string.find(s, NS, 1, true) then + return 0.95 + end + return 0 +end +end + +return S diff --git a/src/Rosetta/init.luau b/src/Rosetta/init.luau index a0db2dd..b4eb96a 100644 --- a/src/Rosetta/init.luau +++ b/src/Rosetta/init.luau @@ -78,6 +78,56 @@ end local LATE: { [string]: number } = { br = 0.3 } -- archive/br: a trial decode of up to 256 KB +-- detection order: by the cost of a sniff (Registry.sniff: Sniffs.luau, Sniffs.luau reaching a codec, the format +-- module), then registry order; the costly LATE sniffs last +local order: { number }? = nil +local byExt: { [string]: { number } } = {} +local Sniffs: { [string]: (any) -> number }? = nil + +local function sniffOrder(): { number } + local o = order + if o then + return o + end + local list: { number } = {} + for idx, e in Registry do + table.insert(list, idx) + for _, x in e.extensions do + byExt[x] = byExt[x] or {} + table.insert(byExt[x], idx) + end + end + local function rank(idx: number): number + local e = Registry[idx] + return if LATE[e.name] then 3 else e.sniff + end + table.sort(list, function(a: number, b: number): boolean + local ra, rb = rank(a), rank(b) + if ra ~= rb then + return ra < rb + end + return a < b + end) + order = list + return list +end + +local function sniffer(e: Registry.Entry): ((any) -> number)? + if e.sniff < 2 then + local s = Sniffs + if not s then + s = require("@rosetta/Sniffs") :: any + Sniffs = s + end + local f = (s :: { [string]: (any) -> number })[e.path] + if f then + return f + end + end + local m = module(e) + return if m and type(m.sniff) == "function" then m.sniff else nil +end + local function detect(buf: buffer, name: string?, category: string?, format: string?): (Registry.Entry?, Err.Err?) if format then local e = find(format, category) @@ -87,52 +137,35 @@ local function detect(buf: buffer, name: string?, category: string?, format: str return e, nil end local ext = Input.extension(name) + local list = sniffOrder() + local hits = if ext then byExt[ext] else nil local best: Registry.Entry? = nil local bestScore, bestIdx = 0, 0 - -- sniffs score 0..1 (core/Sniff); the extension's format scoring 1 cannot be beaten. Formats with a costly sniff - -- (LATE: the most they score) run last, and only when they could still win; ties go to registry order. - local late: { number }? = nil - for idx, e in Registry do - if inCategory(e, category) and (e.caps.decode or e.caps.open) then - local cap = LATE[e.name] - if cap then - late = late or {} - table.insert(late :: { number }, idx) - continue - end - local m = module(e) - if m and m.sniff then - local ok, score = pcall(m.sniff, Bytes.reader(buf)) - if ok and type(score) == "number" and score > 0 then - local extHit = ext and table.find(e.extensions, ext) - if extHit then - score += 0.01 -- ties go to the extension - end - if score > bestScore then - best, bestScore, bestIdx = e, score, idx - if extHit and score >= 1.01 then - return e, nil - end - end + -- sniffs score 0..1 (core/Sniff), +0.01 for the extension's formats; the best wins, ties go to registry order. The + -- extension's formats run first, and a sniff runs only while its cap (1, or LATE) could still win. + for pass = 1, 2 do + local ids = if pass == 1 then hits else list + if ids then + for _, idx in ids do + if pass == 2 and bestScore > 1 then + break end - end - end - end - if late then - for _, idx in late do - local e = Registry[idx] - local extHit = ext and table.find(e.extensions, ext) - local cap = LATE[e.name] + (if extHit then 0.01 else 0) - if cap > bestScore or (cap == bestScore and idx < bestIdx) then - local m = module(e) - if m and m.sniff then - local ok, score = pcall(m.sniff, Bytes.reader(buf)) - if ok and type(score) == "number" and score > 0 then - if extHit then - score += 0.01 - end - if score > bestScore or (score == bestScore and idx < bestIdx) then - best, bestScore, bestIdx = e, score, idx + local e = Registry[idx] + local extHit = pass == 1 or (hits ~= nil and table.find(hits, idx) ~= nil) + if (pass == 1 or not extHit) and inCategory(e, category) and (e.caps.decode or e.caps.open) then + local cap = (LATE[e.name] or 1) + (if extHit then 0.01 else 0) + if cap > bestScore or (cap == bestScore and idx < bestIdx) then + local sniff = sniffer(e) + if sniff then + local ok, score = pcall(sniff, Bytes.reader(buf)) + if ok and type(score) == "number" and score > 0 then + if extHit then + score += 0.01 + end + if score > bestScore or (score == bestScore and idx < bestIdx) then + best, bestScore, bestIdx = e, score, idx + end + end end end end @@ -696,7 +729,7 @@ function F.detect(src: any, opts: Options?): (string?, Err.Err?) return nil, err end -- a format may name the file's flavour more precisely (video/mkv: "webm" for DocType webm) - local m = module(entry) + local m = if entry.variant then module(entry) else nil if m and type(m.variant) == "function" then local ok, v = pcall(m.variant, Bytes.reader(buf)) if ok and type(v) == "string" then diff --git a/tests/detect.luau b/tests/detect.luau new file mode 100644 index 0000000..c6054f6 --- /dev/null +++ b/tests/detect.luau @@ -0,0 +1,210 @@ +-- detect tests: lazy detection (Sniffs.luau, cost order, extension first) against the eager reference (every format +-- module's own sniff, registry order) on samples of every fixture module, with and without names and categories; +-- which modules a first detect loads. Fixtures: tools/fixtures/detect.py. +local T = require("@tests/T") +local Registry = require("@rosetta/Registry") + +local loads: { string } = {} +for _, e in Registry do + local load = e.load + e.load = function(): any + table.insert(loads, e.path) + return load() + end +end + +local F = require("@rosetta") +local Bytes = require("@rosetta/core/Bytes") +local Input = require("@rosetta/core/Input") +local Sniffs = require("@rosetta/Sniffs") +local Blobs1 = require("@tests/gen/detect_blobs_1") +local Blobs2 = require("@tests/gen/detect_blobs_2") +local Blobs3 = require("@tests/gen/detect_blobs_3") +local Blobs4 = require("@tests/gen/detect_blobs_4") + +local t = T.suite("detect") + +-- 1. a first detect of a PNG loads no format module, with or without its name +local PNG = buffer.fromstring("\137PNG\r\n\26\n\0\0\0\rIHDR\0\0\0\1\0\0\0\1\8\6\0\0\0\31\21\196\137\0\0\0\rIDATx\218c\248\255\255?\0\5\254\2\254\167\53\129\132\0\0\0\0IEND\174B`\130") +t:eq(F.detect(PNG, { name = "a.png" }), "png", "png with name") +t:eq(F.detect(PNG), "png", "png without name") +t:eq(F.detect(PNG, { name = "a.jpg" }), "png", "png named .jpg") +t:eq(#loads, 0, "no format module loaded (" .. table.concat(loads, " ") .. ")") +local junk = buffer.create(4096) +for i = 0, 4095 do + buffer.writeu8(junk, i, (i * 7919) % 251) +end +F.detect(junk) +local need = 0 +for _, e in Registry do + if e.sniff == 2 then + need += 1 + end +end +t:check(#loads <= need + 1, "unknown data loads only the modules that sniff themselves: " .. table.concat(loads, " ")) +t:note("unknown data: %d format modules loaded (%s)", #loads, table.concat(loads, " ")) + +-- 2. the eager reference: each module's own sniff in registry order, the extension's format at 1 returns at once, +-- archive/br (a trial decode, at most 0.3) last +local modules: { [string]: any } = {} +for _, e in Registry do + modules[e.path] = e.load() +end + +local function refDetect(buf: buffer, name: string?, category: string?): any + local ext = Input.extension(name) + local best, bestScore, bestIdx = nil, 0, 0 + local late: { number } = {} + for idx, e in Registry do + if (category == nil or e.category == category) and (e.caps.decode or e.caps.open) then + if e.name == "br" then + table.insert(late, idx) + continue + end + local ok, score = pcall(modules[e.path].sniff, Bytes.reader(buf)) + if ok and type(score) == "number" and score > 0 then + local extHit = ext and table.find(e.extensions, ext) + if extHit then + score += 0.01 + end + if score > bestScore then + best, bestScore, bestIdx = e, score, idx + if extHit and score >= 1.01 then + return e + end + end + end + end + end + for _, idx in late do + local e = Registry[idx] + local extHit = ext and table.find(e.extensions, ext) + local cap = 0.3 + (if extHit then 0.01 else 0) + if cap > bestScore or (cap == bestScore and idx < bestIdx) then + local ok, score = pcall(modules[e.path].sniff, Bytes.reader(buf)) + if ok and type(score) == "number" and score > 0 then + if extHit then + score += 0.01 + end + if score > bestScore or (score == bestScore and idx < bestIdx) then + best, bestScore, bestIdx = e, score, idx + end + end + end + end + if best then + return best + end + if ext then + for _, e in Registry do + if (category == nil or e.category == category) and e.name == ext then + return e + end + end + for _, e in Registry do + if (category == nil or e.category == category) and table.find(e.extensions, ext) then + return e + end + end + end + return nil +end + +local function refName(buf: buffer, name: string?, category: string?): string? + local e = refDetect(buf, name, category) + if not e then + return nil + end + local m = modules[e.path] + if type(m.variant) == "function" then + local ok, v = pcall(m.variant, Bytes.reader(buf)) + if ok and type(v) == "string" then + return v + end + end + return e.name +end + +local blobs: { { from: string, data: string } } = {} +for _, part in { Blobs1, Blobs2, Blobs3, Blobs4 } do + for _, b in part :: any do + table.insert(blobs, b) + end +end +local rng = T.rng(7) +for n = 0, 40 do + local b = buffer.create(n * 7) + for i = 0, n * 7 - 1 do + buffer.writeu8(b, i, rng(256) - 1) + end + table.insert(blobs, { from = "random", data = buffer.tostring(b) }) +end +table.insert(blobs, { from = "junk", data = buffer.tostring(junk) }) +table.insert(blobs, { from = "png", data = buffer.tostring(PNG) }) +t:check(#blobs > 1000, "samples from the fixture modules (" .. #blobs .. ")") + +-- 3. every copied sniff scores as the module's own, and every score is in 0..1 (the cost order relies on it) +local copied, diff, over = 0, 0, 0 +for _, e in Registry do + local s = (Sniffs :: any)[e.path] + t:eq(s ~= nil, e.sniff < 2, e.path .. ": in Sniffs.luau as Registry.sniff says") + if s then + copied += 1 + end +end +for _, b in blobs do + local buf = buffer.fromstring(b.data) + for _, e in Registry do + local own = modules[e.path].sniff + local ok1, s1 = pcall(own, Bytes.reader(buf)) + if ok1 and type(s1) == "number" and s1 > 1 then + over += 1 + t:note("%s scores %s on a sample of %s", e.path, tostring(s1), b.from) + end + local s = (Sniffs :: any)[e.path] + if s then + local ok2, s2 = pcall(s, Bytes.reader(buf)) + if ok1 ~= ok2 or (ok1 and s1 ~= s2) then + diff += 1 + if diff <= 10 then + t:note("%s on a sample of %s: module %s, copy %s", e.path, b.from, tostring(s1), tostring(s2)) + end + end + end + end +end +t:eq(diff, 0, "copied sniffs score as the modules do") +t:eq(over, 0, "no sniff scores over 1") + +-- 4. F.detect = the reference: no name, the reference's own extension, a wrong one, an unknown one; and per category +local runs, mismatch = 0, 0 +local function same(buf: buffer, from: string, name: string?, category: string?) + local want = refName(buf, name, category) + local got = F.detect(buf, { name = name, category = category }) + runs += 1 + if got ~= want then + mismatch += 1 + if mismatch <= 10 then + t:note("sample of %s, name %s, category %s: got %s, want %s", from, tostring(name), tostring(category), tostring(got), tostring(want)) + end + end +end +for _, b in blobs do + local buf = buffer.fromstring(b.data) + same(buf, b.from, nil, nil) + local e = refDetect(buf, nil, nil) + if e then + same(buf, b.from, "x." .. e.extensions[1], nil) + same(buf, b.from, nil, e.category) + end + same(buf, b.from, "x.png", nil) + same(buf, b.from, "x.txt", nil) + same(buf, b.from, "x.bin", "audio") +end +t:eq(mismatch, 0, "F.detect matches the eager reference (" .. runs .. " detects)") +t:note("%d samples, %d detects, %d of %d sniffs copied into Sniffs.luau", #blobs, runs, copied, #Registry) + +t:fuzz("detect", function(b: buffer): any + return F.detect(b) +end, { PNG, junk }) +t:done() diff --git a/tools/fixtures.py b/tools/fixtures.py index 08dce50..db102cf 100644 --- a/tools/fixtures.py +++ b/tools/fixtures.py @@ -8,6 +8,7 @@ # INPUTS = ["tests/fixtures/pngsuite", ...] # optional: files / dirs whose change triggers a rebuild # def generate(ctx): ... # ctx.emit("png_suite", value), ctx.nix("imagemagick", [...]), ... # A generator is skipped while all its outputs are newer than itself and its INPUTS (--force reruns it). +# LAST = True runs it after the others; it also reruns when any other generator's output changed (it reads them) # # ctx.emit(name, value): writes tests/gen/.luau returning value. Python values map to Luau: bytes -> string # literal (any bytes), str -> string literal, int / float / bool, list / tuple -> array, dict -> table (string keys @@ -123,12 +124,16 @@ def main(): if "--list" in sys.argv: print("\n".join(names)) return + mods = {name: load(os.path.join(GENERATORS, name + ".py")) for name in names} + names.sort(key=lambda n: bool(getattr(mods[n], "LAST", False))) for name in names: if args and not any(a in name for a in args): continue path = os.path.join(GENERATORS, name + ".py") - mod = load(path) + mod = mods[name] inputs = [path, os.path.abspath(__file__)] + [os.path.join(ROOT, p) for p in getattr(mod, "INPUTS", [])] + if getattr(mod, "LAST", False): + inputs += [os.path.join(stamps, n) for n in names if n != name and not getattr(mods[n], "LAST", False)] stamp = os.path.join(stamps, name) if not force and os.path.exists(stamp): outs = open(stamp).read().split("\n") diff --git a/tools/fixtures/detect.py b/tools/fixtures/detect.py new file mode 100644 index 0000000..a273701 --- /dev/null +++ b/tools/fixtures/detect.py @@ -0,0 +1,56 @@ +# Detection fixtures (tools/fixtures.py): samples of every other fixture module, for tests/detect.luau (lazy detection +# against the eager reference). Runs after the other generators (LAST) and reads their tests/gen output. +# tests/gen/detect_blobs_<1..4>.luau { { from = "", data = } }: up to PER_MODULE string literals of +# 16 bytes or more per module, evenly spaced, cut to CUT bytes, without repeats +import hashlib, os, re + +LAST = True +PER_MODULE = 6 +CUT = 16384 +PARTS = 4 +PART_BYTES = 5_000_000 +HEADER = "-- generated by tools/fixtures.py" +LITERAL = re.compile(rb'"([^"]*)"') +ESCAPE = re.compile(rb"\\x([0-9a-f]{2})") + + +def decode(raw): + return ESCAPE.sub(lambda m: bytes([int(m.group(1), 16)]), raw) + + +def generate(ctx): + names = sorted(f[:-5] for f in os.listdir(ctx.gen) if f.endswith(".luau") and not f.startswith("detect_")) + seen, blobs = set(), [] + for name in names: + with open(os.path.join(ctx.gen, name + ".luau"), "rb") as f: + text = f.read() + if not text.startswith(HEADER.encode()): + continue + lits = [m.span(1) for m in LITERAL.finditer(text) if m.end(1) - m.start(1) >= 16] + lits = [(a, b) for a, b in lits if len(decode(text[a:min(b, a + 64)])) >= 16] + if not lits: + continue + step = max(1, len(lits) / PER_MODULE) + picks = sorted({int(i * step) for i in range(PER_MODULE)} & set(range(len(lits)))) + for i in picks: + a, b = lits[i] + data = decode(text[a:min(b, a + CUT * 4)])[:CUT] + h = hashlib.sha1(data).digest() + if h in seen: + continue + seen.add(h) + blobs.append({"from": name, "data": data}) + parts, cur, size = [], [], 0 + for b in blobs: + if size + len(b["data"]) > PART_BYTES and cur: + parts.append(cur) + cur, size = [], 0 + cur.append(b) + size += len(b["data"]) + parts.append(cur) + if len(parts) > PARTS: + raise SystemExit("fixtures/detect: %d parts, raise PARTS (and the requires in tests/detect.luau)" % len(parts)) + while len(parts) < PARTS: + parts.append([]) + for i, p in enumerate(parts, 1): + ctx.emit("detect_blobs_%d" % i, p) diff --git a/tools/gen_registry.py b/tools/gen_registry.py index e7ec47e..6c1024b 100644 --- a/tools/gen_registry.py +++ b/tools/gen_registry.py @@ -3,6 +3,8 @@ # src/Rosetta///init.luau and writes # src/Rosetta/Registry.luau a static list (Roblox has no dynamic require): each format's contract metadata, copied # from its init.luau, and a load() that requires the module on first use +# src/Rosetta/Sniffs.luau each format's sniff, copied with what it reaches (tools/sniff_extract.py), so detection +# runs without requiring the format modules # docs/FORMATS.md the capability matrix, from each contract's caps # README.md the format table (read / write) and the codec + container list, between the markers # / and / @@ -11,6 +13,9 @@ # --check: exit 1 when any of them is out of date (tools/lint.sh runs this). import os, re, sys +sys.path.insert(0, os.path.dirname(os.path.abspath(__file__))) +import sniff_extract + ROOT = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) SRC = os.path.join(ROOT, "src", "Rosetta") CATEGORIES = ["image", "audio", "video", "model", "cad", "font", "archive", "data", "vector", "layered", "subtitle", @@ -50,6 +55,9 @@ def scan(): sys.exit("gen_registry: %s/%s/init.luau: missing contract fields %s" % (cat, fmt, ", ".join(missing))) c["path"] = cat + "/" + fmt c["folder_category"] = cat + text = open(init).read() + c["sniff_cost"], c["sniff_block"], self_name = sniff_extract.extract(text, c["path"]) + c["variant"] = sniff_extract.has_variant(text, self_name) formats.append(c) return formats @@ -60,6 +68,8 @@ def registry(formats): "-- Registry: GENERATED by tools/gen_registry.py from the format folders - do not edit.", "-- One entry per format: the contract metadata (copied from its init.luau) and load(), which requires the format", "-- module on first use (a static require, as Roblox needs). Order: category, then name.", + "-- sniff: where detection finds the format's sniff (tools/sniff_extract.py): 0 Sniffs.luau, 1 Sniffs.luau reaching a", + "-- codec / container on first call, 2 the format module. variant: the module has variant(r).", "export type Entry = {", "\tname: string,", "\tcategory: string,", @@ -68,6 +78,8 @@ def registry(formats): "\tmime: { string },", "\tdeps: { string },", "\tcaps: { [string]: any },", + "\tsniff: number,", + "\tvariant: boolean?,", "\tload: () -> any,", "}", "", @@ -83,6 +95,8 @@ def registry(formats): "\t\tmime = %s," % c["mime"], "\t\tdeps = %s," % c["deps"], "\t\tcaps = %s," % c["caps"], + "\t\tsniff = %d," % c["sniff_cost"], + ] + (["\t\tvariant = true,"] if c["variant"] else []) + [ "\t\tload = function()", '\t\t\treturn require("@rosetta/%s")' % c["path"], "\t\tend,", @@ -92,6 +106,38 @@ def registry(formats): return "\n".join(out) +def sniffs(formats): + out = [ + "--!strict", + "--!optimize 2", + "-- Sniffs: GENERATED by tools/gen_registry.py from the format folders - do not edit.", + "-- Each format's sniff (format path -> sniff(r)), copied from its init.luau with the top-level locals and types it", + "-- reaches (tools/sniff_extract.py), so detection requires no format module. Requires outside core/ are proxies that", + "-- require on first use. Formats whose sniff needs their module (Registry sniff = 2) are not here.", + "local S: { [string]: (any) -> number } = {}", + "", + "local function lazy(load: () -> any): any", + "\tlocal proxy = {}", + "\treturn setmetatable(proxy, {", + "\t\t__index = function(_, k: any): any", + "\t\t\tlocal m = load()", + "\t\t\tsetmetatable(proxy, { __index = m })", + "\t\t\treturn m[k]", + "\t\tend,", + "\t})", + "end", + "", + ] + for c in formats: + if c["sniff_block"] is None: + continue + out.append("do -- %s" % c["path"]) + out += c["sniff_block"] + out += ["end", ""] + out += ["return S", ""] + return "\n".join(out) + + def caps_dict(lit): """{ decode = true, depths = { 8 } } -> ordered [(key, text)] at the top level.""" body = lit.strip()[1:-1] @@ -220,6 +266,7 @@ def main(): readme_path = os.path.join(ROOT, "README.md") outputs = { os.path.join(SRC, "Registry.luau"): registry(formats), + os.path.join(SRC, "Sniffs.luau"): sniffs(formats), os.path.join(ROOT, "docs", "FORMATS.md"): formats_md(formats), readme_path: readme(formats, readme_path), } @@ -239,7 +286,7 @@ def main(): sys.exit(1) print("gen_registry: up to date (%d formats)" % len(formats)) else: - print("gen_registry: %d formats -> src/Rosetta/Registry.luau, docs/FORMATS.md, README.md%s" % ( + print("gen_registry: %d formats -> src/Rosetta/Registry.luau, Sniffs.luau, docs/FORMATS.md, README.md%s" % ( len(formats), "" if stale else " (unchanged)")) diff --git a/tools/lint_rules.py b/tools/lint_rules.py index 7027f61..fd998f5 100644 --- a/tools/lint_rules.py +++ b/tools/lint_rules.py @@ -9,7 +9,7 @@ # NATIVE native code never throws: a --!native module has no error( / assert( and requires no module that has # one; an @native function body has no error( / assert(. A format's init.luau is never --!native. # LAYERS requires go downward: core < Types < host; core, Types < codecs < containers < formats (/) -# < ops < api (init, Registry). core / codecs / containers / ops may require their own layer; a format +# < ops < api (init, Registry, Sniffs). core / codecs / containers / ops may require their own layer; a format # may require its own folder but never another format; only the api requires host. # codecs live in a domain folder: codecs// (CODEC_DOMAINS). # DEPS a format folder's requires outside itself are exactly the contract's deps = { ... }. @@ -19,7 +19,8 @@ # tests//.luau with a fuzz pass (:fuzz(). # DUP no copy-pasted code: a function body of DUP_LINES (12) or more code lines whose tokens (comments and # whitespace dropped, identifiers kept) equal another module's function body fails; move it down to a -# shared module (core / codecs / containers) and call it from both. +# shared module (core / codecs / containers) and call it from both. Sniffs.luau (generated copies of the +# formats' sniffs) is not compared. # DOCS docs/STYLE.md's layer block names every codec (codecs//), container and core module in the # tree; README.md's generated format table and codec list ( ... ) # match tools/gen_registry.py's output; README.md links every docs/guide page, docs/API.md and @@ -69,7 +70,7 @@ def resolve(target): def layer(mod): """(rank, group) of a module path""" top = mod.split("/")[0] if mod else "" - if mod in ("", "Registry"): + if mod in ("", "Registry", "Sniffs"): return 6, "api" if top == "core": return 0, "core" @@ -296,6 +297,8 @@ TOKEN = re.compile(r'"(?:[^"\\]|\\.)*"|\'(?:[^\'\\]|\\.)*\'|\[=*\[.*?\]=*\]|[A-Z FUNC = re.compile(r"^(\s*)(?:local\s+)?function\b") bodies = {} for f, lines in text.items(): + if mods[f] == "Sniffs": + continue for i, line in enumerate(lines): m = FUNC.match(line) if not m: diff --git a/tools/sniff_extract.py b/tools/sniff_extract.py new file mode 100644 index 0000000..414ff58 --- /dev/null +++ b/tools/sniff_extract.py @@ -0,0 +1,198 @@ +#!/usr/bin/env python3 +# Sniff extraction for tools/gen_registry.py: copies each format's sniff function out of its init.luau, with the +# top-level locals, types and statements it reaches, so src/Rosetta/Sniffs.luau can sniff without requiring the +# format module. A format whose sniff reaches its own module table (or a forward-declared local) is not copied: the api +# loads the module to sniff it. Requires the copy reaches: core/* as they are; any other module through a proxy that +# requires it on first field access (sniff time). +# cost 0: the copy needs only core/*; 1: it reaches a proxied module; 2: not copied (the module sniffs). +import re + +KEYWORDS = set("and break continue do else elseif end false for function if in local nil not or repeat return then " + "true until while type export typeof".split()) +NAME = r"[A-Za-z_]\w*" + + +def clean(text): + """text with string, comment and long-bracket contents blanked (newlines kept), same length""" + out, i, n = [], 0, len(text) + while i < n: + c = text[i] + if c == "-" and text.startswith("--", i): + m = re.match(r"--\[(=*)\[", text[i:]) + if m: + j = text.find("]" + m.group(1) + "]", i + len(m.group(0))) + j = n if j < 0 else j + len(m.group(1)) + 2 + else: + j = text.find("\n", i) + j = n if j < 0 else j + out.append(re.sub(r"[^\n]", " ", text[i:j])) + i = j + elif c == "[" and re.match(r"\[(=*)\[", text[i:]): + m = re.match(r"\[(=*)\[", text[i:]) + j = text.find("]" + m.group(1) + "]", i + len(m.group(0))) + j = n if j < 0 else j + len(m.group(1)) + 2 + out.append('"' + re.sub(r"[^\n]", " ", text[i + 1:j - 1]) + '"') + i = j + elif c in "\"'": + j = i + 1 + while j < n and text[j] != c and text[j] != "\n": + j += 2 if text[j] == "\\" else 1 + j = min(j + 1, n) + out.append(c + " " * (j - i - 2) + c if j - i >= 2 else text[i:j]) + i = j + else: + out.append(c) + i += 1 + return "".join(out) + + +def split_top(s): + """split s on commas outside brackets""" + parts, depth, cur = [], 0, "" + for ch in s: + if ch in "({[<": + depth += 1 + elif ch in ")}]>": + depth -= 1 + if ch == "," and depth == 0: + parts.append(cur) + cur = "" + else: + cur += ch + parts.append(cur) + return parts + + +def statements(text): + """[(first line, last line, cleaned text)] of the top-level statements (0-based inclusive line numbers)""" + lines = text.split("\n") + cl = clean(text).split("\n") + starts = [i for i, l in enumerate(cl) if l[:1] not in ("", " ", "\t") and not re.match(r"(end|until)\b|[}\])]", l)] + out = [] + for k, s in enumerate(starts): + e = (starts[k + 1] if k + 1 < len(starts) else len(lines)) - 1 + while e > s and cl[e].strip() == "": + e -= 1 + out.append((s, e, "\n".join(cl[s:e + 1]))) + return out + + +def free_names(code): + """identifiers read by code that are not field / method names (an over-approximation: locals are included)""" + return {m.group(1) for m in re.finditer(r"(?"): + cut = i + break + head = rest if cut is None else rest[:cut] + names = [p.split(":")[0].strip() for p in split_top(head.split("\n")[0] if cut is None else head)] + return [n for n in names if re.fullmatch(NAME, n)], ("forward" if cut is None else "local") + return [], None + + +REQUIRE = re.compile(r'^local\s+(' + NAME + r')\s*=\s*require\("@rosetta/([\w/]+)"\)\s*$') + + +def extract(text, path): + """(cost, block lines or None, module table name) for one format's init.luau""" + lines = text.split("\n") + sts = statements(text) + sniff_i, self_name = None, None + for i, (s, e, st) in enumerate(sts): + m = re.match(r"function\s+(" + NAME + r")\.sniff\s*\(", st) + if m: + sniff_i, self_name = i, m.group(1) + if sniff_i is None: + return 2, None, None + defs = [] # (statement index, name, kind) + for i, (s, e, st) in enumerate(sts): + names, kind = defines(st) + for n in names: + defs.append((i, n, kind)) + def_names = {n for _, n, _ in defs} + # top-level statements that are not declarations: assignments, loops (a table filled at load time) + others = [i for i, (s, e, st) in enumerate(sts) if defines(st)[1] is None and i != sniff_i] + + def resolve(name, before): + best = None + for i, n, kind in defs: + if n == name and i < before: + best = (i, kind) + return best + + include, lazy, todo, bad = set(), {}, [sniff_i], False + reached = set() + while todo: + i = todo.pop() + if i in include: + continue + include.add(i) + st = sts[i][2] + body = st + if i == sniff_i: + body = st[st.index("("):] + for n in free_names(body): + if n == self_name: + bad = True + continue + r = resolve(n, i) + if r is None: + continue + j, kind = r + if kind == "forward": + bad = True + continue + reached.add(n) + req = REQUIRE.match(lines[sts[j][0]]) if sts[j][0] == sts[j][1] else None + if req and not req.group(2).startswith("core/"): + lazy[j] = (req.group(1), req.group(2)) + continue + todo.append(j) + # load-time statements that touch a reached local (a lookup table filled by a loop) + for k in others: + if k not in include and re.match(r"(function\s+)?" + re.escape(self_name) + r"\b|return\b", sts[k][2]) is None: + if free_names(sts[k][2]) & reached: + todo.append(k) + if bad: + return 2, None, self_name + # a non-function statement that reads a proxied module runs at load time: the proxy would load it at once + for i in include: + if i != sniff_i and defines(sts[i][2])[1] not in ("func", "type"): + if free_names(sts[i][2]) & {a for a, _ in lazy.values()}: + return 2, None, self_name + block = [] + for i in sorted(set(include) | set(lazy)): + s, e, st = sts[i] + if i in lazy: + alias, mod = lazy[i] + block.append('local %s = lazy(function()\n\treturn require("@rosetta/%s")\nend)' % (alias, mod)) + elif i == sniff_i: + src = "\n".join(lines[s:e + 1]) + src = re.sub(r"^function\s+" + re.escape(self_name) + r"\.sniff\s*\(", 'S["%s"] = function(' % path, src) + block.append(src) + else: + src = "\n".join(lines[s:e + 1]) + block.append(re.sub(r"^export\s+type\b", "type", src)) + return (1 if lazy else 0), block, self_name + + +def has_variant(text, self_name): + return self_name is not None and re.search(r"^function\s+" + re.escape(self_name) + r"\.variant\s*\(", text, re.M) is not None