PSC Code Manual

shapes/line.lsp [src]

Line utility functions

Functions

Function signature Description
(line-int line1 line2 3d-p) return intersect of two lines, non-nil 3d-p includes Z value of 0
(line-off-pt line pt) returns a line in s-i form from offseting an s-i form line through a point
(line-offset line offset) returns a line in s-i form from offseting an s-i form line by some amount
(line-offset-dist line1 line2) return offset distance of two like-sloped s-i form lines
(line-point-@x line x) return point on line at dist x
(line-point-@y line y) return point on line at dist y
(line-val line x) return y-value of line at point x
(line-xval-@y line y) return x-value of line at point y
(line-yval-@x line x) return y-value of line at point x
(points->si-line pt1 pt2) returns a line in s-i form from input of a pair of 2D points
(pt-slope m x y) returns a line in slope-intercept format given the slope (m) and a point (x,y)

(line-int line1 line2 3d-p)

return intersect of two lines, non-nil 3d-p includes Z value of 0

(line-off-pt line pt)

returns a line in s-i form from offseting an s-i form line through a point

(line-offset line offset)

returns a line in s-i form from offseting an s-i form line by some amount

(line-offset-dist line1 line2)

return offset distance of two like-sloped s-i form lines

(line-point-@x line x)

return point on line at dist x

(line-point-@y line y)

return point on line at dist y

(line-val line x)

return y-value of line at point x

line-yval-@x is an alias for this function

(line-xval-@y line y)

return x-value of line at point y

(line-yval-@x line x)

return y-value of line at point x

alias for line-val

(points->si-line pt1 pt2)

returns a line in s-i form from input of a pair of 2D points

(pt-slope m x y)

returns a line in slope-intercept format given the slope (m) and a point (x,y)

CAR of returned list is slope CADR is y-intercept at X=0

VARS:
(M nil (NUMBERP M))
(X nil (NUMBERP X))
(Y nil (NUMBERP Y))