Dear visitors and members, with the staff having moved on to other life interests and as a result of changes in people's internet usage habits, the CodeWalrus community have migrated almost entirely to Discord, IRC and WalrusIRC and is now essentially a place where to hang out, chat about gaming, programming, music, anime, and chill. As a result, even though the CW forums will remain open for posting, for faster TI, Casio or HP calculator help and news we recommend using the bilingual TI-Planet forums instead.

We encourage everyone to join our Discord server now.

### WalrusIRC

You need to have 5 posts and not be part of restricted usergroups in order to use the WalrusIRC embedded shoutbox. However, you can also access our IRC channel called #CodeWalrus via EFnet.

### Author Topic: Graphics and other system routines  (Read 13354 times)

0 Members and 1 Guest are viewing this topic.

#### DarkestEx

• Super User
• Join Date: Jan 2015
• Location: Germany
• Posts: 1327
• Post Rating Ratio: +10/-2
• Gender:
##### Re: Graphics and other system routines
« Reply #60 on: November 24, 2015, 08:30:05 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:
Code: [Select]
`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.
« Last Edit: November 24, 2015, 12:19:15 pm by DarkestEx »
• Calculators owned: TI-84+, Casio 101-S, RPN-Calc, Hewlett-Packard 100LX, Hewlett-Packard 95LX
• Consoles, mobile devices and vintage computers owned: Hewlett-Packard 100LX, Hewlett-Packard 95LX, Original Commodore 64C, Tektronix AWG2021, IBM X60s, IBM X60t, Nintendo DS Lite, Nintendo GameBoy Color, Nintendo GameCube, Xbox 360, Palm m5

#### xlibman

• Omni founder & CW co-founder
• CodeWalrus Staff
• Super User
• Forum Maintenance
• Original 5
• CodeWalrus Supporter
• Join Date: Nov 2014
• Location: Quebec, Canada
• Posts: 18973
• Post Rating Ratio: +100/-5
• Gender:
##### Re: Graphics and other system routines
« Reply #61 on: November 24, 2015, 02:31:24 pm »
Thanks for the info. Not bad I guess, since I can split the spritesheet in rows
• Calculators owned: TI-57, 73, TI-80 (broken), TI-81, TI-82, TI-83, TI-83+ (broken), TI-83+ (broken), TI-83+SE (broken), TI-84+, TI-84+CSE, TI-84+CE, TI-85, TI-86, TI-89T, TI-92, TI-Nspire, TI-Nspire CX (semi-broken), HP 39gII, HP Prime, Casio fx-7000G, fx-7400G+, fx-7700GE, fx-9750G+, fx-9750GII, fx-9860G, cfx-9850G, FX-1.0+, fx-CG10, fx-CP400
• Consoles, mobile devices and vintage computers owned: Samsung i5510, Nexus 5, Atari 2600, Lynx, SMS, Game Gear, Genesis, Dreamcast, NES, SNES, N64, GCN, Wii, Wii U, GBA, DS, 3DS, PS2, PS3, PS4, PSP, PSVita, XBox 360, XBOne