I'm searching a way to visualize very near vertices without having to zoom in and searching for them. It seems that if I'm far away from the model the mass of vertex is shown as one. Is there a convenient way to know that there are multiple vertices in one point even at large distance from the model? Maybe I'm missing a more convenient practice to clean mashes that have too many vertex, like merging by distance, but even so it could be useful to view vertices when there many. I'm using Blender 2.8.
-
1$\begingroup$ Maybe enabling the "statistics" option in "viewport overlays" might help. Sometimes this can help identify the number of vertices when some are overlapping. $\endgroup$– common_goldfishNov 30, 2021 at 15:42
2 Answers
Python script
when in edit mode, run this script - it will hide all vertices that don't have another vertex nearby.
import bpy, bmesh
from bpy import context as C
from collections import defaultdict
me = C.active_object.data
bm = bmesh.from_edit_mesh(me)
grid_subdivisions = 1000 # decrease for more tolerance - more vertices left visible
grid = defaultdict(list)
for v in bm.verts:
grid[tuple(map(round, v.co*grid_subdivisions))].append(v)
v.select = False
r = range(-1, 2)
offsets = [(x, y, z) for x in r for y in r for z in r if not x==y==z==0]
for (x, y, z), cell in grid.items():
if len(cell) == 1 and not any((x+a, y+b, z+c) in grid for a, b, c in offsets):
cell[0].select = True
bmesh.update_edit_mesh(me)
bpy.ops.mesh.hide()
-
$\begingroup$ Thank you, I think this answer better to my question. $\endgroup$– ro_orcoDec 1, 2021 at 8:30
-
$\begingroup$ I love this answer...although i don't understand the result with suzanne...and i created a plane to check like this: [1]: i.stack.imgur.com/Oghge.png and as you can see i moved the one vertex near the other...but if i try your code with that...no vertex is selected/unselected. So obviously i am doing something wrong? what's my mistake? what didn't i understand? $\endgroup$– ChrisDec 1, 2021 at 10:42
-
1$\begingroup$ @Chris The script multiplies each X,Y,Z of each vertex by
grid_subdivisions
, and then rounds them, to create a(x, y, z)
tuple denoting a grid cell to be used as a key in a dictionary. Without multiplying, in case of Susanne, you would only get 3 possible values for each axis:-1
,0
,1
, due to rounding. Then for each such cell in a grid, 26 surrounding grid cells are checked - if no such neighboring cell is found in the dictionary, it means there's no neighboring populated cells, and if also current cell has only one vertex, it's a sad, alone vertex - and is marked to be hidden. $\endgroup$ Dec 1, 2021 at 13:38 -
1$\begingroup$ @Chris so in your case perhaps the
grid_subdivisions
is too high, and grid cells are small enough that there is no vertex for which other vertices can be found in the same grid cell or no neighboring cell is "populated". $\endgroup$ Dec 1, 2021 at 13:39 -
1$\begingroup$ @MarkusvonBroady: Thank you very much for your detailed explanation. I am very happy that you don't answer "learn first the basics" like some others do that here. Thank you!! it worked!!!! $\endgroup$– ChrisDec 1, 2021 at 13:51
You can enable Scene Statistics (Preferences->Interface->Status Bar) and then do a circle select with a very small circle radius around the place which is likely to have multiple vertices. Then check in the status bar how many vertices are selected.
-
$\begingroup$ Stqtus Bar menu doesn't seems to be there in Blender 2.8 $\endgroup$– ro_orcoNov 30, 2021 at 16:19
-
$\begingroup$ In 2.8 the status bar is displayed by default if I am not mistaken. So no need to enable it. $\endgroup$– lomaNov 30, 2021 at 16:31
-
$\begingroup$ that's right, number of vertices are in the bottom of the screen $\endgroup$– ro_orcoNov 30, 2021 at 16:41