$darkmode
Suckless OGL 1.0.0
A lean, high-performance C11 PBR Renderer
material.h File Reference

PBR material definitions and management. More...

#include "gl_common.h"
#include <cglm/cglm.h>
Include dependency graph for material.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  PBRMaterial
 Surface properties for the physically-based rendering pipeline. More...
 
struct  MaterialLib
 A collection of material presets loaded from disk or defined at runtime. More...
 

Macros

#define MAX_MATERIAL_NAME_LENGTH   64
 Maximum length for a material identifier string. More...
 

Functions

MaterialLibmaterial_load_presets (const char *path)
 Loads a set of material presets from a configuration file. More...
 
void material_free_lib (MaterialLib *lib)
 Frees all memory associated with a material library. More...
 

Detailed Description

PBR material definitions and management.

Macro Definition Documentation

◆ MAX_MATERIAL_NAME_LENGTH

#define MAX_MATERIAL_NAME_LENGTH   64

Maximum length for a material identifier string.

Function Documentation

◆ material_free_lib()

void material_free_lib ( MaterialLib lib)

Frees all memory associated with a material library.

Parameters
libPointer to the library to destroy.

◆ material_load_presets()

MaterialLib* material_load_presets ( const char *  path)

Loads a set of material presets from a configuration file.

Parameters
pathPath to the material description file.
Returns
Pointer to the allocated library, or NULL on failure.
Here is the call graph for this function: