Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add optional bindings for SDL2_gfx #22

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

RomainFranceschini
Copy link

The SDL2_gfx library provides the basic drawing functions such as circles or triangles against renderers of SDL2.

This PR adds optional bindings for SDL2_gfx and closes #20.
While the library provides support functions for other concerns (such as framerate control), only graphics related functions are binded in src/lib_gfx.cr.

src/gfx.cr defines 3 new shapes (Circle, Ellipse and Triangle) under SDL namespace and defines new drawing methods for SDL::Renderer.

I added the samples/gfx.cr example which showcase the new drawing methods.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Sdl_gfx
1 participant