Commit graph

2292 commits

Author SHA1 Message Date
Sam Lantinga
44980b540d We don't need dlvsym() for ALSA anymore, yay!
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404066
2009-10-13 04:23:34 +00:00
Sam Lantinga
9e00bd18a7 Merged fix from SDL 1.3
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404065
2009-10-12 23:21:19 +00:00
Sam Lantinga
deaf4b7e93 Steven Noonan to sdl
While trying to build the SDLMain.m included with SDL 1.2.14, with
#define SDL_USE_NIB_FILE 1:

/Users/steven/Development/darwinia/targets/macosx/Darwinia/SDLMain.m:
In function '-[SDLMain fixMenu:withAppName:]':
/Users/steven/Development/darwinia/targets/macosx/Darwinia/SDLMain.m:122:
warning: 'sizeToFit' is deprecated (declared at
/Developer/SDKs/MacOSX10.6.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSMenu.h:281)
/Users/steven/Development/darwinia/targets/macosx/Darwinia/SDLMain.m:
In function 'main':
/Users/steven/Development/darwinia/targets/macosx/Darwinia/SDLMain.m:376:
warning: 'poseAsClass:' is deprecated (declared at
/Developer/SDKs/MacOSX10.6.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObject.h:127)
/Users/steven/Development/darwinia/targets/macosx/Darwinia/SDLMain.m:376:
error: 'poseAsClass:' is unavailable (declared at
/Developer/SDKs/MacOSX10.6.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObject.h:127)
/Users/steven/Development/darwinia/targets/macosx/Darwinia/SDLMain.m:377:
warning: passing argument 2 of 'NSApplicationMain' from incompatible
pointer type



Eric Wing to Sam

I don't have time today to look at this in detail, but the problem is definitely the poseAsClass: method.
This was deprecated in Obj-C 2.0 and not retained in 64-bit.

I've never used this method and it has always been limited to esoteric uses. I think this is why Apple wanted to dump it (among complicating some other things they do). I have read about others getting bit by this when migrating. Long story short, there really isn't a migration path for this method. The question that then must be asked is why are we using it (what does it accomplish), and then figure out the 'proper' way of accomplishing that.

Glancing at SDLMain.m, it's not obvious to me why it is there or what it is really accomplishing. My only speculation is that NSApplicationMain hardcodes something to look for NSApplication and a subclass (SDLApplication) fails for some reason (assuming that the original coder did this for good reason).

Three thoughts come to mind.
1) The Info.plist has properties to control things related to the startup class and nib.
NSPrincipalClass, NSMainNibFile

Maybe principle class needs to be SDLApplication and we can delete the poseAs

2) I was told that 10.6 introduced new APIs to make programatic NIB wrangling and avoidance easier. Unfortunately, I don't know the specifics.


3) Instead of subclassing NSApplication in SDLMain.m, maybe we can just add a category. It looks like the following is the only thing that is done (quick glance):

@interface SDLApplication : NSApplication
@end

@implementation SDLApplication
/* Invoked from the Quit menu item */
- (void)terminate:(id)sender
{
   /* Post a SDL_QUIT event */
   SDL_Event event;
   event.type = SDL_QUIT;
   SDL_PushEvent(&event);
}
@end


So instead, we change this to: (warning written in mail and untested)

@interface NSApplication (SDLApplication)
- (void) terminate:(id)sender;
@end

@implementation NSApplication (SDLApplication)
/* Invoked from the Quit menu item */
- (void)terminate:(id)sender
{
   /* Post a SDL_QUIT event */
   SDL_Event event;
   event.type = SDL_QUIT;
   SDL_PushEvent(&event);
}
@end


Then everywhere SDLApplication is used, we change it to NSApplication (and remove the poseAsClass line).

