mirror of
https://github.com/yawut/SDL.git
synced 2026-06-12 19:51:40 -05:00
SDL2 for the Nintendo Wii U (build with "cmake [SDL source path] -DCMAKE_TOOLCHAIN_FILE=$WUT_ROOT/share/wut.toolchain.cmake -DCMAKE_INSTALL_PREFIX=$DEVKITPRO/portlibs/wiiu")
From: Vassilis Virvilis <vasvir@iit.demokritos.gr>
Subject: [SDL] Request: Please reconsider adding tag in SDL_Event
Hi,
Patch in question:
--- include/SDL_events.h 20 Aug 2004 18:57:01 -0000 1.11
+++ include/SDL_events.h 19 Jan 2006 17:35:09 -0000
@@ -214,7 +214,7 @@
} SDL_SysWMEvent;
/* General event structure */
-typedef union {
+typedef union SDL_Event {
Uint8 type;
SDL_ActiveEvent active;
SDL_KeyboardEvent key;
Reasoning:
----------
1) Allows forward declaration of the SDL_Event union in C++. Please
note that in plain C it is possible to forward declare it.
2) Forward declaration is good because it allows encapsulation. It hides
the specific implementation and does not necessarily exposes SDL staff
to my appication's namespace
3) It can't harm plain C because tags are living in a different namespace
than typenames
4) It is already done like this in other places in SDL. Check for example
SDL_KeySym, and SDL_.*Event structures.
5) Right now I have to include SDL/event.h from a C++ header file. See 2)
|
||
|---|---|---|
| docs | ||
| include | ||
| src | ||
| test | ||
| .cvsignore | ||
| acinclude.m4 | ||
| autogen.sh | ||
| Borland.html | ||
| Borland.zip | ||
| BUGS | ||
| config.guess | ||
| config.sub | ||
| configure.in | ||
| COPYING | ||
| CREDITS | ||
| CWprojects.sea.bin | ||
| docs.html | ||
| EpocBuildFiles.zip | ||
| INSTALL | ||
| ltmain.sh | ||
| Makefile.am | ||
| Makefile.dc | ||
| MPWmake.sea.bin | ||
| PBProjects.tar.gz | ||
| README | ||
| README-SDL.txt | ||
| README.AmigaOS | ||
| README.CVS | ||
| README.DC | ||
| README.Epoc | ||
| README.MacOS | ||
| README.MacOSX | ||
| README.MiNT | ||
| README.NanoX | ||
| README.OS2 | ||
| README.PicoGUI | ||
| README.QNX | ||
| README.Qtopia | ||
| README.RISCOS | ||
| README.WinCE | ||
| README.wscons | ||
| sdl-config.in | ||
| sdl.m4 | ||
| SDL.qpg.in | ||
| SDL.spec.in | ||
| setvars.cmd | ||
| strip_fPIC.sh | ||
| TODO | ||
| VisualC.html | ||
| VisualC.zip | ||
| VisualCE.zip | ||
| Watcom.mif | ||
| WhatsNew | ||
Simple DirectMedia Layer
(SDL)
Version 1.2
---
http://www.libsdl.org/
This is the Simple DirectMedia Layer, a general API that provides low
level access to audio, keyboard, mouse, joystick, 3D hardware via OpenGL,
and 2D framebuffer across multiple platforms.
SDL is written in C, but works with C++ natively, and has bindings to
several other languages, including Ada, C#, Eiffel, Java, Lua, ML,
Objective C, Perl, PHP, Pike, Python, and Ruby.
The current version supports Linux, Windows, BeOS, MacOS, MacOS X,
FreeBSD, OpenBSD, BSD/OS, Solaris, IRIX, and QNX. The code contains
support for Windows CE, AmigaOS, Dreamcast, Atari, NetBSD, AIX, OSF/Tru64,
RISC OS, and SymbianOS, but these are not officially supported.
This library is distributed under GNU LGPL version 2, which can be
found in the file "COPYING". This license allows you to use SDL
freely in commercial programs as long as you link with the dynamic
library.
The best way to learn how to use SDL is to check out the header files in
the "include" subdirectory and the programs in the "test" subdirectory.
The header files and test programs are well commented and always up to date.
More documentation is available in HTML format in "./docs/index.html"
The test programs in the "test" subdirectory are in the public domain.
Frequently asked questions are answered online:
http://www.libsdl.org/faq.php
If you need help with the library, or just want to discuss SDL related
issues, you can join the developers mailing list:
http://www.libsdl.org/mailing-list.php
Enjoy!
Sam Lantinga (slouken@libsdl.org)