Added Mir video target (thanks, Brandon!).

11.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 11.2 +++ b/src/video/mir/SDL_mirevents.h Sun Feb 02 23:41:46 2014 -0500 11.3 @@ -0,0 +1,36 @@ 11.4 +/* 11.5 + Simple DirectMedia Layer 11.6 + Copyright (C) 1997-2013 Sam Lantinga 11.7 + 11.8 + This software is provided 'as-is', without any express or implied 11.9 + warranty. In no event will the authors be held liable for any damages 11.10 + arising from the use of this software. 11.11 + 11.12 + Permission is granted to anyone to use this software for any purpose, 11.13 + including commercial applications, and to alter it and redistribute it 11.14 + freely, subject to the following restrictions: 11.15 + 11.16 + 1. The origin of this software must not be misrepresented; you must not 11.17 + claim that you wrote the original software. If you use this software 11.18 + in a product, an acknowledgment in the product documentation would be 11.19 + appreciated but is not required. 11.20 + 2. Altered source versions must be plainly marked as such, and must not be 11.21 + misrepresented as being the original software. 11.22 + 3. This notice may not be removed or altered from any source distribution. 11.23 +*/ 11.24 + 11.25 +/* 11.26 + Contributed by Brandon Schaefer, 11.27 +*/ 11.28 + 11.29 +#include "SDL_config.h" 11.30 + 11.31 +#ifndef _SDL_mirevents_h 11.32 +#define _SDL_mirevents_h 11.33 + 11.34 +#include 11.35 + 11.36 +extern void 11.37 +MIR_HandleInput(MirSurface* surface, MirEvent const* ev, void* context); 11.38 + 11.39 +#endif /* _SDL_mirevents_h */

13.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 13.2 +++ b/src/video/mir/SDL_mirframebuffer.h Sun Feb 02 23:41:46 2014 -0500 13.3 @@ -0,0 +1,46 @@ 13.4 +/* 13.5 + Simple DirectMedia Layer 13.6 + Copyright (C) 1997-2013 Sam Lantinga 13.7 + 13.8 + This software is provided 'as-is', without any express or implied 13.9 + warranty. In no event will the authors be held liable for any damages 13.10 + arising from the use of this software. 13.11 + 13.12 + Permission is granted to anyone to use this software for any purpose, 13.13 + including commercial applications, and to alter it and redistribute it 13.14 + freely, subject to the following restrictions: 13.15 + 13.16 + 1. The origin of this software must not be misrepresented; you must not 13.17 + claim that you wrote the original software. If you use this software 13.18 + in a product, an acknowledgment in the product documentation would be 13.19 + appreciated but is not required. 13.20 + 2. Altered source versions must be plainly marked as such, and must not be 13.21 + misrepresented as being the original software. 13.22 + 3. This notice may not be removed or altered from any source distribution. 13.23 +*/ 13.24 + 13.25 +/* 13.26 + Contributed by Brandon Schaefer, 13.27 +*/ 13.28 + 13.29 +#include "SDL_config.h" 13.30 + 13.31 +#ifndef _SDL_mirframebuffer_h 13.32 +#define _SDL_mirframebuffer_h 13.33 + 13.34 +#include "../SDL_sysvideo.h" 13.35 + 13.36 +#include "SDL_mirvideo.h" 13.37 + 13.38 +extern int 13.39 +MIR_CreateWindowFramebuffer(_THIS, SDL_Window* sdl_window, Uint32* format, 13.40 + void** pixels, int* pitch); 13.41 + 13.42 +extern int 13.43 +MIR_UpdateWindowFramebuffer(_THIS, SDL_Window* sdl_window, 13.44 + const SDL_Rect* rects, int numrects); 13.45 + 13.46 +extern void 13.47 +MIR_DestroyWindowFramebuffer(_THIS, SDL_Window* sdl_window); 13.48 + 13.49 +#endif /* _SDL_mirframebuffer_h */

15.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 15.2 +++ b/src/video/mir/SDL_mirmouse.h Sun Feb 02 23:41:46 2014 -0500 15.3 @@ -0,0 +1,37 @@ 15.4 +/* 15.5 + Simple DirectMedia Layer 15.6 + Copyright (C) 1997-2013 Sam Lantinga 15.7 + 15.8 + This software is provided 'as-is', without any express or implied 15.9 + warranty. In no event will the authors be held liable for any damages 15.10 + arising from the use of this software. 15.11 + 15.12 + Permission is granted to anyone to use this software for any purpose, 15.13 + including commercial applications, and to alter it and redistribute it 15.14 + freely, subject to the following restrictions: 15.15 + 15.16 + 1. The origin of this software must not be misrepresented; you must not 15.17 + claim that you wrote the original software. If you use this software 15.18 + in a product, an acknowledgment in the product documentation would be 15.19 + appreciated but is not required. 15.20 + 2. Altered source versions must be plainly marked as such, and must not be 15.21 + misrepresented as being the original software. 15.22 + 3. This notice may not be removed or altered from any source distribution. 15.23 +*/ 15.24 + 15.25 +/* 15.26 + Contributed by Brandon Schaefer, 15.27 +*/ 15.28 + 15.29 +#include "SDL_config.h" 15.30 + 15.31 +#ifndef _SDL_mirmouse_h 15.32 +#define _SDL_mirmouse_h 15.33 + 15.34 +extern void 15.35 +MIR_InitMouse(); 15.36 + 15.37 +extern void 15.38 +MIR_FiniMouse(); 15.39 + 15.40 +#endif /* _SDL_mirmouse_h */

