Commit Graph

10030 Commits

Author SHA1 Message Date
David Ludwig 0903aa3f8d WinRT: added manual, app-setup instructions to the README
A number of other parts of the WinRT README were edited, either for clarity, or to help with Markdown rendering.
2014-09-14 11:36:24 -04:00
David Ludwig 11d865b8fc WinRT: added a note to README regarding need for a MS account 2014-09-14 10:31:18 -04:00
David Ludwig 4eef8bbc11 WinRT: cleaned up section headers 2014-09-14 10:29:54 -04:00
Alex Szpakowski 3071128deb Merged default into iOS-improvements 2014-09-10 18:10:37 -03:00
Sam Lantinga bf8ac8e798 DSCAPS_GL was added for DirectFB 1.6 2014-09-10 14:05:27 -07:00
Sam Lantinga 0e65e62367 Report the correct desktop video mode on the iMX6 2014-09-10 08:59:19 -07:00
mastermind 50cc4efec8 Freescale i.MX6 video driver
---
 CMakeLists.txt                  |   2 +
 cmake/sdlchecks.cmake           |  20 +++
 configure                       |  51 +++++++
 configure.in                    |  28 ++++
 include/SDL_config.h.cmake      |   1 +
 include/SDL_config.h.in         |   1 +
 src/video/SDL_sysvideo.h        |   3 +
 src/video/SDL_video.c           |   3 +
 src/video/mx6/SDL_mx6events.c   |  45 ++++++
 src/video/mx6/SDL_mx6events_c.h |  31 +++++
 src/video/mx6/SDL_mx6opengles.c | 211 ++++++++++++++++++++++++++++
 src/video/mx6/SDL_mx6opengles.h |  68 +++++++++
 src/video/mx6/SDL_mx6video.c    | 301 ++++++++++++++++++++++++++++++++++++++++
 src/video/mx6/SDL_mx6video.h    |  78 +++++++++++
 14 files changed, 843 insertions(+)
 create mode 100644 src/video/mx6/SDL_mx6events.c
 create mode 100644 src/video/mx6/SDL_mx6events_c.h
 create mode 100644 src/video/mx6/SDL_mx6opengles.c
 create mode 100644 src/video/mx6/SDL_mx6opengles.h
 create mode 100644 src/video/mx6/SDL_mx6video.c
 create mode 100644 src/video/mx6/SDL_mx6video.h
2014-09-10 08:54:01 -07:00
Ryo Munakata 7798b4d62a video: waylandmouse: handle mmap error properly
Signed-off-by: Ryo Munakata <ryomnktml@gmail.com>
2014-09-09 17:26:16 +09:00
Sam Lantinga 5f39ea89c9 Fixed bug 2415 - Message Boxes aren't implemented on Android
Philipp Wiesemann

I attached a patch for an incomplete implementation of the messagebox parts.

It was not tested on lots of devices yet and features a very fragile workaround to block the calling SDL thread while the dialog is handled on Android's UI thread. Although it works for testmessage.c I assume there are lot of situations were it may fail (standby, device rotation and other changes). Also not all flags and colors are implemented.

On the other hand most uses of the messagebox are to show an error on start and fragility (or working at all) may not matter there.
2014-09-13 02:15:18 -07:00
Sam Lantinga 2bfb3c3e82 Fixed using uninitialized display data in iMX6 initialization 2014-09-12 15:09:33 -07:00
Pierre-Loup A. Griffais 24c86b5501 [X11] Reconcile logical keyboard state with physical state on FocusIn
since the window system doesn't do it for us like other platforms.

This prevents sticky keys and missed keys when going in and out
of focus, for example Alt would appear to stick if switching away
from an SDL app with Alt-Tab and had to be pressed again.

CR: Sam
2014-09-11 19:24:42 -07:00
Ryan C. Gordon bcaae0b577 Deal with various .bmp file format variants in SDL_LoadBMP_RW().
This helps when modern versions of The Gimp (and lots of other things)
produces a 32-bit bitmap with an alpha channel, or anything with "BI_BITFIELDS"
format, since that data is now embedded in the bitmap info header instead of
directly following it and we would accidentally skip over embedded versions of
it.

