It was very confusing to have configure generate an SDL_config.h and then not have it be used when building on Mac OS X or Windows. I'll just have to remember to use SDL_config_windows.h when building official releases that are supposed to be ABI compatible with Visual Studio.
--HG--
rename : include/SDL_config_generated.h.in => include/SDL_config.h.in
Alex Nankervis 2012-01-15 14:20:01 PST
SDL_cocoawindow.m, windowDidResize needs to also send a window move event.
Depending on the corner you resize a window from, or when maximizing a window,
the window position will change. Discovered this when creating a maximized
window and found that the window position was stuck at the un-maximized
window's value.
Diff with fix attached.
Tim Angus to SDL
void function( SDL_Surface* surface )
{
SDL_Surface* anotherSurface =
SDL_ConvertSurfaceFormat( surface, ... );
// surface->map->dst is now equal to anotherSurface
// Do some stuff with anotherSurface
SDL_FreeSurface( anotherSurface );
// anotherSurface is now a dead pointer,
// but surface->map->dst still points to it
}
int main( )
{
SDL_Surface* surface = CreateAValidSurface( );
function( surface );
}
At this point blit something from surface. SDL_LowerBlit is called, which checks surface->map->dst against the blit destination. If the pointers happen to match (not that unlikely), the map is decided to be valid and bad things happen.
It seems to me like the whole idea of caching the blit mapping is fundamentally flawed in that the source surface has no knowledge of the lifetime of the destination surface.
Alex Nankervis 2012-01-15 11:19:45 PST
DirectX joysticks can enumerate their axis out of order. This results in some
joysticks having vertical/horizontal swapped, for example (vertical axis gets
assigned to axis0). Joysticks that I've tested with this problem: XBOX 360
controller, Logitech Extreme 3D Pro.
Attached is a diff that fixes this by sorting the DX joystick objects by their
data offsets into the DX data structs. This puts the joystick objects into a
standard ordering (X axis -> axis0, Y axis -> axis1, and so on).
bastien.bouclet@gmail.com 2011-06-26 02:15:36 PDT
SDL_Keyboard::focus does not seem to be reset when the window that has focus is
destroyed, resulting in the following crash :
#0 X11_SetWindowGammaRamp (_this=0x8ed9cb0, window=0x91f25c0, ramp=0x0) at
src/video/x11/SDL_x11window.c:948
#1 0x001bd15e in SDL_OnWindowFocusLost (window=0x91f25c0) at
src/video/SDL_video.c:1900
#2 0x00168a2e in SDL_SendWindowEvent (window=0x91f25c0, windowevent=<value
optimized out>, data1=0, data2=0)
at src/events/SDL_windowevents.c:157
#3 0x00166454 in SDL_SetKeyboardFocus (window=0x9678a08) at
src/events/SDL_keyboard.c:612
morgan.devel@gmail.com 2012-01-13 00:32:23 PST
The android version of SDL_SYS_JoystickUpdate doesn't check if there is
actually new data and always generate the SDL_JOYAXISMOTION event.
Consequently, doing a while(SDL_PollEvent()) will result in an endless loop.
The attached patch fix this issue.
It also scale the incoming values properly in the Sint16 range. The scale from
[-gravity;+gravity] is done directly in the java part because one may want to
map the sensor values with a non-linear method for example.
I'm playing with SDL on android, and did notice a problem in latest sources ( branch "default" ) :
SDL/src/render/opengles/SDL_glesfuncs.h:10: error: 'glDrawTexiOES' undeclared (first use in this function)
SDL/src/render/opengles/SDL_glesfuncs.h:10: error: (Each undeclared identifier is reported only once
If it can help you win some time here is the fix, applied to the "Android.mk" file :
LOCAL_CFLAGS += -D GL_GLEXT_PROTOTYPES
I think this fixes the bug. I'm not sure why it would fail, and it may have something to do with the version of OpenGL that we initialize and use by default. Regardless, this should take care of the problem.