Tue, 02 Apr 2013 07:57:37 -0700Fixed bug 1780 - SDL_RWFromFile() sets an error on Android although a valid SDL_RWops pointer is returned.
Sam Lantinga <slouken@libsdl.org> [Tue, 02 Apr 2013 07:57:37 -0700] rev 7045
Fixed bug 1780 - SDL_RWFromFile() sets an error on Android although a valid SDL_RWops pointer is returned.

Philipp Wiesemann

SDL_RWFromFile() sets an error to be queried with SDL_GetError() on Android although a valid SDL_RWops pointer is returned.

This happens if the fallback implemented in SDL_android.cpp is used to load compressed assets (see README.android in section "Loading assets") and results in a message like "java.io.FileNotFoundException: This file can not be opened as a file descriptor; it is probably compressed". I think this is confusing and not needed because the loading works as expected.

I attached a patch which changes SDL_android.cpp to not set an error if compressed assets are loaded. In this case also no Exception is queried and no additional string are created.

Tue, 02 Apr 2013 07:55:25 -0700Fixed bug 1779 - SDL's Android project template has old default icons from Android.
Sam Lantinga <slouken@libsdl.org> [Tue, 02 Apr 2013 07:55:25 -0700] rev 7044
Fixed bug 1779 - SDL's Android project template has old default icons from Android.

Philipp Wiesemann

SDL's Android project template has old default icons from Android while iOS project template has custom icons with SDL's logo.

There is a Wizard in the Android Developer Tools to create "Android Icon Sets". As an example I created icons from the iOS loading screen and attached them in a ZIP archive. They are named "ic_launcher.png" instead of "icon.png" because that is the new name used in Android projects. To use them the AndroidManifest.xml needs to be changed to have "@drawable/ic_launcher" instead of "@drawable/icon". I do not know why there was no icon created for ldpi. Maybe it is deprecated.

Tue, 02 Apr 2013 07:51:23 -0700Fixed bug 1781 - SDL sets an error for the initial touch on Android.
Sam Lantinga <slouken@libsdl.org> [Tue, 02 Apr 2013 07:51:23 -0700] rev 7043
Fixed bug 1781 - SDL sets an error for the initial touch on Android.

Philipp Wiesemann

SDL sets an error to be queried with SDL_GetError() for the initial touch on Android.

Android_OnTouch() in SDL_androidtouch.c uses SDL_GetTouch() to check if a touch device was already added. SDL_GetTouch() sets the error "Unknown touch device" for an out of range access because touch devices are added after initial touch. I think this error is confusing because it always happens by design.

I attached a patch which removes the call to SDL_GetTouch() and only uses SDL_AddTouch() which does the check (if already added) again and does not set an error (if not added yet).

Mon, 01 Apr 2013 23:15:21 -0700Fixed bug 1782 - SDL_opengl.h header disabled on FreeBSD
Sam Lantinga <slouken@libsdl.org> [Mon, 01 Apr 2013 23:15:21 -0700] rev 7042
Fixed bug 1782 - SDL_opengl.h header disabled on FreeBSD

q66

The SDL_opengl.h header contains this:

#ifdef __FreeBSD__ /* !!! FIXME: temp compiler warning fix... */
#define NO_SDL_GLEXT 1
#endif

However, I can't seem to find what kind of compiler warning it was and it makes it unusable to use on FreeBSD. If I comment out these lines on my machine, everything works fine - I use FreeBSD 9-STABLE (x86_64, gcc and clang both, the same in a x86 chroot). All I could find is that this was causing an error on FreeBSD 8, but I can't test that on my machine (maybe if I set up some FreeBSD 8 chroot).

I set up a 8.2 chroot and investigated the problem. Apparently this issue was fixed in Mesa 7.6 (and in Git, June 4 2009, but it didn't get into 7.5). By the time those lines were added, FreeBSD contained the libGL port version 7.4.4, which suffered from the issue, but on April 2012 the version was updated to 7.6, which is available for FreeBSD 8 and FreeBSD 9 alike, which means those three lines should be safe to remove (it'll work fine for everyone with sufficiently up to date ports).

Mon, 01 Apr 2013 13:21:23 -0300Backed out changeset: a500a9dbfb41
Gabriel Jacobo <gabomdq@gmail.com> [Mon, 01 Apr 2013 13:21:23 -0300] rev 7041
Backed out changeset: a500a9dbfb41

Mon, 01 Apr 2013 13:21:08 -0300Backed out changeset: a713101e1d25
Gabriel Jacobo <gabomdq@gmail.com> [Mon, 01 Apr 2013 13:21:08 -0300] rev 7040
Backed out changeset: a713101e1d25

Mon, 01 Apr 2013 13:20:22 -0300Backed out changeset: 9cef1005df5f
Gabriel Jacobo <gabomdq@gmail.com> [Mon, 01 Apr 2013 13:20:22 -0300] rev 7039
Backed out changeset: 9cef1005df5f

Sun, 31 Mar 2013 13:05:40 -0400Changed audio subsystem's OpenDevice interface to return -1 on error.
Ryan C. Gordon <icculus@icculus.org> [Sun, 31 Mar 2013 13:05:40 -0400] rev 7038
Changed audio subsystem's OpenDevice interface to return -1 on error.

This lets us 'return SDL_SetError("whatever");' on one line.

Fixes Bugzilla #1778.

Sun, 31 Mar 2013 12:48:50 -0400Make SDL_SetError and friends unconditionally return -1.
Ryan C. Gordon <icculus@icculus.org> [Sun, 31 Mar 2013 12:48:50 -0400] rev 7037
Make SDL_SetError and friends unconditionally return -1.

This lets us change things like this...

if (Failed) {
SDL_SetError("We failed");
return -1;
}

...into this...

if (Failed) {
return SDL_SetError("We failed");
}


Fixes Bugzilla #1778.

Fri, 29 Mar 2013 21:29:57 -0400Corrected function signature on SDL_strtod_inline() (thanks, Axel!).
Ryan C. Gordon <icculus@icculus.org> [Fri, 29 Mar 2013 21:29:57 -0400] rev 7036
Corrected function signature on SDL_strtod_inline() (thanks, Axel!).

Fixes Bugzilla #1774.