Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
 Welcome to our latest new user santa ! (Registered 2020-05-31) You are not logged in 
CSDb User Forums


Forums > C64 Pixeling > Seeking help on converting
2020-03-10 18:28
Stoker

Registered: Jul 2019
Posts: 5
Seeking help on converting

I have created mono pixel work on photoshop that I want to load as PRG file. The data will be used for sprites that only require a 16 pixel height.
If I use Spritead or CharPad the graphics get chopped up and require more work in program to sort order of pixels out.
Is there a way / program that can just convert Bitmap into simple data?
(hope I've explained this well enough)
Thanks in advance
 
... 4 posts hidden. Click here to view all posts....
 
2020-03-11 12:09
Isildur

Registered: Sep 2006
Posts: 248
SpritePad is perfect for this easy task.
Correctly cropped bitmap is the key.
Make sure your bitmap size is multiplication of 24x21.
Set background to black and pixels to white and import .bmp spritesheet to SpritePad. That's all.

Edit: bitmap must be 1 color only, so if it's not then use "Threshold" adjustment layer in Photoshop to make it 1 color.
2020-03-11 12:24
Stoker

Registered: Jul 2019
Posts: 5
Thank you Isildur, but what spritepad does, I'm trying to avoid.
Spritepad wants to take data and make sprites out of it, so after every 63rd byte an extra is added to make the sprites fit nice and orderly into 64 byte blocks.

What I'm after is a byte for byte copy of what I have, converted into a file that I can add to my DIR as a PRG file

The code in my game will pick parts of that data to paste into 24x21 sprite size, but each part is only 16 pixels tall, so I have opportunity to compact code. If saved through spritepad i have that extra 64th byte dotted around at random places (as far as 24x16 sections are concerned)

It's a tricky one I know, and thanks for everyone trying to find a solution
2020-03-11 14:32
cadaver

Registered: Feb 2002
Posts: 1130
I recommend grabbing your language and image loading libraries of choice and writing a custom utility. In a complex project it won't be the last one. Plus if you make it a commandline utility with no user interaction needed, it's easy to make a part of your automated build (makefiles or such)
2020-03-11 14:49
MagerValp

Registered: Dec 2001
Posts: 975
So basically what you're asking for is a 1 bpp uncompressed linear raw format converter, like what you'd use for Amiga graphics.

But I'd convert it to sprites with gaps and all and just let the cruncher deal with it. The custom code you'll write to unpack the sprites will probably be larger than what the cruncher spends on 16 byte padding.
2020-03-11 15:24
TheRyk

Registered: Mar 2009
Posts: 715
Quote:

I've tried Pixcen, but can't seem to save in recognisable formt for c64

With PixCen you can export in .kla and various other C64 graphics formats, if all you need is a an executable .prg displaying your stuff on a C64, that's a different story and hasn't got to do with conversion a lot.
2020-03-11 15:33
Frost

Registered: Jun 2009
Posts: 7
As far as i know, you can save as an executable .prg with PixCen. I've made executables of both multicolor and hires pictures for compos with it.
2020-03-11 23:36
Stoker

Registered: Jul 2019
Posts: 5
Thank you all for your replies and advice. As unfamiliar with anything but 6502, I wrote a little machine code routine in lieu of c/C+ that did the job perfectly.
Compacted sprites that load on the fly and lots of memory saved.
2020-03-12 18:30
Carrion

Registered: Feb 2009
Posts: 267
I wonder why my fellow BONZAIists haven't replied yet but it looks to me like what you need could be done with Bonzai PicConv V4.0
Or can it?
2020-03-12 21:49
Walt

Registered: May 2004
Posts: 14
Unfortunately PicConv cannot be used as he wants to use a custom format... I second the idea of using some script language to load the file and convert it to the required format...
2020-03-12 22:20
Stoker

Registered: Jul 2019
Posts: 5
Thank you Carrion.. a fantastic program, and will definitely come in handy for other requirements..
but, Yes, as Walt said my requirement was a bit more custom, but I managed to get what I was after with a little work around on photoshop and a little MC program.

Script language would have been perfect, I'll have to put my head down and learn that one day as I'm only familiar with 6502.

Thank you all, this has been a great help to my project and hope to have a completed game very soon
Previous - 1 | 2 - Next
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
Ozzy/Argus
Steel/SCS&TRC/G★P
phreedh/HmF
Jammer/TooMany
OSC
ΛΛdZ
Sentinel/Excess
Knight Rider/Excess
Scooby/G★P/Light
Guests online: 100
Top Demos
1 Coma Light 13  (9.7)
2 Edge of Disgrace  (9.7)
3 Comaland 100%  (9.7)
4 Uncensored  (9.7)
5 Unboxed  (9.6)
6 The Shores of Reflec..  (9.6)
7 Remains  (9.6)
8 NGC 1277 100%  (9.5)
9 Lunatico  (9.5)
10 C=Bit 18  (9.5)
Top onefile Demos
1 Dawnfall V1.1  (9.6)
2 Crystal Gazer  (9.6)
3 The Tuneful Eight [u..  (9.5)
4 Smile to the Sky  (9.5)
5 Instinct  (9.5)
6 Rewind  (9.5)
7 Bad Boy  (9.5)
8 Daah, Those Acid Pil..  (9.5)
9 Gumbo Revised  (9.4)
10 Tribute to Ben - Las..  (9.4)
Top Groups
1 PriorArt  (9.6)
2 Oxyron  (9.4)
3 Booze Design  (9.4)
4 Censor Design  (9.4)
5 Performers  (9.4)
Top Hardware-Gurus
1 Soci  (9.9)
2 Grue  (9.8)
3 Zer0-X  (9.8)
4 Wiesel  (9.8)
5 Lemming  (9.7)

Home - Disclaimer
Copyright © No Name 2001-2020
Page generated in: 0.038 sec.