That sounds great Andrew. Also, Chris's Paint Show Pro tip is really
good. Appreciated, fellas.
Lately I've been manipulating data directly in Excel, as the 16 palette
colours haven't been enough for a few ideas I've been working on. I
convert into XPM file format with Grafx2 to get the data in a text
format. Not a very clean dev pipe I'll admit!
Howard
On 20/10/2013 15:44, Andrew Gillen wrote:
I do similar, although I do all my graphics work in grafx2. Save them
out as 16 colour pngs and import into my own crap thing I wrote in
Delphi to parse through the RGB data, combine the nibbles and chuck
the image out a a load of DEFBs, line by line. It'll auto-create the
CLUT entries too if I need.
It even does weird and wonderful stuff like outputting graphics as
hard coded asm for sprite routines and such.
I guess I found that nothing off the shelf met my requirements so I
had to get my hands dirty.
Cheers
Andrew
----- Original Message ----- From: "Chris Pile"
<chris.p...@blueyonder.co.uk>
To: <sam-users@nvg.ntnu.no>
Sent: Sunday, October 20, 2013 2:44 PM
Subject: Re: Windows Tools for Sam
Hi Andy,
I've always used "Paint Shop Pro v7.04" - setting the "canvas" to
256x192 and 256 (byte per pixel) colour mode. Then make sure you
only use the first 16 palette entries (in Paint Shop Pro) when you
design your graphics. These 16 entries will then map directly to
the SAM's 16 palette colours.
When you come to save the image save it as filetype "RAW" and make
sure you set the "header" bytes to zero. This will spit out your
image as a simple byte-per-pixel, linear 256x192 block of data of
48k in size.
So, for example, if the first 5 pixels of your image used palette
entries 1, 12, 3, 9 and 15 the first 5 bytes of the RAW data block
you saved from PSP would look like (in HEX):
01 0C 03 09 0F ... and so on.
Then you can either write a simple PC program to take these bytes
and combine them to produce the required nybble-per-pixel layout of
the SAM, or you could "import" this block using SimCoupé and write
a simple SAM program to to this conversion. After conversion the
above example would look like (again, in HEX):
1C 39 Fx (where "x" would be whatever the 6th byte was in the RAW)
The disadvantage to this method is the palette information isn't
saved with the RAW image data. So you must hand-build the CLUT on
the SAM from whatever 16-colours you decided to use in Paint Shop
Pro. An extra step, but not too troublesome.
If you try this method be sure to find a version of Paint Shop Pro
that is <=7.04, as all version after that sucked big time!
Chris.
On 20/10/2013 10:35, Andrew Park wrote:
Hi
Does anyone know of any windows based tools to create graphics for
the sam? What i mean is you can draw the graphics in a windows based
environment then export the data to be used in assembly such as JAM
etc?
Andy