Fixing DirectX code

I’ve been looking into the DirectX palette problem, and it looks like
it’s caused by Windows changing the palette when SDL doesn’t expect it.

I’m re-architecting the code so that it will automatically remap the
the blit if the colors or pixel format changes, but it’s a large
reorganization.

The good news is that SDL should be able to handle screen depth change
with the new modifications.

I’ll probably take most or all of next week to work out the changes
and thoroughly test them before putting them in a release.
The changes will be source-code compatible, but not binary compatible.

See ya!
-Sam Lantinga (slouken at devolution.com)–
Author of Simple DirectMedia Layer -
http://www.devolution.com/~slouken/SDL/

“Sam” == Sam Lantinga writes:

Sam> I've been looking into the DirectX palette problem, and it
Sam> looks like it's caused by Windows changing the palette when
Sam> SDL doesn't expect it.

Glad you found it.

Sam> I'm re-architecting the code so that it will automatically
Sam> remap the the blit if the colors or pixel format changes, but
Sam> it's a large reorganization.

Understood.

Sam> The good news is that SDL should be able to handle screen
Sam> depth change with the new modifications.

Yay. Of course that means there’s tons of testing to do after the
work is in place.

Sam> I'll probably take most or all of next week to work out the
Sam> changes and thoroughly test them before putting them in a
Sam> release.  The changes will be source-code compatible, but not
Sam> binary compatible.

? Why SC but not BC?

Sam> See ya!  -Sam Lantinga (slouken at devolution.com)

Sam> -- Author of Simple DirectMedia Layer -
Sam> http://www.devolution.com/~slouken/SDL/ --

–Cliff
@Clifford_T_Matthews

Sam> The good news is that SDL should be able to handle screen
Sam> depth change with the new modifications.

Yay. Of course that means there’s tons of testing to do after the
work is in place.

Indeed. :slight_smile:

Sam> I'll probably take most or all of next week to work out the
Sam> changes and thoroughly test them before putting them in a
Sam> release.  The changes will be source-code compatible, but not
Sam> binary compatible.

? Why SC but not BC?

The API wasn’t going to change, but the surface structure was.
Update: SDL_MapSurface() and SDL_UnmapSurface() are no longer needed,
so will be removed from the API. Surfaces are now automatically mapped
on blit.

See ya!
-Sam Lantinga (slouken at devolution.com)–
Author of Simple DirectMedia Layer -
http://www.devolution.com/~slouken/SDL/

“Sam” == Sam Lantinga writes:

Sam> The good news is that SDL should be able to handle screen
Sam> depth change with the new modifications.

>> Yay.  Of course that means there's *tons* of testing to do
>> after the work is in place.

Sam> Indeed. :)

Sam> I'll probably take most or all of next week to work out the
Sam> changes and thoroughly test them before putting them in a
Sam> release.  The changes will be source-code compatible, but not
Sam> binary compatible.

>> ? Why SC but not BC?

Sam> The API wasn't going to change, but the surface structure
Sam> was.  Update: SDL_MapSurface() and SDL_UnmapSurface() are no
Sam> longer needed, so will be removed from the API.  Surfaces are
Sam> now automatically mapped on blit.

This is all coming in under the wire before you do an ABI freeze, I
guess. Cool.

Sam> See ya!  -Sam Lantinga (slouken at devolution.com)

Sam> -- Author of Simple DirectMedia Layer -
Sam> http://www.devolution.com/~slouken/SDL/ --

I have the video card installed and after quite a battle I have all
the Windows drivers including DirectX 5.0 loaded. I haven’t been able
to get X to work on it yet but I haven’t tried too hard yet, either.

–Cliff
@Clifford_T_Matthews