This repository has been archived on 2023-03-25. You can view files and clone it, but cannot push or open issues or pull requests.
mightyscape-1.1-deprecated/extensions/fablabchemnitz/elliptical_box/inkscape_helper/PathSegment.py

30 lines
706 B
Python

from collections import namedtuple
PathPoint = namedtuple('PathPoint', 't coord tangent curvature c_dist')
class PathSegment(object):
def __init__(self):
raise NotImplementedError
@property
def lenth(self):
raise NotImplementedError
def subdivide(self, part_length):
raise NotImplementedError
def pathpoint_at_t(self, t):
raise NotImplementedError
def t_at_length(self, length):
raise NotImplementedError
# also need:
# find a way do do curvature dependent spacing
# - based on deviation from a standard radius?
# - or ratio between thickness and curvature?
#def point_at_distance(d):
# pass