diff options
| author | Ray <raysan5@gmail.com> | 2019-09-22 21:47:19 +0200 |
|---|---|---|
| committer | Ray <raysan5@gmail.com> | 2019-09-22 21:47:19 +0200 |
| commit | bdcb16e7bbbc216ad70686047e7fa5fee4e70fd0 (patch) | |
| tree | fb19b799dc4ce372c14e1a3bca2faeb8154a2802 /examples/models/models_material_pbr.c | |
| parent | a679b0ccc015295ed8c305605b0bf19112f949f3 (diff) | |
| download | raylib-bdcb16e7bbbc216ad70686047e7fa5fee4e70fd0.tar.gz raylib-bdcb16e7bbbc216ad70686047e7fa5fee4e70fd0.zip | |
Review PR and comments
Diffstat (limited to 'examples/models/models_material_pbr.c')
| -rw-r--r-- | examples/models/models_material_pbr.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/examples/models/models_material_pbr.c b/examples/models/models_material_pbr.c index 2c0a15e3..0da74140 100644 --- a/examples/models/models_material_pbr.c +++ b/examples/models/models_material_pbr.c @@ -100,9 +100,8 @@ int main(void) // De-Initialization //-------------------------------------------------------------------------------------- - // user must unload shaders and textures as they could be in use - // by other models.... - UnloadShader(model.materials[0].shader); + // Shaders and textures must be unloaded by user, + // they could be in use by other models UnloadTexture(model.materials[0].maps[MAP_ALBEDO].texture); UnloadTexture(model.materials[0].maps[MAP_NORMAL].texture); UnloadTexture(model.materials[0].maps[MAP_METALNESS].texture); @@ -111,6 +110,7 @@ int main(void) UnloadTexture(model.materials[0].maps[MAP_IRRADIANCE].texture); UnloadTexture(model.materials[0].maps[MAP_PREFILTER].texture); UnloadTexture(model.materials[0].maps[MAP_BRDF].texture); + UnloadShader(model.materials[0].shader); UnloadModel(model); // Unload model |
