🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.atari.st
Article #27986

GEM VDI image file format (Help needed)

#27986
From: hannu
Date: Wed, 19 Aug 1987 16:36
70 lines
2862 bytes
Hi there !

I downloaded two postscript conversion programs from uh-info@uhupvm1.
a) 1ST2PS, which converts 1STword -files to postscript

b) NMFPS, which converts .gem -files (gemDraw /easyDraw) to postscipt

Both worked quite nicely , no problems. Then i got an idea to make
cnversion- program for image (.img) -files ( for ex. GemPaint).
If you have the bit image, then conversion to postsrcipt in quite easy.
This can be done easily with for ex. DEGAS -files.The .img files are
not so easy. They are encoded ( file format appendixed)

But...   the testfile didn't look like it should have been (not at all)
I might be that  the file format has been changed (and I have an old version
manual). Does anyone know if file format is revised or if there are bugs
in manual

Hannu Koivisto        hannu@tut.fi      (internet style address)
	         ...!mcvax!tut!hannu    (old uucp -style)		
                    koivisto@fintuta.bitnet  (also via bitnet)

===================== bit image file (.img) format ========================

from: GEM Programmers Guide, VOL 1: VDI (old version?)

HEADER FORMAT	The bit image file header consists of sixteen WORDS (two
		bytes ?)

		Word 		   contents
		 0		upper left x of bit image
		 1		upper left y
		 2		lower right x
		 3		lower right y
		 4		source device page width
		 5		              page height
		 6		source device pixel widht in microns
		 7				    height
		 8		bits per pixel
		 9 - 16		reserved for future use (zero)
Rem! sixteen or seventeen words ??


DATA FORMAT	Pixel data may be encoded in any of four formats, which may
		occur within the same bit image file
		- run-length encoding (default)
		- extended run-length encoding
		- raster encoding
		- raster-run encoding

Run-length packet:	byte 0	run length   ( < 128 )
			byte 1  color index    < 256

Extended packet:        byte 0  opcode = -1
			byte 1  extended run length  ( ie. *128 pixels)
			byte 2  color index

Raster packet:		byte 0  opcode= -2
			byte 1  number of pixels in stream
			byte 2  packed color indices
			...               ( rem! bits/pixel )

Raster-run packet:	byte 0  opcode= -2
			byte 1  pattern repeat count
			byte 2  number of pixels in stream
			byte 3  packed color indices
			...
=============================================================================
-- 
mina se olen
Technical Details
Message-ID: <105@karhu.tut.FI>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!water!watmath!clyde!rutgers!seismo!mcvax!enea!tut!hannu

Show Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: arc1-ca.pugleaf.net!utzoo!utgpu!water!watmath!clyde!rutgers!seismo!mcvax!enea!tut!hannu
From: hannu@tut.UUCP
Newsgroups: comp.sys.atari.st
Subject: GEM VDI image file format (Help needed)
Message-ID: <105@karhu.tut.FI>
Date: Wed, 19-Aug-87 12:36:00 EDT
Article-I.D.: karhu.105
Posted: Wed Aug 19 12:36:00 1987
Date-Received: Sat, 22-Aug-87 09:03:38 EDT
Organization: Tampere University of Technology, Finland
Lines: 70