Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/jeslie0/descartes

Haskell wrapper around Edinburgh University's descartes package.
https://github.com/jeslie0/descartes

descartes ffi haskell nix

Last synced: about 17 hours ago
JSON representation

Haskell wrapper around Edinburgh University's descartes package.

Awesome Lists containing this project

README

        

#+title: Descartes
#+author: James Leslie
[[https://img.shields.io/github/license/jeslie0/descartes.svg]] [[https://img.shields.io/github/v/release/jeslie0/descartes.svg]]
#+html:

This is a Haskell wrapper around The University of Edinburgh, School of Informatics' [[https://www.inf.ed.ac.uk/teaching/courses/cp/descartes.html][Descartes Package]]. The Descartes Packages is a small C library that uses [[https://www.libsdl.org/][SDL]] to make a very simple graphics package. It provides a way to make and render points, lines and rectangles on a 500px by 500px grid. It is mainly useful for educational purposes (indeed, I used it in the introductory "Computer Programming" course, back in 2014).

The main reason I made this library was to get a better understanding of Haskell's Foreign Function Interface with C, which turns out to be quite nice and very useable. As such, this repository may be of more use for someone wanting to explore Haskell's FFI functionality, rather than as an actual library.

Note - I only wrote the Haskell code and C wrapper code. Everything in [[file:cbits/descartes/][descartes]] directory is from the Descartes library.

* Dependencies
The only dependency is SDL. This has been tested with SDL version 1.2.15.

* Modifications
I made a few minor modifications to the Descartes C library. I changed the title of the graphics window to "Descartes".