Changeset View
Changeset View
Standalone View
Standalone View
io_import_dxf/dxfimport/do.py
| Context not available. | |||||
| for j in range(1, nc): | for j in range(1, nc): | ||||
| j = j % en.ncount | j = j % en.ncount | ||||
| j_ = (j - 1) % en.ncount | j_ = (j - 1) % en.ncount | ||||
| face = [] | face = [ | ||||
| face.append(bm.verts.new(en.get_location((i_, j_)))) | bm.verts.new(en.get_location((i_, j_))), | ||||
| face.append(bm.verts.new(en.get_location((i, j_)))) | bm.verts.new(en.get_location((i, j_))), | ||||
| face.append(bm.verts.new(en.get_location((i, j)))) | bm.verts.new(en.get_location((i, j))), | ||||
| face.append(bm.verts.new(en.get_location((i_, j)))) | bm.verts.new(en.get_location((i_, j))) | ||||
| ] | |||||
| bm.faces.new(face) | bm.faces.new(face) | ||||
| Context not available. | |||||
| # creating bbox geometry | # creating bbox geometry | ||||
| bm = bmesh.new() | bm = bmesh.new() | ||||
| verts = [] | verts = [ | ||||
| # left side vertices | # left side vertices | ||||
| verts.append(bm.verts.new((xmin, ymin, zmin))) | bm.verts.new((xmin, ymin, zmin)), | ||||
| verts.append(bm.verts.new((xmin, ymin, zmax))) | bm.verts.new((xmin, ymin, zmax)), | ||||
| verts.append(bm.verts.new((xmin, ymax, zmax))) | bm.verts.new((xmin, ymax, zmax)), | ||||
| verts.append(bm.verts.new((xmin, ymax, zmin))) | bm.verts.new((xmin, ymax, zmin)), | ||||
| # right side vertices | # right side vertices | ||||
| verts.append(bm.verts.new((xmax, ymin, zmin))) | bm.verts.new((xmax, ymin, zmin)), | ||||
| verts.append(bm.verts.new((xmax, ymin, zmax))) | bm.verts.new((xmax, ymin, zmax)), | ||||
| verts.append(bm.verts.new((xmax, ymax, zmax))) | bm.verts.new((xmax, ymax, zmax)), | ||||
| verts.append(bm.verts.new((xmax, ymax, zmin))) | bm.verts.new((xmax, ymax, zmin)) | ||||
| ] | |||||
| # creating the widgets | # creating the widgets | ||||
| if do_widgets: | if do_widgets: | ||||
| Context not available. | |||||