Newbie question
-
Hello,
a complete newbie here, please bear with me.So I am trying to find the intersection points between two co-planar Sketchup circles.
defined by:
C1 = [center1], [normal], radius1
C2 = [center2], [normal], radius2This is probably a bad solution but I've been trying to use the Geom::intersect_line_line for each pair of Edge components, somewhat like this:
T=C1.each{|j| C2.each {|k|Geom::intersect_line_line(j,k)}}
But i stumbled on another problem, which is, Geom::intersect_line_line only accepts Arrays(i'm trying to input Edge objects, also Edge arrays won't work).
And, whenever i use the .to_a method to any Edge object(including in the above code), this is what i get:
"(eval): warning: default `to_a' will be obsolete"Can anyone tell me what I have to do to make the Geom::intersect_line_line to work with Edges? Also is there a simpler solution to this that I'm missing?
-
Is the geometry of the circles in the same group/model space? Or is it separated by groups or components?
-
Because SketchUp's circles are in reality finely faceted polygons the real-intersection of two arcs' circumferences is unlikely to be exactly on those arcs' edges, unless by coincidence it turns out to be at one of the arc's edge's vertices.
Conversely the actual-intersection of those arcs' edges is unlikely to fall exactly on the arcs' circumferences, unless by coincidence it's at a vertex of those arcs' edges...My TrueTangent tools contain a number of algorithms to find circles/arcs' true tangents, true intersection points etc...
Perhaps these will help you find what you need...
Advertisement