Perhaps you could ask the bug reporter to try this solution (#3).
And if that fails, maybe try #1.


-Eric


Steven Noonan to Sam

The suggested change (diff below) seems to work fine.

- Steven

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404064
2009-10-12 21:07:12 +00:00
Sam Lantinga
0e89501b8e Joystick patch from FreeBSD ports system
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404060
2009-10-12 09:32:55 +00:00
Ryan C. Gordon
d5b19efe79 Forcibly disabled MMX mixers.
Hopefully fixes Bugzilla #649.

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404059
2009-10-12 08:58:12 +00:00
Ryan C. Gordon
5409db51f6 Whoops, need to convert from bits to bytes for frame size.
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404057
2009-10-12 08:18:36 +00:00
Ryan C. Gordon
c865dbf891 Corrected misuse of snd_pcm_writei() in ALSA driver.
Hopefully fixes Bugzilla #650.

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404056
2009-10-12 08:06:40 +00:00
Sam Lantinga
56967065f7 Added support for SDL_VIDEO_FULLSCREEN_DISPLAY, but mouse events need to be fixed up.
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404043
2009-10-10 15:10:06 +00:00
Sam Lantinga
007680c438 Added SDL_VIDEO_FULLSCREEN_DISPLAY as a preferred synonym for SDL_VIDEO_FULLSCREEN_HEAD on X11.
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404042
2009-10-10 15:06:04 +00:00
Sam Lantinga
7d7dbf1910 Put the braces on the next line so vi can find the beginning of the function.
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404041
2009-10-10 14:59:32 +00:00
Patrice Mandin
83b57facc5 Disable double buffer for Milan. Also set current width,height after we read it.
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404038
2009-10-10 10:28:05 +00:00
Sam Lantinga
3b682483b5 Added missing caca files
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404037
2009-10-10 10:17:51 +00:00
Sam Lantinga
a1bececfc3 Fixed bug #838
Ozkan Sezer      2009-10-10 01:45:27 PDT

sdlenvvars.html doesn't list pulse among the supported values for
SDL_AUDIODRIVER var.  Attached a quick patch to remedy that, hopefully placing
the entry in the right order.  Regards.

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404036
2009-10-10 10:15:35 +00:00
Sam Lantinga
dc6913d2e1 Adapted from Debian patch: 320_activate_xrandr_on_default.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404035
2009-10-10 10:14:01 +00:00
Sam Lantinga
cb2bc4152c Debian patch: 310_segfault_noGLX.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404034
2009-10-10 10:10:36 +00:00
Sam Lantinga
17a7853ac1 Debian patch: f230_manpages.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404033
2009-10-10 10:09:01 +00:00
Sam Lantinga
826b5d2690 Debian patch: 218_joystick_memmove.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404031
2009-10-10 10:01:38 +00:00
Sam Lantinga
dd4a6eaa0d Debian patch: 216_page_size.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404030
2009-10-10 09:59:29 +00:00
Sam Lantinga
bca21936a4 Fixed bug #833
Fixed errors with older autoconf

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404029
2009-10-10 09:58:32 +00:00
Sam Lantinga
55cc565391 Don't double-include sys/param.h
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404026
2009-10-10 09:43:50 +00:00
Sam Lantinga
600685ad07 Whoops, FreeBSD 6.2 doesn't define __FreeBSD_kernel_version
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404025
2009-10-10 09:43:08 +00:00
Sam Lantinga
279116cdd6 Adapted from 215_kfreebsd_gnu.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404024
2009-10-10 09:38:02 +00:00
Sam Lantinga
8e0af4ac94 Debian patch: 214_missing_mmx_blit.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404022
2009-10-10 09:28:35 +00:00
Sam Lantinga
0d0229d870 Made typedef for SDL_bool the same as the other typedefs.
If this causes problems on any compiler, please report a bug to
http://bugzilla.libsdl.org/
and include the platform and version of compiler you're using.

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404020
2009-10-10 09:22:11 +00:00
Sam Lantinga
42b81dd3ee Added patch note for revision 5005
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404019
2009-10-10 09:21:09 +00:00
Sam Lantinga
c56bce7975 Debian patch: 209_alsa_priority.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404018
2009-10-10 09:07:51 +00:00
Sam Lantinga
87ffb1444e Debian patch: 050_altivec_detection.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404017
2009-10-10 09:03:08 +00:00
Sam Lantinga
2fd226c25c Changed environment variable to match Debian patch 205_lock_keys.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404016
2009-10-10 09:02:17 +00:00
Sam Lantinga
37ec7a4604 Disable iPodLinux code by default (can be enabled with --enable-ipod)
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404015
2009-10-10 08:59:28 +00:00
Sam Lantinga
69e01437c8 Debian patch: 040_propagate_pic_to_nasm.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404014
2009-10-10 08:56:01 +00:00
Sam Lantinga
de7e975cc7 Debian patch: 030_pulseaudio_enable.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404013
2009-10-10 08:50:35 +00:00
Sam Lantinga
650e3d941d Debian patch: 020_libcaca_new_api.diff
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404012
2009-10-10 08:46:06 +00:00
Sam Lantinga
e154913136 Updated change log with recent checkins
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404011
2009-10-10 08:11:36 +00:00
Sam Lantinga
467af3d4a9 Fixed bug #627
Increased accuracy of alpha blend calculation

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404008
2009-10-10 07:48:15 +00:00
Ryan C. Gordon
a716c9878f Moved to stable ALSA API.
This cleans up a few problems with our use of the ancient ALSA 0.9 API.

This means we can ditch the dlvsym() nonsense and use SDL_LoadFunction(), too.

 Fixes Bugzilla #745.

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404006
2009-10-10 07:33:18 +00:00
Sam Lantinga
b613ffc4f1 Fixed bug #634
If TranslateMessage() isn't done, then IME messages aren't generated.

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404005
2009-10-10 07:30:00 +00:00
Ryan C. Gordon
f0c110f75a Cache the swap control setting, even on Mesa.
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%404002
2009-10-10 06:38:02 +00:00
Ryan C. Gordon
f9ef094b34 Fixed incorrect return value test for SGI swap control.
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403999
2009-10-10 05:21:31 +00:00
Ryan C. Gordon
f9c9c5e9c5 Default value for SGI swap control GL attribute should be -1.
Explicitly try to set it if you want a different value. Different glX
 implementations appear to have different defaults for this, and you can't
 query them for the current value.

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403998
2009-10-10 05:17:47 +00:00
Sam Lantinga
259a72541e Fixed bug #798
kty@lavabit.com      2009-09-19 14:19:04 PDT

The stable release of SDL 1.2.13 for BeOS/Haiku has a bug in
BE_FindClosestFSMode that causes it to sometimes not select the best mode when
going fullscreen. There are in fact two bugs in the implementation but I will
not go into specifics because there is already a patch for it in the developer
SVN 1.3. However I am still reporting it because I believe the following code
is a better patch for the issue. The current implementation on SVN only works
if it is able to find an exact match for the requested mode. However, by
scanning from lowest-to-highest resolution instead of highest-to-lowest, one
can find the best mode at all times

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403997
2009-10-10 02:11:07 +00:00
Sam Lantinga
dbb19d2093 Fixed bug #831
Andrey      2009-10-09 08:08:04 PDT

gapi_hires_fix

I made a mistake with the conclusions.
And last time I as was mistaken with conclusions.
Now I thought about in more detail the algorithm works.
I have made it that the project fheroes2 well worked.
The result of my work in attachment.
I have a possibility to check up it on different models pocketpc.
I checked various modes screen of 320x320, 320x240, 640x480, 800x400.

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403996
2009-10-10 02:03:53 +00:00
Ryan C. Gordon
f8cb9e8845 Remove sdl.pc during "make uninstall"
Fixes Bugzilla #813 for the 1.2 branch.

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403991
2009-10-08 09:02:03 +00:00
Ryan C. Gordon
ef83107326 Allow Unicode filenames in RWOPS on Windows.
Fixes Bugzilla #733.

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403990
2009-10-08 07:48:37 +00:00
Sam Lantinga
f619466ff9 Ozkan Sezer 2009-04-01 23:17:13 PDT
This change should be applied to the 1.2 branch, too, because the svn version
SDL_net requires it.

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403989
2009-10-08 07:45:55 +00:00
Sam Lantinga
0cfa331d1a Update config.guess and config.sub
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403988
2009-10-08 07:09:04 +00:00
Sam Lantinga
0818c28108 SDL 1.2.14 is a recommended update.
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403985
2009-10-07 08:03:32 +00:00
Sam Lantinga
8329a0a1dd Updated documentation with major changes for 1.2.14
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403984
2009-10-07 08:00:20 +00:00
Sam Lantinga
70baaa8962 SuSE 11.1 installs directfb-config without directfb-devel, so check to
make sure the development headers are actually available!

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403982
2009-10-07 06:11:19 +00:00
Sam Lantinga
6ae47f142b Fixed building without OpenGL support
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403981
2009-10-07 06:10:40 +00:00
Sam Lantinga
b3e1d764b8 Updated libtool to version 2.2.6a
--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%403975
2009-10-04 22:31:25 +00:00