Workbench: Remove warning

When in forward rendering and Object outline was disabled every render
call created one console warning (uniform objectId not found)

this commit removes this warning
This commit is contained in:
Jeroen Bakker 2018-06-21 15:15:41 +02:00
parent 8534ce9384
commit 526392ab16
1 changed files with 3 additions and 1 deletions

View File

@ -334,7 +334,9 @@ void workbench_forward_engine_init(WORKBENCH_Data *vedata)
psl->composite_pass = DRW_pass_create("Composite", state);
grp = DRW_shgroup_create(wpd->composite_sh, psl->composite_pass);
DRW_shgroup_uniform_texture_ref(grp, "objectId", &e_data.object_id_tx);
if (OBJECT_ID_PASS_ENABLED(wpd)) {
DRW_shgroup_uniform_texture_ref(grp, "objectId", &e_data.object_id_tx);
}
DRW_shgroup_uniform_texture_ref(grp, "transparentAccum", &e_data.transparent_accum_tx);
DRW_shgroup_uniform_texture_ref(grp, "transparentRevealage", &e_data.transparent_revealage_tx);
DRW_shgroup_uniform_block(grp, "world_block", wpd->world_ubo);