SampleProgram.py
import rhinoscriptsyntax as rs
import drawlatticehinge as lh
import math
def clear_all():
all_obs = rs.ObjectsByType(0)
rs.DeleteObjects(all_obs)
clear_all()
parameter = [37.5,0.2,0.4,1.5,10]
lattice = lh.LatticeHinge(parameter)
startPoint = (0,0,0)
endPoint = (200,200,0)
lattice.draw_lattice_follow_crosspoint(startPoint,endPoint)
parameter = [37.5,0.2,0.4,1.5,10]
LINE_LENGTH = parameter[0] #37.5#
LINE_WIDTH = parameter[1] #0.2#
OVERLAP_RATE = parameter[2] #0.4#
LINE_INTERVAL = parameter[3] #1.5#
INTERVAL_LIMIT = parameter[4] #10#
cutAngle = (math.radians(90),math.radians(90),math.radians(90),math.radians(90))
※comment LINE_LENGTH = length of one line LINE_WIDTH = width of one line (0.2mm because it is the cut width of the laser) OVERLAP_RATE = Overlapping line lengths LINE_INTERVAL = Line-to-line spacing INTERVAL_LIMIT = Lattice repeat count (this number determines the width and number of lattices)
Lattice Hinge was drawn between startPoint = (0,0,0) and endPoint = (200,200,0)
Recommended Posts