Skip to content

Commit fe20a1b

Browse files
author
Robert Kooima
committed
Added source links back into docs.
1 parent 4723eb0 commit fe20a1b

File tree

10 files changed

+38
-3
lines changed

10 files changed

+38
-3
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@
1818

1919
- [`noise`](noise.md) — Implements a 3D coherent noise generator using the Simplex method of Ken Perlin.
2020

21-
- [`plane`](plane.md) — Renders a simple 3D plane using OpenGL.Useful as a basic scene backdrop.
21+
- [`plane`](plane.md) — Renders a simple 3D plane using OpenGL. Useful as a basic scene backdrop.

cube.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,15 @@ This module renders the 3D reference cube using OpenGL. It is useful for testing
44

55
To better enable a concrete understanding of 3D transforms, a real-world instance of the 3D reference cube may be constructed from paper or cardstock [using this template PDF](cube.pdf).
66

7+
- [cube.c](cube.c)
8+
- [cube.h](cube.h)
9+
- [cubepx.png](cubepx.png)
10+
- [cubenx.png](cubenx.png)
11+
- [cubepy.png](cubepy.png)
12+
- [cubeny.png](cubeny.png)
13+
- [cubepz.png](cubepz.png)
14+
- [cubenz.png](cubenz.png)
15+
716
## Compilation
817

918
To use this module, simply link it with your own code. It requires OpenGL, [GLEW](http://glew.sourceforge.net/), and the [`image`](image.html#config) utility. To load the cube texture images, the `image` utility requires the PNG libraries.

demo.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22

33
This module implements a trivial framework for OpenGL demonstration. It is appropriate for the interactive presentation of rendering techniques and animations, but provides few facilities for mapping user input onto application control. A demo implementation using this module need only provide a function to perform rendering and, optionally, functions for setup, shutdown, and animation.
44

5+
- [demo.c](demo.c)
6+
- [demo.h](demo.h)
7+
58
The module maintains several pieces of internal state including the position, orientation, and zoom value of the camera, and the direction toward the primary light source. Upon rendering, the camera zoom is loaded into the OpenGL projection matrix, the position and orientation are loaded into the OpenGL model-view matrix, the primary light source direction is loaded into `GL_LIGHT0`, and the mouse pointer vector is loaded into `GL_LIGHT1`.
69

710
The demo module is implemented using [GLUT](http://www.opengl.org/resources/libraries/glut/), and applications are free to co-opt any GLUT features not used internally. Notably, this includes [GLUT's menu functions](http://www.opengl.org/resources/libraries/glut/spec3/node35.html#SECTION00070000000000000000), which applications may use for interactive feature selection and configuration.

glsl.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
# glsl
22

3-
This API consists of an extremely simple structure of OpenGL objects and a small set of functions that operate upon it. The structure contains a program object, vertex and fragment shader objects, and character pointers used to cache shader file names, if provided.
3+
This API consists of an extremely simple structure of OpenGL objects and a small set of functions that operate upon it.
4+
5+
- [glsl.c](glsl.c)
6+
- [glsl.h](glsl.h)
7+
8+
The structure contains a program object, vertex and fragment shader objects, and character pointers used to cache shader file names, if provided.
49

510
struct glsl
611
{

image.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22

33
This module implements a basic image I/O library supporting the reading and writing of PNG and JPEG images. It provides a uniform simplified front-end to [libpng](http://www.libpng.org/), [libtiff](http://www.remotesensing.org/libtiff/), [libjpeg](http://www.ijg.org/), and [OpenEXR](http://www.openexr.com/). Usable color depths and channel counts vary depending on format.
44

5+
- [image.c](image.c)
6+
- [image.h](image.h)
7+
58
## Compilation
69

710
To use this module, simply link it with your own code and the supporting libraries for all necessary image formats.

math3d.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ This module implements a right-handed 3D mathematics library supporting three-co
44

55
By default, `real` is `typedef`-ed to `double`. However, `float` is used instead if the preprocessor symbol `CONFIG_MATH3D_FLOAT` is defined during inclusion of `math3d.h` and compilation of `math3d.c`.
66

7+
- [math3d.c](math3d.c)
8+
- [math3d.h](math3d.h)
9+
710
Array layout is as follows. Note that the quaternion scalar part follows the vector part, allowing vector functions to operate upon the vector part of a quaternion. Also, the matrix representation is column-wise, matching the layout expected by OpenGL. Here, *a<sub><small>ij</small></sub>* is the element at row *i*, column *j*.
811

912
<table style="text-align:center;border:none">

noise.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22

33
This module implements a three-dimensional coherent noise generator using the Simplex method of Ken Perlin, as described in <a href="http://www.csee.umbc.edu/~olano/s2002c36/ch02.pdf"><i>Real-Time Shading SIGGRAPH Course Notes (2001)</i>, Chapter 2: Noise Hardware.</a> The output is deterministic, but infinite and non-repeating in all directions.
44

5+
- [noise.c](noise.c)
6+
- [noise.h](noise.h)
7+
58
## API
69

710
- `double noise_sample(double x, double y, double z)`

obj.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22

33
`obj` loads, manipulates, optimizes, renders, and stores 3D geometry using the Wavefront OBJ file format.
44

5+
- [obj.c](obj.c)
6+
- [obj.h](obj.h)
7+
58
An OBJ file consists of sets of *materials*, *vertices*, and *surfaces*. A surface consists of sets of *polygons* and *lines* with a reference to a material to be used when rendering them. A polygon is a triplet of references to vertices in the file, and a line is a pair of references to vertices.
69

710
OBJ files are referenced using pointers to type `obj`. The elements within the OBJ are referenced by integer index. These indices work much like a file or socket descriptor. The internal geometry representation is not accessible to the application. All operations on geometry are performed using the API documented here.

plane.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
# plane
22

3-
This modules a simple gridded plane using OpenGL. The look of it is patterned after the cover of Edward Tufte's [Visual Explanations](http://www.amazon.com/Visual-Explanations-Quantities-Evidence-Narrative/dp/0961392126). The plane is often useful as a backdrop to simple 3D demos, and can help work through those dreaded blank screen bugs. In addition, it represents an example of basic vertex buffer object creation, population, and rendering.
3+
This module is a very basic OpenGL code that renders a simple gridded plane as on the cover of Edward Tufte's [Visual Explanations](http://www.amazon.com/Visual-Explanations-Quantities-Evidence-Narrative/dp/0961392126). The plane is often useful as a backdrop to simple 3D demos, and can help work through those dreaded blank screen bugs. In addition, it represents an example of basic vertex buffer object creation, population, and rendering.
4+
5+
- [plane.c](plane.c)
6+
- [plane.h](plane.h)
47

58
## Compilation
69

type.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22

33
This module implements a mechanism for rendering text using OpenGL. This may be used to add GUI elements and labels in both 3D scenes and in 2D overlays.
44

5+
- [type.c](type.c)
6+
- [type.h](type.h)
7+
58
A `line` of text is drawn as a series of textured quads using a single `font`. Each quad appears as a single glyph. All quads in a `line` are stored in a single vertex buffer object, and all glyphs in a `font` are represented in a single texture.
69

710
Despite its name, one `line` may give many thousands of distinct textual elements, each with an independant 3D transformation. This mechanism enables the very efficient display of great quantities of text with only a single texture binding and a single vertex batch.

0 commit comments

Comments
 (0)