aboutsummaryrefslogtreecommitdiff
path: root/src/library_sdl.js
AgeCommit message (Collapse)Author
2013-05-16fix test_sdl_alloctextAlon Zakai
2013-05-14* Switch to using offscren canvas for TTF size estimation in SDLJames Gregory
* use the actual font the user asked for.
2013-05-13use Browser mouse calculations in glutAlon Zakai
2013-05-13refactor mouse movement handling from SDL into BrowserAlon Zakai
2013-05-09misc sdl fixes to pull #1146Alon Zakai
2013-05-07* SDL_GL_ExtensionSupported: fixed integer valueMartin Gerhardy
* added myself to the AUTHORS file
2013-05-07* more SDL2 stuffMartin Gerhardy
2013-05-07* some SDL2 stuffMartin Gerhardy
2013-05-02fix SDL.keyboardState size to add safe buffer zoneAlon Zakai
2013-05-01unpress keys when losing focusAlon Zakai
2013-05-01preparation for key releasing when losing focus in SDLAlon Zakai
2013-03-30Support rotozoomSurfaceFelix H. Dahlke
2013-03-20fix indentationAlon Zakai
2013-03-19Make SDL handle the case where canvas backbuffer and canvas CSS element are ↵Vladimir Vukicevic
not the same size
2013-03-17optimize SDL.offsetsAlon Zakai
2013-03-17Fix offsets for canvasAleksander Guryanov
2013-03-12make sure SDL.channelMinimumNumber is initialized; fixes SDL audio testsAlon Zakai
2013-03-08Added test and fixed bugs exposed by the test.Michael Bishop
2013-03-08Add support for `Mix_ReserveChannels`Michael Bishop
2013-03-06Further improvement of the full screen support:Michael Riss
- SDL_WM_ToggleFullScreen now delivers correct return values, reflecting that for a SDL program it's impossible to switch to full screen mode in the browser environment Signed-off-by: Michael Riss <Michael.Riss@gmx.de>
2013-03-06- fixed formatting issuesMichael Riss
- bugfix: an existing pointerLockChange handler now gets properly removed before it is installed anew - completed the implementation of the SDL_ShowCursor() function: - can now query the current state of the cursor/pointer - properly delivers adequate return values - added safeguard: when not in fullscreen mode, attempts to lock the pointer are ignored as they would fail due to the security model of the browser and a return value indicating the error is returned Signed-off-by: Michael Riss <Michael.Riss@gmx.de>
2013-03-06Improved fullscreen functionality.Michael Riss
- the requestFullScreen function now has two boolean arguments: "doLockPointer" and "doResizeCanvas" - when using "doResizeCanvas", the SDL application gets notified via the "SDL_VIDEORESIZE" event of the new resolution, the old resolution setting is saved and gets restored when the canvas returns to windowed mode - when setting "doLockPointer" to false the mouse pointer remains visible in fullscreen mode and allows e.g. RTS (Real Time Strategy) type games - the SDL application can check via the "SDL_FULLSCREEN" flag in the flags field of the SDL_Surface struct whether the canvas is currently in fullscreen mode or not. - depending on the browser the SDL application can switch out of the fullscreen mode with the "SDL_WM_ToggleFullScreen(SDL_Surface*);" call (currently chrome supports it, firefox does not) - Also, the requestFullScreen has been fixed to avoid repeated adding of the event listeners every time requestFullScreen is called. - src/shell.html got changed to demonstrate all variants to switch to fullscreen mode Note: Due to the security model of web browsers, the SDL model cannot be fully supported. What is not possible? - Initiating the switch to fullscreen from the SDL application. - Initiating the pointer lock from the SDL application when *not* in fullscreen mode How to work around the limitations? All the actions that cannot be initiated by the SDL application have to be initiated by the web browser instead. A good practice should be to start the application in windowed mode and have a button situated close to the canvas which switches the canvas into fullscreen mode and also changes the canvas size to fullscreen resolution. This way, the SDL application receives a SDL_VIDEORESIZE event and can check in the even handler whether it is now in fullscreen mode and take further actions. When leaving fullscreen mode the old windowed canvas resolution gets restored and triggers another SDL_VIDEORESIZE event which - again - can be used to adapt the application to windowed mode. Signed-off-by: Michael Riss <Michael.Riss@gmx.de>
2013-03-05fix coding convention stuffAlon Zakai
2013-03-05Merge branch 'sd-audio' of github.com:michaeljbishop/emscripten into ↵Alon Zakai
michaeljbishop-sd-audio
2013-02-28simplify audio fix from last commitAlon Zakai
2013-02-28Make Mix_QuickLoad_RAW work againEhsan Akhgari
2013-02-27Implement SDL_TEXTINPUTEhsan Akhgari
2013-02-26return 0 in Mix_Init if no flags are provided; this allows ↵Alon Zakai
|while(Mix_Init(0)) Mix_Quit();| to work
2013-02-26Mix_QuitAlon Zakai
2013-02-22Changed formatting and fixed a bug in response to Kripken'sMichael J. Bishop
recommendations.
2013-02-22Added some SDL_Mixer calls:Michael J. Bishop
- `Mix_Playing` - `Mix_Pause` - `Mix_Pause` - `Mix_Resume`
2013-02-20Mix_InitAlon Zakai
2013-02-19Use the copy composite operation when calling drawImageEhsan Akhgari
This optimizes IMG_Load so that it just does a memcpy as opposed to try to composite. The resulting buffer will be the same, it just happens that we don't need to do all of the work involved in compositing in the first place.
2013-02-06option to not capture keyboard in SDLAlon Zakai
2013-01-29fix Mix_PlayChannel error return codes; fixes #805Alon Zakai
2013-01-24fix SDL_GetMouseState ; fixes #795Alon Zakai
2013-01-23sdl and gl error stubsAlon Zakai
2013-01-03fix sdl shutdown crashAlon Zakai
2013-01-02SDL mutex stubsAlon Zakai
2012-12-21merge incomingAlon Zakai
2012-12-20modify sdl error textAlon Zakai
2012-12-20SDL_SetGammaAlon Zakai
2012-12-14add some browser/sdl function signaturesAlon Zakai
2012-12-07dynCallAlon Zakai
2012-12-07TTF_CloseFontAlon Zakai
2012-12-07only use typed function tables in asm_js modeAlon Zakai
2012-11-12zoomSurface support; fixes #673Alon Zakai
2012-10-31warn in SDL_CreateThread about the problem with SDL threadsAlon Zakai
2012-10-29fix bug with locking an sdl surface not reading the canvas pixel data ↵Alon Zakai
properly; fixes #664
2012-10-29only fire sdl unload event if there is a main loopAlon Zakai