https://github.com/sealinesun/tsdl
Thin bindings to SDL for OCaml
https://github.com/sealinesun/tsdl
c ocaml
Last synced: 2 months ago
JSON representation
Thin bindings to SDL for OCaml
- Host: GitHub
- URL: https://github.com/sealinesun/tsdl
- Owner: sealinesun
- License: isc
- Created: 2022-05-25T19:31:16.000Z (about 4 years ago)
- Default Branch: analyse-49
- Last Pushed: 2022-05-25T19:33:12.000Z (about 4 years ago)
- Last Synced: 2025-05-24T12:42:45.964Z (about 1 year ago)
- Topics: c, ocaml
- Language: OCaml
- Homepage: http://erratique.ch/software/tsdl/
- Size: 469 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGES.md
- License: LICENSE.md
- Support: support/consts.ml
Awesome Lists containing this project
README
Tsdl — Thin bindings to SDL for OCaml
-------------------------------------------------------------------------------
%%VERSION%%
Tsdl is an OCaml library providing thin bindings to the cross-platform
SDL C library.
Tsdl depends on the [SDL 2.0.6][sdl] C library (or later),
[ocaml-ctypes][ctypes] and the `result` compatibility package.
Tsdl is distributed under the ISC license.
[sdl]: http://www.libsdl.org/
[ctypes]: https://github.com/ocamllabs/ocaml-ctypes
Home page: http://erratique.ch/software/tsdl
Contact: Daniel Bünzli ``
## Installation
Tsdl needs the C library SDL 2.0.6 or later installed on your
system. Tsdl can be installed with `opam`:
opam install tsdl
If you don't use `opam` consult the [`opam`](opam) file for
build instructions and a complete specification of the dependencies.
## Documentation
The documentation and API reference is automatically generated by
from the source interfaces. It can be consulted [online][online]
or via `odig doc tsdl`.
[online]: http://erratique.ch/software/tsdl/doc/
## Sample programs
Sample programs are located in the `test` directory of the
distribution. They can be built with:
./pkg/pkg.ml build --tests true
and listed with
./pkg/pkg.ml test --list
The resulting binaries are in `_build/test` :
- `test.native`, tests the bindings, the executable should exit
with 0.
- `sdlevents.native`, traces SDL events.
- `min.native` a minimal SDL example.