Red/Blue colours swap when disabling Double Buffering in SDL Driver
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 14.1k
- Forks
- 2.2k
- Avg merge
- 7h 35m
- Merged PRs (30d)
- 51
Description
Description
When I disable Double Buffering in the SDL driver (by removing HW_DOUBLEBUF from SDL_SetVideoMode), the menu is fine but in-game colours on all cores are messed up. Seems like the Red and Blue channels get swapped over. I made this change to stop screen flickering on the platform I'm using, but it created this problem!
Expected behavior
No change to in-game colours.
Actual behavior
Reds become Blues and Blues become Reds.
Steps to reproduce the bug
I change SDL_SetVideoMode to this -
vid->screen = SDL_SetVideoMode(video->width, video->height, 32,
SDL_SWSURFACE | (video->fullscreen ? SDL_FULLSCREEN : 0));
Bisect Results
[Try to bisect and tell us when this started happening]
Version/Commit
You can find this information under Information/System Information
- RetroArch: [version/commit]
Environment information
- OS: [The operating system you're running]
- Compiler: [In case you are running local builds]
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Locate the SDL_SetVideoMode call in the SDL driver and compare the video surface format with the rendering path when HW_DOUBLEBUF is absent. Reproduce the reported configuration and verify that disabling double buffering leaves red and blue channels unchanged in-game.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100