https://github.com/celsojr/cs-sdl2
CSharp bindings for SDL2 simple setup
https://github.com/celsojr/cs-sdl2
Last synced: 2 months ago
JSON representation
CSharp bindings for SDL2 simple setup
- Host: GitHub
- URL: https://github.com/celsojr/cs-sdl2
- Owner: celsojr
- Created: 2021-08-30T00:37:16.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2025-02-27T19:28:16.000Z (3 months ago)
- Last Synced: 2025-02-28T03:25:33.470Z (3 months ago)
- Language: C#
- Homepage:
- Size: 273 KB
- Stars: 0
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# Installing SDL2 and CSharp bindings
## Search all sdl2 libs
### Linux
```sh
apt-cache search libsdl2
```
### macOS
```sh
brew search SDL2
```
## Install the desired SDL libs
### Linux
```sh
apt install libsdl2-2.0-0
apt install libsdl2-image-2.0-0
```
### macOS
```sh
brew install SDL2
brew install SDL2_image# check
ls -l /opt/homebrew/lib/libSDL2.dylib# create a symbolic if needed
echo 'export DYLD_LIBRARY_PATH=/opt/homebrew/lib:$DYLD_LIBRARY_PATH' >> ~/.zshrc
```
## Download the c# files with the wrapper methods for SDL2
### wget
```sh
mkdir SDL
cd SDL
wget https://github.com/flibitijibibo/SDL2-CS/raw/master/src/SDL2.cs
wget https://github.com/flibitijibibo/SDL2-CS/raw/master/src/SDL2_image.cs
```
### curl
```sh
mkdir SDL
cd SDL
curl -LO https://github.com/flibitijibibo/SDL2-CS/raw/master/src/SDL2.cs
curl -LO https://github.com/flibitijibibo/SDL2-CS/raw/master/src/SDL2_image.cs
```