{"id":17209180,"url":"https://github.com/rswinkle/opengl_reference","last_synced_at":"2025-07-08T21:37:48.174Z","repository":{"id":146964887,"uuid":"52490664","full_name":"rswinkle/opengl_reference","owner":"rswinkle","description":"Collection of modern OpenGL programs for reference and frameworks","archived":false,"fork":false,"pushed_at":"2024-06-05T22:56:04.000Z","size":4411,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-05T10:34:23.446Z","etag":null,"topics":["3d-graphics","c","cpp","examples","graphics","graphics-library","opengl"],"latest_commit_sha":null,"homepage":"http://www.robertwinkler.com/projects/opengl_reference.html","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rswinkle.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"liberapay":"rswinkle","custom":"http://www.robertwinkler.com/donations.html"}},"created_at":"2016-02-25T02:29:33.000Z","updated_at":"2024-07-21T17:09:52.000Z","dependencies_parsed_at":"2024-06-02T07:24:23.597Z","dependency_job_id":"074afb17-a66d-4d46-ac67-9aa4ee2e75ee","html_url":"https://github.com/rswinkle/opengl_reference","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rswinkle%2Fopengl_reference","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rswinkle%2Fopengl_reference/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rswinkle%2Fopengl_reference/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rswinkle%2Fopengl_reference/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rswinkle","download_url":"https://codeload.github.com/rswinkle/opengl_reference/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248792163,"owners_count":21162327,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["3d-graphics","c","cpp","examples","graphics","graphics-library","opengl"],"created_at":"2024-10-15T02:50:58.152Z","updated_at":"2025-04-13T22:36:13.611Z","avatar_url":"https://github.com/rswinkle.png","language":"C++","readme":"opengl_reference\n================\n\nThis is going to be a repository of mostly modern (3.3/4.x) OpenGL programs.\nMost of these will be either exploring/demonstrating concepts, testing\nmy own OpenGL helper libraries, or be framework/template programs for\nstarting new projects.\n\nActually I've started using this repo to create small programs to test\nwhat is supposed to happen (assuming the drivers are obeying the spec\nwhich isn't always a safe assumption) for various situations to help\nme in developing PortableGL (and creating regression tests for it).\n\nI think I'll reorganize the src directory with subdirectories for tests\nand another for testing OpenGL ES behavior as well.  PortableGL, while\nmostly 3.x-ish already has some 4.x features and while I have always\nsaid it was targeting a core profile that wasn't strictly accurate.\nThere's no reason not to be more compatible and support OpenGL ES features\nas well where they make sense.\n\nThere are better repositories of modern OpenGL programs to\nuse for learning because they're more complete/organized,\nthey go with a book etc.  However, this is mostly for my own\npersonal use/code and will be constantly changing.  Writing\na bunch of OpenGL programs will also force me to learn glm\nand finish my own OpenGL math/helper code.\n\nDownload\n========\nGet the source from [Github](https://github.com/rswinkle/opengl_reference).\n\n\nThe table below lists only a handful of the programs in this repo.  Maybe\nI'll split them up by category (templates/frameworks, feature examples, demos, \"games\") later.\nThose listed use my own math library, rsw_math, but there are often glm versions as well, ie glm_modelviewer.cpp.\n\n| Program | Description | Image |\n| --- | --- | --- |\n| ex1.c | Hello Triangle                                            | ![ex1](https://raw.githubusercontent.com/rswinkle/opengl_reference/master/media/screenshots/ex_1.png) |\n| ex2.c | Hello Interpolation                                       | ![ex2](https://raw.githubusercontent.com/rswinkle/opengl_reference/master/media/screenshots/ex_2.png) |\n| gears.c | Classic gears demo.  Switch between polygon modes with p.  | ![gears](https://raw.githubusercontent.com/rswinkle/opengl_reference/master/media/screenshots/gears.png) |\n| modelviewer.cpp | Load a model from ./media/models.  Switch between Gouraud and Phong shading with s.  Switch between polygon modes with p. | ![ex3](https://raw.githubusercontent.com/rswinkle/opengl_reference/master/media/screenshots/ex_3.png) |\n| texturing.cpp | Switch between textures with 1, filtering modes with f, zoom/rotate with arrow keys | ![ex4](https://raw.githubusercontent.com/rswinkle/opengl_reference/master/media/screenshots/ex_4.png) |\n| grass.cpp | Based on example in superbible, uses flying controls, WIP | ![grass](https://raw.githubusercontent.com/rswinkle/opengl_reference/master/media/screenshots/grass.png) |\n| point_sprites.c | Point Sprite example, uses multitexturing and discard keyword in fragment shader to \"disolve\" textured point.  | ![point_sprites](https://raw.githubusercontent.com/rswinkle/opengl_reference/master/media/screenshots/point_sprites.png) |\n| sphereworld_color.cpp | Based on SphereWorld example from SB with ADS lighting, moving/rotating objects, with flying controls.  | ![sphere_world_color](https://raw.githubusercontent.com/rswinkle/opengl_reference/master/media/screenshots/sphereworld_color.png) |\n| flying.cpp | Template with 6DOF flying controls ala Descent. Mouse + WASDQE + LShift + Space | ![flying](https://raw.githubusercontent.com/rswinkle/opengl_reference/master/media/screenshots/flying.png) |\n| left_handed.cpp | [OpenGL *is* left handed](https://stackoverflow.com/questions/5168163/is-the-opengl-coordinate-system-right-handed-or-left-handed/22675164#22675164). | ![left_handed](https://raw.githubusercontent.com/rswinkle/opengl_reference/master/media/screenshots/left_handed.png) |\n","funding_links":["https://liberapay.com/rswinkle","http://www.robertwinkler.com/donations.html"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frswinkle%2Fopengl_reference","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frswinkle%2Fopengl_reference","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frswinkle%2Fopengl_reference/lists"}