DEADSOFTWARE

add readme
[bb-sdl2-gl.git] / README
1 This repo contains bindings to SDL2, SDL2_image and modern OpenGL for BlackBox.
2 Windows version and Linux version switched using selectors OS:Win32 and
3 OS:Linux32.
7 SDL2 and SDL2_image bindings hand writed and not fully, but most functions
8 implemented.
9 About implementation:
10 - Prefixes SDL_ and IMG_ removed, prefix SDLK_ renamed to K_.
11 - Structures that can only be pointers(like struct Window) already binded as
12 pointers to limited records.
13 - C types binded as Int, Long, SizeT, Uint, Enum, STR and PtrSTR.
14 - SDL_bool renamed to Bool.
15 - Procedure GetClosestDisplayMode returns Int instead pointer(possibly to local
16 variable).
17 - Everywhere used IN-params, VAR-params when possibly and read-only fields in
18 accordance with documentation.
20 Module SDL2Lib / SDL2Image binds functions, types and consants.
21 Module SDL2Macro implements inline functions and macroses.
22 Module SDL2Test just a sample how to use SDL2 in BlackBox.
26 OpenGL bindings generated from gl.xml (fresh version can be founded there
27 https://github.com/KhronosGroup/OpenGL-Registry).
28 About implementation:
29 - Prefixes not removed.
30 - Call procedure SDL2GL.Init after context creation.
31 - Pointer prameters binded as VAR-params.
33 Module SDL2GL contains all constants, types and procedures.
34 Module SDL2GLGen is utility for binding generation. It <s>contains shitcode</s>
35 depends on subsystem Xmlcore(http://www.zinnamturm.eu/downloadsTZ.htm#Xmlcore).
39 Todo:
40 - Some c headers and macroses (see sources).
41 - Cpu-dependent procedures using [code].
42 - Test everything.
43 - Documentation.
44 - Samples.