From: Kartik Thakore Date: Sun, 2 Aug 2009 14:37:56 +0000 (-0400) Subject: Merge branch 'patch' X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=1a54b647a438acdcbd5d6e86f2d2e159fa692a6c;hp=faad43be293c8de28169e2ee12ab99a881c50bf4;p=sdlgit%2FSDL_perl.git Merge branch 'patch' --- diff --git a/lib/SDL/App.pm b/lib/SDL/App.pm index f28eb03..42b4122 100644 --- a/lib/SDL/App.pm +++ b/lib/SDL/App.pm @@ -3,7 +3,8 @@ # The application object, sort of like a surface # # Copyright (C) 2000,2002,2003,2004 David J. Goehrig - +# Copyright (C) 2009 Kartik Thakore +# package SDL::App; use strict; @@ -26,10 +27,13 @@ sub new { -red_accum_size -ras -blue_accum_size -bas -green_accum_sizee -gas -alpha_accum_size -aas -double_buffer -db -buffer_size -bs -stencil_size -st - -asyncblit + -asyncblit -init / ) if ($SDL::DEBUG); - SDL::Init(SDL_INIT_EVERYTHING()); + # SDL_INIT_VIDEO() is 0, so check defined instead of truth. + my $init = defined $options{-init} ? $options{-init} : SDL_INIT_EVERYTHING(); + + SDL::Init($init); my $t = $options{-title} || $options{-t} || $0; my $it = $options{-icon_title} || $options{-it} || $t; diff --git a/src/OpenGL.xs b/src/OpenGL.xs index d027d10..5dddb06 100644 --- a/src/OpenGL.xs +++ b/src/OpenGL.xs @@ -670,6 +670,7 @@ glGet ( param ) case GL_MAX_ATTRIB_STACK_DEPTH: case GL_POLYGON_SMOOTH_HINT: case GL_ACCUM_GREEN_BITS: + case GL_MAX_TEXTURE_UNITS_ARB: { GLint ret[1]; int i; diff --git a/src/SDL.xs b/src/SDL.xs index 56e793b..b72fbba 100644 --- a/src/SDL.xs +++ b/src/SDL.xs @@ -2323,7 +2323,7 @@ JoyAxisEventValue ( e ) OUTPUT: RETVAL -Uint8 +Sint16 JoyButtonEventWhich ( e ) SDL_Event *e CODE: