From 337a7ed292638542f702f1ce2119dc73072f0b56 Mon Sep 17 00:00:00 2001 From: Philipp Oeser Date: Thu, 9 Apr 2020 23:31:36 +0200 Subject: Pointclouds: fix point drawing The radius component is only one float. This resulted in only a third of intended points to draw and could lead to glitches. Pointcloud drawing will still change a lot in the future, this is just to be able to work on some simple tools. Differential Revision: https://developer.blender.org/D7390 --- source/blender/draw/intern/draw_cache_impl_pointcloud.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/blender/draw/intern/draw_cache_impl_pointcloud.c') diff --git a/source/blender/draw/intern/draw_cache_impl_pointcloud.c b/source/blender/draw/intern/draw_cache_impl_pointcloud.c index 83757cb714a..53939b35285 100644 --- a/source/blender/draw/intern/draw_cache_impl_pointcloud.c +++ b/source/blender/draw/intern/draw_cache_impl_pointcloud.c @@ -134,7 +134,7 @@ static void pointcloud_batch_cache_ensure_pos(Object *ob, PointCloudBatchCache * /* initialize vertex format */ pos_id = GPU_vertformat_attr_add(&format, "pointcloud_pos", GPU_COMP_F32, 3, GPU_FETCH_FLOAT); radius_id = GPU_vertformat_attr_add( - &format, "pointcloud_radius", GPU_COMP_F32, 3, GPU_FETCH_FLOAT); + &format, "pointcloud_radius", GPU_COMP_F32, 1, GPU_FETCH_FLOAT); } GPU_VERTBUF_DISCARD_SAFE(cache->pos); -- cgit v1.2.3