whatisgithub

What is pyglfw?

rougier/pyglfw — explained in plain English

Analysis updated 2026-07-18 · repo last pushed 2019-12-02

40PythonAudience · developerComplexity · 2/5DormantSetup · easy

In one sentence

pyglfw is a Python wrapper around GLFW that handles window creation and keyboard/mouse input for graphics apps, so you can focus on drawing with OpenGL instead of platform windowing code.

Mindmap

mindmap
  root((pyglfw))
    What it does
      Window creation
      Mouse and keyboard input
      Wraps GLFW C library
    Tech Stack
      Python
      GLFW 3.0.1
    Use Cases
      Graphics demos
      Data visualization
      Game prototypes
    Audience
      Python developers
      Graphics hobbyists
      Visualization builders

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Open a window in Python and respond to keyboard and mouse events without writing platform-specific code.

USE CASE 2

Build a lightweight foundation for a 3D graphics demo or data visualization tool using OpenGL for drawing.

USE CASE 3

Prototype a simple game window and input loop in Python before adding a full game engine.

USE CASE 4

Use as a thin, low-overhead windowing layer instead of a heavier Python graphics framework.

What is it built with?

PythonGLFW

How does it compare?

rougier/pyglfwasimons81/hermes-dreamingbaskduf/harness-starter-kit
Stars404040
LanguagePythonPythonPython
Last pushed2019-12-02
MaintenanceDormant
Setup difficultyeasymoderateeasy
Complexity2/53/52/5
Audiencedeveloperdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · easy Time to first run · 30min

Community-maintained wrapper targeting GLFW 3.0.1, not an official GLFW release.

Copy-paste prompts

Prompt 1
Show me how to use pyglfw to open a Python window and print a message every time the user presses a key.
Prompt 2
Write a Python script using pyglfw that creates a window and draws a rotating triangle with OpenGL.
Prompt 3
How do I capture mouse movement and clicks in a pyglfw window using Python?
Prompt 4
Explain how pyglfw translates GLFW's C functions into Python calls for window and input handling.

Frequently asked questions

What is pyglfw?

pyglfw is a Python wrapper around GLFW that handles window creation and keyboard/mouse input for graphics apps, so you can focus on drawing with OpenGL instead of platform windowing code.

What language is pyglfw written in?

Mainly Python. The stack also includes Python, GLFW.

Is pyglfw actively maintained?

Dormant — no commits in 2+ years (last push 2019-12-02).

How hard is pyglfw to set up?

Setup difficulty is rated easy, with roughly 30min to a first successful run.

Who is pyglfw for?

Mainly developer.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.