fix: remove useless vars
This commit is contained in:
parent
d1ccfc40be
commit
c8b16c818e
5
main.py
5
main.py
|
@ -352,18 +352,15 @@ class MAPS(obja.Model):
|
||||||
for i in range(16):
|
for i in range(16):
|
||||||
selected_vertices = self.select_vertices() # find the set of vertices to remove
|
selected_vertices = self.select_vertices() # find the set of vertices to remove
|
||||||
|
|
||||||
faces_to_add, faces_to_remove = [], []
|
|
||||||
while len(selected_vertices) > 0:
|
while len(selected_vertices) > 0:
|
||||||
vertex = selected_vertices.pop(0) # get next vertex
|
vertex = selected_vertices.pop(0) # get next vertex
|
||||||
print(f" {len(selected_vertices)} ", end='\r')
|
print(f" {len(selected_vertices)} ", end='\r')
|
||||||
|
|
||||||
# Extract ring faces
|
# Extract ring faces
|
||||||
_, ring_faces = self.one_ring(vertex)
|
_, ring_faces = self.one_ring(vertex)
|
||||||
faces_to_remove += ring_faces
|
|
||||||
|
|
||||||
# Apply retriangulation algorithm
|
# Apply retriangulation algorithm
|
||||||
faces = self.clip_ear(vertex)
|
faces = self.clip_ear(vertex)
|
||||||
faces_to_add += faces
|
|
||||||
|
|
||||||
# Edit the first faces
|
# Edit the first faces
|
||||||
for i in range(len(faces)):
|
for i in range(len(faces)):
|
||||||
|
@ -381,7 +378,7 @@ class MAPS(obja.Model):
|
||||||
operations.append(('av', vertex, self.vertices[vertex]))
|
operations.append(('av', vertex, self.vertices[vertex]))
|
||||||
self.vertices[vertex] = None
|
self.vertices[vertex] = None
|
||||||
|
|
||||||
# REgister remaining vertices and faces
|
# Register remaining vertices and faces
|
||||||
for i, face in enumerate(self.faces):
|
for i, face in enumerate(self.faces):
|
||||||
if face != None:
|
if face != None:
|
||||||
operations.append(('af', i, face))
|
operations.append(('af', i, face))
|
||||||
|
|
Loading…
Reference in a new issue