Skip to content

Instantly share code, notes, and snippets.

View Immanuel-C's full-sized avatar
🎯
Focusing

Immanuel Charles Immanuel-C

🎯
Focusing
  • Ontario, Canada
  • 01:57 (UTC -05:00)
View GitHub Profile
@jasonwhite
jasonwhite / joystick.c
Last active September 17, 2024 05:52
Reads joystick/gamepad events on Linux and displays them.
/**
* Author: Jason White
*
* Description:
* Reads joystick/gamepad events and displays them.
*
* Compile:
* gcc joystick.c -o joystick
*
* Run:
@nickrolfe
nickrolfe / windows_modern_opengl_context.c
Last active October 13, 2024 00:03
Sample code showing how to create a window using a modern OpenGL core profile context without any libraries other than the standard Win32 wglXXX calls.
// Sample code showing how to create a modern OpenGL window and rendering context on Win32.
#include <windows.h>
#include <gl/gl.h>
#include <stdbool.h>
typedef HGLRC WINAPI wglCreateContextAttribsARB_type(HDC hdc, HGLRC hShareContext,
const int *attribList);
wglCreateContextAttribsARB_type *wglCreateContextAttribsARB;