17.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 17.2 +++ b/src/video/mir/SDL_miropengl.h Sun Feb 02 23:41:46 2014 -0500 17.3 @@ -0,0 +1,57 @@ 17.4 +/* 17.5 + Simple DirectMedia Layer 17.6 + Copyright (C) 1997-2013 Sam Lantinga 17.7 + 17.8 + This software is provided 'as-is', without any express or implied 17.9 + warranty. In no event will the authors be held liable for any damages 17.10 + arising from the use of this software. 17.11 + 17.12 + Permission is granted to anyone to use this software for any purpose, 17.13 + including commercial applications, and to alter it and redistribute it 17.14 + freely, subject to the following restrictions: 17.15 + 17.16 + 1. The origin of this software must not be misrepresented; you must not 17.17 + claim that you wrote the original software. If you use this software 17.18 + in a product, an acknowledgment in the product documentation would be 17.19 + appreciated but is not required. 17.20 + 2. Altered source versions must be plainly marked as such, and must not be 17.21 + misrepresented as being the original software. 17.22 + 3. This notice may not be removed or altered from any source distribution. 17.23 +*/ 17.24 + 17.25 +/* 17.26 + Contributed by Brandon Schaefer, 17.27 +*/ 17.28 + 17.29 +#include "SDL_config.h" 17.30 + 17.31 +#ifndef _SDL_miropengl_h 17.32 +#define _SDL_miropengl_h 17.33 + 17.34 +#include "SDL_mirwindow.h" 17.35 + 17.36 +#include "../SDL_egl_c.h" 17.37 + 17.38 +#define MIR_GL_DeleteContext SDL_EGL_DeleteContext 17.39 +#define MIR_GL_GetSwapInterval SDL_EGL_GetSwapInterval 17.40 +#define MIR_GL_SetSwapInterval SDL_EGL_SetSwapInterval 17.41 + 17.42 +extern void 17.43 +MIR_GL_SwapWindow(_THIS, SDL_Window* window); 17.44 + 17.45 +extern int 17.46 +MIR_GL_MakeCurrent(_THIS, SDL_Window* window, SDL_GLContext context); 17.47 + 17.48 +extern SDL_GLContext 17.49 +MIR_GL_CreateContext(_THIS, SDL_Window* window); 17.50 + 17.51 +extern int 17.52 +MIR_GL_LoadLibrary(_THIS, const char* path); 17.53 + 17.54 +extern void 17.55 +MIR_GL_UnloadLibrary(_THIS); 17.56 + 17.57 +extern void* 17.58 +MIR_GL_GetProcAddress(_THIS, const char* proc); 17.59 + 17.60 +#endif /* _SDL_miropengl_h */

19.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 19.2 +++ b/src/video/mir/SDL_mirvideo.h Sun Feb 02 23:41:46 2014 -0500 19.3 @@ -0,0 +1,40 @@ 19.4 +/* 19.5 + Simple DirectMedia Layer 19.6 + Copyright (C) 1997-2013 Sam Lantinga 19.7 + 19.8 + This software is provided 'as-is', without any express or implied 19.9 + warranty. In no event will the authors be held liable for any damages 19.10 + arising from the use of this software. 19.11 + 19.12 + Permission is granted to anyone to use this software for any purpose, 19.13 + including commercial applications, and to alter it and redistribute it 19.14 + freely, subject to the following restrictions: 19.15 + 19.16 + 1. The origin of this software must not be misrepresented; you must not 19.17 + claim that you wrote the original software. If you use this software 19.18 + in a product, an acknowledgment in the product documentation would be 19.19 + appreciated but is not required. 19.20 + 2. Altered source versions must be plainly marked as such, and must not be 19.21 + misrepresented as being the original software. 19.22 + 3. This notice may not be removed or altered from any source distribution. 19.23 +*/ 19.24 + 19.25 +/* 19.26 + Contributed by Brandon Schaefer, 19.27 +*/ 19.28 + 19.29 +#include "SDL_config.h" 19.30 + 19.31 +#ifndef _SDL_mirvideo_h_ 19.32 +#define _SDL_mirvideo_h_ 19.33 + 19.34 +#include 19.35 +#include 19.36 + 19.37 +typedef struct 19.38 +{ 19.39 + MirConnection* connection; 19.40 + 19.41 +} MIR_Data; 19.42 + 19.43 +#endif /* _SDL_mirvideo_h_ */