Join us on Discord!
You can help CodeWalrus stay online by donating here.

Graphics and other system routines

Started by DarkestEx, October 19, 2015, 10:31:05 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

DarkestEx

#60
Quote from: DJ Omnimaga on November 24, 2015, 07:55:27 AM
So I am curious about what the following sprites would look like in Microcat format and how much space they would take:



Would the sprite sheet need to be split into multiple files and only one part loaded at a time?
Sure, I'll convert it for you.
About the size and if you have to split it, you can calculate that easily.
But first, what pixel format do you want to use? In this case I would either use 4bpp or preferably 8bpp.
To calculate the size of an image in bytes, simply do:
size = 20 + (2^bpp) - 1 + (width * height * bpp) / 8

(Only do the + (2^bpp) - 1 if you are using a bpp < 8 )

The maximum size of a sprite(sheet) is 32KB.

Edit: But to answer your question, no, you cannot load a sprite(sheet) this big at once. 32 KB max per sprite(sheet). I will in the future just refer to sprite as for the console / claw, a spritesheet and a single sprite are exactly the same thing.
There will be a draw sprite rectangle method to draw only a part of a sprite or spritesheet.
  • Calculators owned: TI-84+, Casio 101-S, RPN-Calc, Hewlett-Packard 100LX, Hewlett-Packard 95LX
  • Consoles, mobile devices and vintage computers owned: Original Commodore 64C, C64 DTV, Nintendo GameBoy Color, Nintendo GameCube, Xbox 360, PlayStation 2

Dream of Omnimaga

Thanks for the info. Not bad I guess, since I can split the spritesheet in rows :)
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

Powered by EzPortal