Can someone please explain to me how I go about selecting edge loops in BMesh? I'm new to Blender scripting and am venturing into BMesh but I can not figure out how to actual select an edge loop. Let's say I'm starting with an edge. How then do I go about getting and selecting the edge loop that that edge is a part of? Please and thank you!
This is almost a duplicate of this question. Simply add the select statement at the end. I also branched the code sample to go in both directions of the first edge.
e = bm.edges
for loop in e.link_loops:
if len(loop.vert.link_edges) == 4:
e.select = True
while len(loop.vert.link_edges) == 4:
# jump between BMLoops to the next BMLoop we need
loop = loop.link_loop_prev.link_loop_radial_prev.link_loop_prev
# following edge in the edge loop
e_next = loop.edge
e_next.select = True