-
Notifications
You must be signed in to change notification settings - Fork 55
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
Get DirectDraw backend to work with real hardware #842
base: vanilla
Are you sure you want to change the base?
Get DirectDraw backend to work with real hardware #842
Conversation
This seems to be actually related to some cards being unable to display the 640x400 mode. In that case we fallback ot a 640x480 resolution. Signed-off-by: Giuliano Belinassi <[email protected]>
Both DirectDraw and DirectSound backends works fine under Win9x. Signed-off-by: Giuliano Belinassi <[email protected]>
@@ -46,8 +46,19 @@ else() | |||
set(OPENAL TRUE) | |||
endif() | |||
|
|||
if(WIN32 AND WIN9X) | |||
if(SDL2) | |||
message("note: Use DSOUND or SDL1 for video support in Windows 9x.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
message("note: Use DSOUND or SDL1 for video support in Windows 9x.") | |
message("note: Use DDRAW or SDL1 for video support in Windows 9x.") |
/* giulianob: C&C runs by default in 640x400 resolution, which is | ||
by some videocards even back then. In failure to set the | ||
resulution, try to fallback into 640x480. */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/* giulianob: C&C runs by default in 640x400 resolution, which is | |
by some videocards even back then. In failure to set the | |
resulution, try to fallback into 640x480. */ | |
/* giulianob: C&C runs by default in 640x400 resolution, which isn't | |
supported by some video cards even back then. If it fails to set | |
the resolution, try to fall back to 640x480. */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the original code for 480 should be restored in InitDDraw, see original source repo
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This commit fixes the problem of DirectDraw failing to set the video mode because the card rejects 640x400 mode, as did my NVIDIA TNT2.
This also marks both DirectDraw and DirectSound backends as supported, as we now support Windows 9x and they work fine in those systems.