[Bf-blender-cvs] [9c7bd1fad90] blender2.8: Cleanup: simplify fix for T53497, this part is not strictly needed.
Brecht Van Lommel
noreply at git.blender.org
Wed Apr 4 12:28:32 CEST 2018
Commit: 9c7bd1fad902a8258aca83e4413e797036d017da
Author: Brecht Van Lommel
Date: Wed Apr 4 12:15:27 2018 +0200
Branches: blender2.8
https://developer.blender.org/rB9c7bd1fad902a8258aca83e4413e797036d017da
Cleanup: simplify fix for T53497, this part is not strictly needed.
===================================================================
M source/blender/draw/intern/draw_manager_data.c
===================================================================
diff --git a/source/blender/draw/intern/draw_manager_data.c b/source/blender/draw/intern/draw_manager_data.c
index 23e339bcd8f..b09e45e90f7 100644
--- a/source/blender/draw/intern/draw_manager_data.c
+++ b/source/blender/draw/intern/draw_manager_data.c
@@ -82,24 +82,7 @@ static void drw_shgroup_uniform_create_ex(DRWShadingGroup *shgroup, int loc,
uni->length = length;
uni->arraysize = arraysize;
- /* Insert into list sorted by location so that slots are consistenly assigned
- * for different draw calls, to avoid shader specialization/patching by the driver. */
- DRWUniform *next = shgroup->uniforms;
- DRWUniform *prev = NULL;
-
- while (next && loc > next->location) {
- prev = next;
- next = next->next;
- }
-
- if (prev) {
- prev->next = uni;
- }
- else {
- shgroup->uniforms = uni;
- }
-
- uni->next = next;
+ BLI_LINKS_PREPEND(shgroup->uniforms, uni);
}
static void drw_shgroup_builtin_uniform(
More information about the Bf-blender-cvs
mailing list