@Matthieu_from_NAVINN wrote:
Hi,
I’ve got a huge issue with the latest Rhino releases: the result ofHiddenLineDrawing.Compute().segments
is not computed anymore, or rather the output is missing:HiddenLineDrawingSegment.parentcurve => nothing HiddenLineDrawingSegment.geometry => unsolved
It used to work perfectly with rhino 6 SR9, and it fails with SR14 or later releases. I also tried to force compilation with various rhinocommon versions, but it does not change the issue so Rhino itself has most probably something wrong.
Here is a more detailed sample of code, based on @dale exemple:
Dim HLDParam As New Rhino.Geometry.HiddenLineDrawingParameters HLDParam.AbsoluteTolerance = doc.ModelAbsoluteTolerance HLDParam.Flatten = True HLDParam.IncludeHiddenCurves = True HLDParam.IncludeTangentEdges = False HLDParam.IncludeTangentSeams = False HLDParam.AddClippingPlane(New Plane(Plane.WorldZX) With {.OriginY = Y}) For Each obj In doc.Objects HLDParam.AddGeometry(obj.Geometry, obj.Attributes) Next HLDParam.SetViewport(viewport) Dim HLD As HiddenLineDrawing = Rhino.Geometry.HiddenLineDrawing.Compute(HLDParam, False) If HLD Is Nothing Then Exit Sub For Each HLD_Segment As HiddenLineDrawingSegment In HLD.Segments Dim attr As ObjectAttributes = TryCast(HLD_Segment.ParentCurve.SourceObject.Tag, ObjectAttributes).duplicate Dim c As Curve = HLD_Segment.CurveGeometry.DuplicateCurve() ... Next
Posts: 1
Participants: 1