[File] [PATCH] Add ColoRIX images.

Christos Zoulas christos at zoulas.com
Sat Apr 1 16:08:29 UTC 2023


Committed, thanks!

christos

> On Apr 1, 2023, at 11:15 AM, Eddy Jansson <eddy at klopper.net> wrote:
> 
> My attempt at adding support for this old MS-DOS-era image format.
> 
> I'm been maintaining this at https://github.com/eloj/rix-magic where there
> are also a directory of (truncated) test files.
> 
> ---
> magic/Magdir/images | 36 ++++++++++++++++++++++++++++++++++++
> 1 file changed, 36 insertions(+)
> 
> diff --git a/magic/Magdir/images b/magic/Magdir/images
> index 0506915..a0ff1ad 100644
> --- a/magic/Magdir/images
> +++ b/magic/Magdir/images
> @@ -4159,3 +4159,39 @@
> #!:mime	application/octet-stream
> !:mime	image/x-idf
> !:ext	idf
> +
> +# Type: ColoRIX VGA Paint Image File (.rix/.sci/.scX)
> +# From: Eddy Jansson <github.com/eloj>
> +# Reference: https://www.fileformat.info/format/rix/spec/
> +#
> +0	name	rix-header
> +>0	uleshort x \b, %u x
> +>2	uleshort x %u
> +# palette type:
> +# .. if direct color, low bits encode bpp
> +>4	ubyte&128 0
> +>>4 ubyte&127 x \b %u bpp (direct color)
> +# .. else palette
> +>4	ubyte&128 128
> +>>4 ubyte&7 0 \b x 2
> +>>4 ubyte&7 1 \b x 4
> +>>4 ubyte&7 2 \b x 8
> +>>4 ubyte&7 3 \b x 16
> +>>4 ubyte&7 4 \b x 32
> +>>4 ubyte&7 5 \b x 64
> +>>4 ubyte&7 6 \b x 128
> +>>4 ubyte&7 7 \b x 256
> +# storage type
> +#>5  ubyte&15 0 \b, Linear
> +>5  ubyte&15 1 \b, Planar (0213)
> +>5  ubyte&15 2 \b, Planar
> +>5  ubyte&15 3 \b, Text
> +>5  ubyte&15 4 \b, Planar lines
> +>5	ubyte&128 128 \b (compressed)
> +>5	ubyte&64 64 \b (extension)
> +>5	ubyte&32 32 \b (encrypted)
> +
> +0	string	RIX3	ColoRIX Image
> +>4 use rix-header
> +
> +0	string	RIX7	ColoRIX Slideshow
> --
> 2.34.1
> 
> --
> File mailing list
> File at astron.com
> https://mailman.astron.com/mailman/listinfo/file
> 
> 
> --
> This message has been 'sanitized'.  This means that potentially
> dangerous content has been rewritten or removed.  The following
> log describes which actions were taken.
> 
> Sanitizer (start="1680364691"):
>  Split unusually long word(s) in header.
>  SanitizeFile (filename="unnamed.txt", mimetype="text/plain"):
>    Match (names="unnamed.txt", rule="9"):
>      Enforced policy: accept
> 
>  Total modifications so far: 1
> 
> 
> Anomy 0.0.0 : Sanitizer.pm
> $Id: Sanitizer.pm,v 1.94 2006/01/02 16:43:10 bre Exp $

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 235 bytes
Desc: Message signed with OpenPGP
URL: <https://mailman.astron.com/pipermail/file/attachments/20230401/564e7fac/attachment.asc>


More information about the File mailing list