From b649fc13ed47a80e9b06b83cd76c6f9ab73154bc Mon Sep 17 00:00:00 2001 From: Hans Goudey Date: Tue, 23 Aug 2022 10:44:02 -0400 Subject: Cleanup: Avoid using invalid attribute domain The number of attribute domains isn't an attribute domain, so storing ATTR_DOMAIN_NUM in a variable with an eAttrDomain type isn't correct. In the cases it was used, the value wouldn't be accessed anyway. --- source/blender/gpu/intern/gpu_buffers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/blender/gpu/intern') diff --git a/source/blender/gpu/intern/gpu_buffers.c b/source/blender/gpu/intern/gpu_buffers.c index d64b8b4118a..8d9ae8e5257 100644 --- a/source/blender/gpu/intern/gpu_buffers.c +++ b/source/blender/gpu/intern/gpu_buffers.c @@ -1324,7 +1324,7 @@ bool GPU_pbvh_attribute_names_update(PBVHType pbvh_type, eAttrDomain active_color_domain = active_color_layer ? BKE_id_attribute_domain(&me_query.id, active_color_layer) : - ATTR_DOMAIN_NUM; + ATTR_DOMAIN_POINT; GPUAttrRef vcol_layers[MAX_GPU_ATTR]; int totlayer = gpu_pbvh_make_attr_offs(ATTR_DOMAIN_MASK_COLOR, -- cgit v1.2.3