Skip to content

Instantly share code, notes, and snippets.



View GitHub Profile
Mimerme /
Created May 15, 2021
Triangle with SDL2-rs and gl-rs
use std::{
ffi::{c_void, CStr, CString},
mem, ptr,
use anyhow::Result;
use gl::types::{GLboolean, GLchar, GLenum, GLfloat, GLint, GLsizeiptr, GLuint};
use sdl2::{event::Event, sys::KeyCode};
static WIDTH: GLuint = 512;
View gist:3d36e3775db1b5a7b75aeccc376804ba
-- This library provide high level turtle movement functions.
-- Before being able to use them, you should start the GPS with egps.startGPS()
-- then get your current location with egps.setLocationFromGPS().
-- egps.forward(), egps.back(), egps.up(), egps.down(), egps.turnLeft(), egps.turnRight()
-- replace the standard turtle functions.
-- If you need to use the standard functions, you
-- should call egps.setLocationFromGPS() again before using any egps functions.
-- Gist at: