| Summary: | Mac OS Classic gamma ramp support... | ||
|---|---|---|---|
| Product: | SDL | Reporter: | Ryan C. Gordon <icculus> |
| Component: | video | Assignee: | Ryan C. Gordon <icculus> |
| Status: | RESOLVED FIXED | QA Contact: | Sam Lantinga <slouken> |
| Severity: | enhancement | ||
| Priority: | P1 | CC: | wolfy |
| Version: | HG 1.2 | ||
| Hardware: | PowerPC | ||
| OS: | Mac OS Classic | ||
| URL: | http://lists.libsdl.org/pipermail/sdl-libsdl.org/2007-June/061238.html | ||
| Attachments: |
Patch to support macrom gamma.
MacGamma code from ADC. Gamma ramp functions header from ADC. Updated patch. Updated patch for macrom AND macdsp... |
||
|
Description
Ryan C. Gordon
2007-06-02 21:59:58 UTC
Created attachment 207 [details]
Patch to support macrom gamma.
Patch to macrom.
--ryan.
Created attachment 208 [details]
MacGamma code from ADC.
Source code from Apple Developer Connection to provide gamma ramp API.
--ryan.
Created attachment 209 [details]
Gamma ramp functions header from ADC.
Header file from Apple Developer Connection for those gamma ramp APIs.
--ryan.
I'd really like to get the MacGamma.c code merged into src/video/macrom/SDL_romvideo.c so that we don't have to change the project files. --ryan. (Bumping to P1 so it gets considered for 1.2.12...) --ryan. Created attachment 210 [details]
Updated patch.
Merged this all into one patch, cleaned it up a little.
--ryan.
CC'ing Greg...I can't get SDL to build on Mac OS Classic at all to test the updated patch. Can you try it and let me know if it works? Thanks, --ryan. I haven't applied it, but reading it, it looks like your new patch doesn't add gamma support to DrawSprocket, only the toolbox video driver. If you don't mind having the MacGamma.c code duplicated in SDL_dspvideo and SDL_romvideo (that's why I had the file separate), I could see about a patch to both files that wouldn't require a new project file to be created. Created attachment 211 [details]
Updated patch for macrom AND macdsp...
Whoops, I missed that in the original patch. I've moved the gamma code to maccommon, so now the changes to macdsp and macrom are extremely minimal.
Attaching patch against latest Subversion.
--ryan.
OK I'm working on getting this to compile. For some reason I'm getting I'm getting undefined symbols for PBStatus, which is weird because MacGamma worked fine for me before. I'll let you know I had that problem on OS X (PBStatusSync() isn't in Carbonlib)...I don't know what library it's in for Classic. --ryan. Changing PBStatus(..., 0) to PBStatusAsync(...) fixed it. Compiled with the standard project file, and works great. I tweaked it from PBStatusAsync() to PBStatusSync(), since that '0' says we need it synchronously, and appears to solve the linking issue without risk of a race condition. This patch is now in source control, svn revision #3073 for the 1.2 branch (and isn't applicable to the 1.3 branch). When you get a moment, update to the latest in Subversion and make sure this still works. It should, so I'm resolving the bug, but just reopening it if I screwed something up. Thanks for the legwork on this one, Gregory! --ryan. |