Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GB graphic prefix bug #87

Closed
ghost opened this issue Jun 30, 2016 · 2 comments · Fixed by #88
Closed

GB graphic prefix bug #87

ghost opened this issue Jun 30, 2016 · 2 comments · Fixed by #88

Comments

@ghost
Copy link

ghost commented Jun 30, 2016

When you define a GB graphic constant, like DW `00133100 the resulting two bytes of planar data seem to get stored in the wrong order. It should store the least significant bits first and the most significant ones after them.

Currently DW `00133100 results in $18 $3C being stored instead of $3C $18.

Due to this bug, all pixels with ligh-gray or dark-gray shades get swapped.

@AntonioND
Copy link
Member

AntonioND commented Jun 30, 2016

I'll try to take a look at it this weekend, but at least I've looked for the location of the bug if someone wants to do it before: https://github.com/bentley/rgbds/blob/master/src/asm/globlex.c#L83

Probably just swapping the 2 bits in here could do the trick: https://github.com/bentley/rgbds/blob/master/src/asm/globlex.c#L100

@bentley
Copy link
Contributor

bentley commented Sep 5, 2016

@AntonioND fixed this in fbb825a.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants