gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

Coding > Accessing map tile data one byte at a time

#21125 - nath86 - Mon May 24, 2004 12:22 pm

Hey I found out the hard way that you can only access tile data 16bits at a time instead of 8. Is there a way around this? Its kinda annoying doing two pixels at a time instead of 1, because i have to check blah blah blah.

Thanks in advance

#21137 - Miked0801 - Mon May 24, 2004 6:36 pm

Sorry, VRAM Bus only allows 16/32-bit read/writes. Gotta deal with it...

#21148 - dagamer34 - Mon May 24, 2004 10:12 pm

nath86 wrote:
Hey I found out the hard way that you can only access tile data 16bits at a time instead of 8. Is there a way around this? Its kinda annoying doing two pixels at a time instead of 1, because i have to check blah blah blah.

Thanks in advance


Are you trying to plot a single pixel in mode 4? There is some code floating around on the boards that will allow you to do that. Just remember that it will be no where as fast as writing pixels in modes 3/5, so don't expect much. And its in asm by the way.

Just do a search for "mode 4 plot pixel" on the boards. It should come up with something.
_________________
Little kids and Playstation 2's don't mix. :(

#21172 - dXtr - Tue May 25, 2004 9:02 am

I rememberd solveing it with some nice bitshifting and bitmasking =)