raspberrypi / pico-playground

BSD 3-Clause "New" or "Revised" License
438 stars 92 forks source link

Sprite_Demo #16

Open BambooEngineer opened 3 years ago

BambooEngineer commented 3 years ago

I know the floating head sprites are arrays of char hex but i cant find an image converter that seems to work. When i replace the original sprite hex with something i get from any converters i do find, nothing appears. Not even a few pixels ! Im not a great coder but i wanna display my own sprites atleast. I have been successful with changing everything but the sprite itself like speed, position, bg color

kilograham commented 3 years ago

@Wren6991 what did u use to create the data?

Wren6991 commented 3 years ago

With the packtiles script, also in this repo:

https://github.com/raspberrypi/pico-playground/blob/master/scanvideo/flash_stream/img/packtiles

E.g. packtiles -sdmf bgar5515 raspberry.png raspberry_bgar5515.h will convert a single image into the format expected by that sprite demo:

Wren6991 commented 3 years ago

You'll need python3 and PIL installed to run the script

BambooEngineer commented 3 years ago

Nice i will try it out, 8 bit kick made a bgar5515 converter that outputs on the java console but only a few lines of my image showed up. Like the image was a face and all i got on screen where the eyes.

BambooEngineer commented 3 years ago

the packtiles script launched and gave me data but it just did not work out on screen. I finally found a script that works created by boochow. Now i can use the example code from demo1 to do sprite movement.