surf:basic-surface can only handle ideally oriented curves
Created by: reiniervandijk
The surf:basic-surface object produces weird results when curves are not oriented (from start to end) as expected. However, nowhere does the documentation mention constraints on orientations of curves... Reproduce with:
(define-object basic-surface-test2 (base-object)
:computed-slots
((display-controls (list :color :orange)))
:objects
((curve-bottom :type 'linear-curve :start #(0.0 0.0 0.0) :end (translate (the-child :start) :right 3))
(curve-right :type 'linear-curve :start (the curve-bottom :end) :end (translate (the-child :start) :front 2))
(curve-top :type 'linear-curve :start (the curve-right :end) :end (translate (the-child :start) :left 2))
;; (curve-left :type 'linear-curve :start (the curve-top :end) :end (the curve-bottom :start))
(3d-curve :type 'fitted-curve :points (list (the curve-top :end) (translate (the curve-top :end) :up 1) (the curve-bottom :start)))
(issue :type 'basic-surface
:pass-down (curve-bottom curve-right curve-top)
:curve-left (the 3d-curve))
(works :type 'basic-surface
:pass-down (curve-bottom curve-right curve-top)
:curve-left (the 3d-curve :reverse))
)
)
Imported comments:
By genworks on 2013-01-30 20:57:45 UTC
Would it be reasonable for the object to reverse curves automatically to achieve reasonable results, or should the documentation simply mention that curves should be in a consistent direction in order to achieve desired results?
By reiniervandijk on 2013-01-30 21:15:06 UTC
If you know the rules of how to orient curves in a way that the geometry kernel expects, I would be in favor of the object doing it automatically on behalf of user. As long as you did not implement it yet, consider adding this to documentation and provide intuitive error messages on failure.
By genworks on 2015-01-30 23:17:51 UTC
moved to internal tracking list.