|
AGL
0
3D graphics library
|


Go to the source code of this file.
Namespaces | |
| agl | |
Macros | |
| #define | AGL_PI 3.141592653589793238462643383279502884197169399375105820974 |
| \(\pi\). What else? More... | |
Internal constants | |
These values are used by AGL internally while creating the GLFW window. | |
| #define | AGL_SAMPLE_SIZE 4 |
| Samples to take per pixel for anti-aliasing. More... | |
| #define | AGL_GLVERSION_MAJOR 3 |
| OpenGL major version. More... | |
| #define | AGL_GLVERSION_MINOR 3 |
| OpenGL minor version. More... | |
| #define | AGL_GLFW_INIT_ERROR 1 |
| Error if GLFW was not initialised. More... | |
| #define | AGL_GLFW_CREATE_WINDOW_ERROR 2 |
| Error if window was not created. More... | |
Types of shading | |
These values are used to define how entities will be shaded. These are currently unused. | |
| #define | AGL_POINTS 1 |
| Display each vertex as a point. More... | |
| #define | AGL_LINES 2 |
| Display each edge as a line. More... | |
| #define | AGL_TRIGS 4 |
| Display each face; this is default. More... | |
| #define | AGL_SHADING_FLAT 1 |
| Each face will be shaded with a single color. More... | |
| #define | AGL_SHADING_GOURAUD 2 |
| Each vertex will be shaded. More... | |
| #define | AGL_SHADING_PHONG 3 |
| Each point (fragment) will be shaded. More... | |
Special colors | |
These are constants for special colors for materials. | |
| #define | AGL_COLOR_POS2RGB -1 |
| Position based color. More... | |
| #define | AGL_COLOR_NORM2RGB -2 |
| Normal based color. More... | |
| #define | AGL_COLOR_CHECKER -3 |
| Checker board pattern. More... | |
Functions | |
| GLuint | loadShaders (std::string vertShader, std::string fragShader) |
| Load a pair of shaders. More... | |
| GLuint | loadShadersFromFile (const char *vsPath, const char *fsPath) |
| Load shaders from files. More... | |
| std::string | readTextFile (const char *path) |
| Reads a text file. More... | |
| void | saveImage (const char *path, int w, int h) |
| Save the current render as a ppm image. More... | |
| #define AGL_COLOR_CHECKER -3 |
Checker board pattern.
| #define AGL_COLOR_NORM2RGB -2 |
Normal based color.
| #define AGL_COLOR_POS2RGB -1 |
Position based color.
| #define AGL_GLFW_CREATE_WINDOW_ERROR 2 |
Error if window was not created.
| #define AGL_GLFW_INIT_ERROR 1 |
Error if GLFW was not initialised.
| #define AGL_GLVERSION_MAJOR 3 |
OpenGL major version.
| #define AGL_GLVERSION_MINOR 3 |
OpenGL minor version.
| #define AGL_LINES 2 |
Display each edge as a line.
| #define AGL_PI 3.141592653589793238462643383279502884197169399375105820974 |
\(\pi\). What else?
| #define AGL_POINTS 1 |
Display each vertex as a point.
| #define AGL_SAMPLE_SIZE 4 |
Samples to take per pixel for anti-aliasing.
| #define AGL_SHADING_FLAT 1 |
Each face will be shaded with a single color.
| #define AGL_SHADING_GOURAUD 2 |
Each vertex will be shaded.
| #define AGL_SHADING_PHONG 3 |
Each point (fragment) will be shaded.
| #define AGL_TRIGS 4 |
Display each face; this is default.