Fixes Bugzilla #2714.
2014-09-08 01:36:22 -04:00
Philipp Wiesemann 0b98d0cb8a Fixed example in header file.
Did not compile because of typo in function name and missing argument.
2014-09-06 23:20:14 +02:00
Philipp Wiesemann c363bffa59 Changed version displayed in documentation generated by doxygen. 2014-09-04 22:59:32 +02:00
J?rgen Tjern? 782d590b77 Fix non-power-of-two shaped windows.
This fixes a bug where SDL_SetWindowShape would render artifacts if the image
was not a power of two image, due to rounding of width / 2.
2014-09-02 14:14:23 -07:00
Sam Lantinga 7242e81474 Updated version to 2.0.4 2014-09-02 06:55:47 -07:00
Ryan C. Gordon 724d24d990 Mac: Don't add the same joystick twice if IOKit reports a duplicate device.
Fixes Bugzilla #2704.
2014-08-31 11:21:10 -04:00
Philipp Wiesemann 7e515963a6 Corrected hint documentation. 2014-08-27 23:27:42 +02:00
Sam Lantinga 66a88c6c97 Fixed memory leak getting the X11 window title 2014-08-25 10:55:54 -07:00
Sam Lantinga 05cff7923c Fixed bug 2699 - possible memory leak in GL_RenderReadPixels
Benoit Pierre

If glReadPixels returns an error, than the temporary buffer is not deallocated
2014-08-24 00:02:12 -07:00
Sam Lantinga 9d54a90098 May have fixed the Linux build again 2014-08-23 19:06:54 -07:00
Sam Lantinga fe4bc5ab25 Fixed Linux build 2014-08-23 11:00:16 -07:00
Sam Lantinga 059579e48f Fixed bug 2696 - Mac: fix display mode refresh rate calculation
Alex Szpakowski

SDL's Cocoa backend uses the CGDisplayMode API to get refresh rate information about a display mode, but CGDisplayModeGetRefreshRate will return 0 on most non-CRT monitors.

The only way I know of to get correct refresh rate information in OS X is via the CoreVideo DisplayLink API.
I have attached a patch which tries to use the CVDisplayLinkGetNominalOutputVideoRefreshPeriod function if CGDisplayModeGetRefreshRate fails, which fixes display mode refresh rate information on the monitors I tested.

The CVDisplayLink API requires linking with the CoreVideo framework, and the patch updates the various build files to do so.
2014-08-23 10:47:50 -07:00
Ryan C. Gordon a79ed6cea2 Fix declaration-after-statement errors in ibus code. 2014-08-21 23:22:46 -04:00
Ryan C. Gordon 5e1f15892f Adjusted code style slightly for SDL_ibus.c 2014-08-21 23:15:17 -04:00
Ryan C. Gordon da4c3d54d6 Added note about libibus-1.0-dev to the Linux README. 2014-08-21 23:03:38 -04:00
Philipp Wiesemann 96d23f6a8f Fixed typos in test program. 2014-08-20 22:51:56 +02:00
Philipp Wiesemann aaefa6a855 Fixed not needed standard includes in test program. 2014-08-20 22:49:59 +02:00
Philipp Wiesemann ed5435034d Fixed warnings about unused value in test program. 2014-08-20 22:47:07 +02:00
Philipp Wiesemann a0cdcb0a8a Fixed warnings about unused functions in test program. 2014-08-20 22:44:15 +02:00
Philipp Wiesemann 005da280db Fixed warnings about missing initializers in test program. 2014-08-20 22:40:56 +02:00
Alex Szpakowski b1a0bd10a2 Merged default into iOS-improvements 2014-08-20 17:20:22 -03:00
Ryan C. Gordon 41728b3c6c Fixed the cmake-guided static analysis and use it by default.
The configure script fails on it on Mac OS X, now, for whatever reason.

Hopefully gets our static analysis buildslave running again!
2014-08-20 01:21:45 -04:00
Sam Lantinga 2d2f90200d Better check for __has_feature 2014-08-19 22:04:54 -07:00
Sam Lantinga 38b49c30e1 Changed the name of the IME hint to match the naming convention in SDL 2014-08-19 21:59:56 -07:00
Alex Baines 90bc642fa8 Add a SDL_IM_INTERNAL_EDITING event to make IMs like iBus render editing text in its own UI instead of sending TEXTEDITING events.
This is useful for applications that handle TEXTINPUT events but not TEXTEDITING events.
2014-08-19 23:31:50 +01:00
Alex Baines f4ddacf425 Improvements to the IBus related code:
+ Handle HidePreeditText IBus signal.
+ Use SDL_GetKeyboardFocus instead of SDL_GetFocusWindow.
+ Move the X11 IBus SetFocus calls to the X11_DispatchFocus functions.
+ Simplify the IBus ifdefs when handling X11 KeyEvents.
+ Remove inotify watch when SDL_IBus_Quit is called.
2014-08-19 23:17:28 +01:00
Alex Baines 6f84f37c0a Take the window border size into account when positioning the IBus candidate list. 2014-08-19 22:28:53 +01:00
Sam Lantinga eba65c66a3 Fixed bug 2694 - configure bug __has_feature macro not detected
skaller

