Skip to content

Commit 6777bb3

Browse files
committed
remove duplicates
1 parent 6f8bd17 commit 6777bb3

File tree

2 files changed

+0
-88
lines changed

2 files changed

+0
-88
lines changed

src/compas_occ/geometry/curves/nurbs.py

Lines changed: 0 additions & 78 deletions
Original file line numberDiff line numberDiff line change
@@ -526,23 +526,6 @@ def is_rational(self):
526526
# Methods
527527
# ==============================================================================
528528

529-
def copy(self):
530-
"""Make an independent copy of the current curve.
531-
532-
Returns
533-
-------
534-
:class:`OCCNurbsCurve`
535-
An independent copy of the curve.
536-
"""
537-
return OCCNurbsCurve.from_parameters(
538-
self.points,
539-
self.weights,
540-
self.knots,
541-
self.multiplicities,
542-
self.degree,
543-
self.is_periodic
544-
)
545-
546529
def transform(self, T):
547530
"""Transform this curve.
548531
@@ -558,71 +541,10 @@ def transform(self, T):
558541
occ_T.SetValues(* T.list)
559542
self.occ_curve.Transform(occ_T)
560543

561-
def transformed(self, T):
562-
"""Transform a copy of the curve.
563-
564-
Parameters
565-
----------
566-
T : :class:`compas.geometry.Transformation`
567-
568-
Returns
569-
-------
570-
:class:`OCCNurbsCurve`
571-
A transformed copy of the curve.
572-
"""
573-
copy = self.copy()
574-
copy.transform(T)
575-
return copy
576-
577544
def reverse(self):
578545
"""Reverse the parametrisation of the curve."""
579546
self.occ_curve.Reverse()
580547

581-
def space(self, n=10):
582-
"""Compute evenly spaced parameters over the curve domain.
583-
584-
Parameters
585-
----------
586-
n : int, optional
587-
The number of values in the parameter space.
588-
589-
Returns
590-
-------
591-
List[:obj:`float`]
592-
"""
593-
u, v = self.domain
594-
return linspace(u, v, n)
595-
596-
def xyz(self, n=10):
597-
"""Compute point locations corresponding to evenly spaced parameters over the curve domain.
598-
599-
Parameters
600-
----------
601-
n : int, optional
602-
The number of points in the discretisation.
603-
604-
Returns
605-
-------
606-
List[:class:`compas.geometry.Point`]
607-
"""
608-
return [self.point_at(param) for param in self.space(n)]
609-
610-
def locus(self, resolution=100):
611-
"""Compute the locus of the curve.
612-
613-
Parameters
614-
----------
615-
resolution : int, optional
616-
The number of intervals at which a point on the
617-
curve should be computed. Defaults to 100.
618-
619-
Returns
620-
-------
621-
List[:class:`compas.geometry.Point`]
622-
Points along the curve.
623-
"""
624-
return self.xyz(resolution)
625-
626548
def point_at(self, t):
627549
"""Compute a point on the curve.
628550

src/compas_occ/geometry/curves/nurbs.pyi

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -181,20 +181,10 @@ class OCCNurbsCurve(NurbsCurve):
181181
# Methods
182182
# ==============================================================================
183183

184-
def copy(self) -> 'OCCNurbsCurve': ...
185-
186184
def transform(self, T: Transformation) -> None: ...
187185

188-
def transformed(self, T: Transformation) -> 'OCCNurbsCurve': ...
189-
190186
def reverse(self) -> None: ...
191187

192-
def space(self, n: int = 10) -> List[float]: ...
193-
194-
def xyz(self, n: int = 10) -> List[Point]: ...
195-
196-
def locus(self, resolution=100) -> List[Point]: ...
197-
198188
def point_at(self, t: float) -> Point: ...
199189

200190
def tangent_at(self, t) -> Vector: ...

0 commit comments

Comments
 (0)