Blender Git Loki

Git Commits -> Revision 93e26cb

Revision 93e26cb by Clément Foucault (master)
March 16, 2018, 07:50 (GMT)
DRW: Fix/refactor UBO & Texture binding.

Previous approach was not clear enough and caused problems.
UBOs were taking slots and not release them after a shading group even
if this UBO was only for this Shading Group (notably the nodetree ubo,
since we now share the same GPUShader for identical trees).

So I choose to have a better defined approach:
- Standard texture and ubo calls are assured to be valid for the shgrp
they are called from.
- (new) Persistent texture and ubo calls are assured to be valid accross
shgrps unless the shader changes.

The standards calls are still valids for the next shgrp but are not assured
to be so if this new shgrp binds a new texture.

This enables some optimisations by not adding redundant texture and ubo
binds.

Commit Details:

Full Hash: 93e26cb770ab052ce06f7a1248d636a068b45edf
Parent Commit: 43d0943
Lines Changed: +95, -41

5 Modified Paths:

/source/blender/draw/intern/draw_manager.c (+2, -2) (Diff)
/source/blender/draw/intern/draw_manager.h (+5, -3) (Diff)
/source/blender/draw/intern/draw_manager_data.c (+16, -2) (Diff)
/source/blender/draw/intern/draw_manager_exec.c (+70, -34) (Diff)
/source/blender/draw/intern/DRW_render.h (+2, -0) (Diff)
Tehnyt: Miika HämäläinenViimeksi päivitetty: 07.11.2014 14:18MiikaH:n Sivut a.k.a. MiikaHweb | 2003-2021