Merge branch 'sdl_android' of github.com:pelya/commandergenius into sdl_android

This commit is contained in:
Gerhard Stein
2013-11-25 15:04:58 +01:00
12 changed files with 1548 additions and 1553 deletions

View File

@@ -47,7 +47,7 @@ SwVideoMode=y
SdlVideoResize=y
# Application resizing will keep 4:3 aspect ratio, with black bars at sides (y)/(n)
SdlVideoResizeKeepAspect=n
SdlVideoResizeKeepAspect=y
CompatibilityHacksProperUsageOfSDL_UpdateRects=y

View File

@@ -26,7 +26,7 @@
----------------------------------------------------------*/
#define SCREEN_W 640
#define SCREEN_H 480
#define SCREEN_H 256
#define BALLS 300

View File

@@ -170,10 +170,10 @@ MultiABI=y
AppMinimumRAM=0
# Application version code (integer)
AppVersionCode=07003
AppVersionCode=07004
# Application user-visible version name (string)
AppVersionName="0.7.0.03"
AppVersionName="0.7.0.04"
# Reset SDL config when updating application to the new version (y) / (n)
ResetSdlConfigForThisVersion=n

File diff suppressed because it is too large Load Diff

View File

@@ -390,7 +390,14 @@ SDL_Surface *ANDROID_SetVideoMode(_THIS, SDL_Surface *current,
SDL_ANDROID_ForceClearScreenRectAmount = 0;
if( SDL_ANDROID_ScreenKeep43Ratio )
{
SDL_ANDROID_sWindowWidth = (SDL_ANDROID_sFakeWindowWidth * SDL_ANDROID_sRealWindowHeight) / SDL_ANDROID_sFakeWindowHeight;
if( (float)width / (float)height < (float)SDL_ANDROID_sWindowWidth / (float)SDL_ANDROID_sWindowHeight )
SDL_ANDROID_sWindowWidth = (SDL_ANDROID_sFakeWindowWidth * SDL_ANDROID_sRealWindowHeight) / SDL_ANDROID_sFakeWindowHeight;
else
// Force 4:3 ratio, with black borders at the left/right,
// this is needede for Uae4all2, which has 640x256 video mode,
// and expects those 256 pixels to stretch 2x height like on a TV interlaced display.
SDL_ANDROID_sWindowWidth = SDL_ANDROID_sWindowHeight * 4 / 3;
SDL_ANDROID_TouchscreenCalibrationWidth = SDL_ANDROID_sWindowWidth;
SDL_ANDROID_ForceClearScreenRectAmount = 2;
}