|
ForumsSega Master System / Mark III / Game GearSG-1000 / SC-3000 / SF-7000 / OMV |
Home - Forums - Games - Scans - Maps - Cheats - Credits Music - Videos - Development - Hacks - Translations - Homebrew |
Author | Message |
---|---|
|
Fast conversion to planar format, anyone?
Posted: Thu Jun 01, 2017 11:47 am
|
I was wondering what's the fastest method to convert 8 pixels colors to the planar format we need for the SMS.
I mean, source can be 8 bytes, 4 bytes, whatever actually, but output should be the 4 bytes we need to push to VRAM. Anyone? :) |
|
|
Posted: Thu Jun 01, 2017 2:21 pm |
I did this but can't find the code. Not sure if this is the fastest but from memory i did something like this.
- ld a, (hl), inc hl... running over input. - shift values in to b, c, d, e - when bcde are full write them to ram using stack. Use outd to compensate for reverse order. Was something like that. |
|
|
Posted: Thu Jun 01, 2017 2:49 pm |
oh, I see the point. thanks for the directions! :) | |
|
Posted: Thu Jun 01, 2017 2:59 pm |
I suppose you are talking about this post? :) http://www.smspower.org/forums/15469-ChunkyToPlanarOnSMS |
|