Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilipp Oeser <info@graphics-engineer.com>2020-12-30 17:25:13 +0300
committerPhilipp Oeser <info@graphics-engineer.com>2020-12-30 19:03:06 +0300
commit2be2165dd6478eff51291e2c173bd91f5d720c6d (patch)
tree14b35585535dadb33be5f493541f7ede3ac053a0 /source/blender/gpu
parentf910342c8d1f09a140d036b2d3583933cc126593 (diff)
Cleanup: Use LISTBASE_FOREACH macro
Differential Revision: https://developer.blender.org/D9960
Diffstat (limited to 'source/blender/gpu')
-rw-r--r--source/blender/gpu/intern/gpu_material.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/source/blender/gpu/intern/gpu_material.c b/source/blender/gpu/intern/gpu_material.c
index 3f22424c7c9..675036b31c3 100644
--- a/source/blender/gpu/intern/gpu_material.c
+++ b/source/blender/gpu/intern/gpu_material.c
@@ -803,14 +803,11 @@ void GPU_material_compile(GPUMaterial *mat)
void GPU_materials_free(Main *bmain)
{
- Material *ma;
- World *wo;
-
- for (ma = bmain->materials.first; ma; ma = ma->id.next) {
+ LISTBASE_FOREACH (Material *, ma, &bmain->materials) {
GPU_material_free(&ma->gpumaterial);
}
- for (wo = bmain->worlds.first; wo; wo = wo->id.next) {
+ LISTBASE_FOREACH (World *, wo, &bmain->worlds) {
GPU_material_free(&wo->gpumaterial);
}