src/video/xbios/SDL_xbios_centscreen.c
changeset 1061 5023cde12cbd
child 1064 fba6b67b4d60
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/src/video/xbios/SDL_xbios_centscreen.c	Wed May 18 17:02:17 2005 +0000
     1.3 @@ -0,0 +1,53 @@
     1.4 +/*
     1.5 +    SDL - Simple DirectMedia Layer
     1.6 +    Copyright (C) 1997-2004 Sam Lantinga
     1.7 +
     1.8 +    This library is free software; you can redistribute it and/or
     1.9 +    modify it under the terms of the GNU Library General Public
    1.10 +    License as published by the Free Software Foundation; either
    1.11 +    version 2 of the License, or (at your option) any later version.
    1.12 +
    1.13 +    This library is distributed in the hope that it will be useful,
    1.14 +    but WITHOUT ANY WARRANTY; without even the implied warranty of
    1.15 +    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
    1.16 +    Library General Public License for more details.
    1.17 +
    1.18 +    You should have received a copy of the GNU Library General Public
    1.19 +    License along with this library; if not, write to the Free
    1.20 +    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
    1.21 +
    1.22 +    Sam Lantinga
    1.23 +    slouken@libsdl.org
    1.24 +*/
    1.25 +
    1.26 +/*
    1.27 +	Centscreen extension definitions
    1.28 +
    1.29 +	Patrice Mandin
    1.30 +*/
    1.31 +
    1.32 +#include <stdlib.h>
    1.33 +
    1.34 +#include <mint/falcon.h>
    1.35 +
    1.36 +#include "SDL_xbios.h"
    1.37 +#include "SDL_xbios_centscreen.h"
    1.38 +
    1.39 +void SDL_XBIOS_CentscreenInit(_THIS)
    1.40 +{
    1.41 +	centscreen_mode_t	curmode;
    1.42 +
    1.43 +	/* Reset current mode list */
    1.44 +	if (XBIOS_modelist) {
    1.45 +		free(XBIOS_modelist);
    1.46 +		XBIOS_nummodes = 0;
    1.47 +		XBIOS_modelist = NULL;
    1.48 +	}
    1.49 +
    1.50 +	/* Add current active mode */
    1.51 +	Vread(&curmode);
    1.52 +
    1.53 +	SDL_XBIOS_AddMode(this, -1, curmode.physx, curmode.physy, curmode.plan,
    1.54 +		SDL_FALSE
    1.55 +	);
    1.56 +}