using gcc 4.2 (the default) on Mac OSX 10.6.8

 CC     build/SDL_dynapi.lo
In file included from /Users/johnskaller/SDL/src/dynapi/SDL_dynapi.c:31:
include/SDL_syswm.h:211:39: error: missing binary operator before token "("

The fault appears to be here:

#if defined(__OBJC__) && __has_feature(objc_arc)

that the __has_feature macro is not supported by gcc 4.2.

The code works fine with my clang 3.3svn.
2014-08-19 21:17:21 -07:00
Sam Lantinga 04f7422552 Fixed bug 2691 - Disabling shared library prevent cmake configuration
hotgloupi

Configuring using "cmake -DSDL_STATIC=1 -DSDL_SHARED=0" generate and error in CMakeLists.txt at line 1334:

CMake Error at CMakeLists.txt:1334 (install):
  install TARGETS given target "SDL2" which does not exist in this directory.

This install rule shouldn't be present when the DLL has been disabled
2014-08-19 21:13:07 -07:00
Sam Lantinga 5a752c3aa7 Better Mac OS X build fix - actually match the SDK OpenGL headers. 2014-08-18 18:44:08 -07:00
Sam Lantinga 4b8f75381f Fixed Mac OS X build 2014-08-18 18:17:03 -07:00
Sam Lantinga bbab38552a SDL - fix fullscreen desktop windows not restoring to fullscreen state if focus changes happen due to programtic window changes (and not user alt-tabbing) 2014-08-18 18:16:45 -07:00
Sam Lantinga 877666e237 Fixed UV texture coordinate scale when using GL_ARB_texture_non_power_of_two 2014-08-18 11:28:16 -07:00
Ryan C. Gordon f4d3303c9e Don't use the system OpenGL headers, ever.
(the replacement header is from Mesa, under what the MIT license.)
2014-08-18 14:05:02 -04:00
Sam Lantinga d1cc47b337 Fixed 2680 - OSX: Replace NSAutoreleasePool with @autoreleasepool
Tim McDaniel

This patch replaces all use of NSAutoreleasePool with the Apple recommended @autoreleasepool.  @autoreleasepool is supposedly more efficient, and since it is scope based it can't be accidentally not released.
2014-08-17 15:07:00 -07:00
Sam Lantinga 5e50180415 Fixed bug 2655 - OSX: Window position and global mouse coord spaces are different
Tim McDaniel

On OSX, with revision 8729, the coordinate space for window position and the coordinate space for global mouse position don't match.  For a non-fullscreen window, the window position is global relative to the bottom of the menubar.  The global mouse position is relative to the top of the screen.  This affects Cocoa_WarpMouse and potentially other things as well.  Further, the coordinate system for window position is now affected by what screen it is on.  For example, if I have two equal size screens oriented side by side such that the tops of the screens are equal in global space, with the menubar on one screen, and a window straddles the two screens, the window's y position makes no sense.  The window's y position depends on what screen "most" of the window is on.  So if I move the window horizontally just a bit, the y position of my window is now different by the size of the menubar, even though the window was not moved vertically.

I'd like to reiterate that this was a fairly fundamental change (and a breaking change for us).  If SDL OSX is to really support multi-display configurations, this is especially problematic.

If the real concern is preventing windows from going under the menubar, then perhaps a solution involving something like overriding [NSWindow constrainFrameRect] would be less problematic than redefining the global window coord space for the main display.
2014-08-17 14:57:52 -07:00
Sam Lantinga de3d381cb6 Fixed bug 2685 - SDL_RenderReadPixels() doesn't work with offscreen targets
Andreas Falkenhahn

SDL_RenderReadPixels() doesn't seem to work when trying to read pixels from a texture that has been created using SDL_TEXTUREACCESS_TARGET and has been selected as the render target using SDL_SetRenderTarget().

I am attaching a small program that demonstrates the issue. I get the following result here:

READ PIXEL RETURN: 0 --- COLOR CHECK: ff000000

But it should be:

READ PIXEL RETURN: 0 --- COLOR CHECK: ffff0000

Tested with SDL 2.0.3 on Windows 7.
2014-08-17 14:44:53 -07:00
Sam Lantinga 2e3c778ef5 Fixed bug where the render target is updated instead of the default output when the window is resized. 2014-08-17 14:34:41 -07:00
Sam Lantinga f17587df4a Reset CMAKE_REQUIRED_FLAGS after test 2014-08-17 13:49:53 -07:00