Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit c01d262

Browse files
committed
Remove mlab.quad2cubic
1 parent fc1ff11 commit c01d262

File tree

2 files changed

+1
-18
lines changed

2 files changed

+1
-18
lines changed

doc/api/next_api_changes/2018-09-18-DS.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,5 @@ in Matplotlib 2.2 has been removed. See below for a list:
2828
- `mlab.segments_intersect`
2929
- `mlab.fftsurr`
3030
- `mlab.offset_line`
31+
- `mlab.quad2cubic`
3132
- `mlab.donothing_callback`

lib/matplotlib/mlab.py

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -2870,21 +2870,3 @@ def path_length(X):
28702870
"""
28712871
X = distances_along_curve(X)
28722872
return np.concatenate((np.zeros(1), np.cumsum(X)))
2873-
2874-
2875-
@cbook.deprecated('2.2')
2876-
def quad2cubic(q0x, q0y, q1x, q1y, q2x, q2y):
2877-
"""
2878-
Converts a quadratic Bezier curve to a cubic approximation.
2879-
2880-
The inputs are the *x* and *y* coordinates of the three control
2881-
points of a quadratic curve, and the output is a tuple of *x* and
2882-
*y* coordinates of the four control points of the cubic curve.
2883-
"""
2884-
# TODO: Candidate for deprecation -- no longer used internally
2885-
2886-
# c0x, c0y = q0x, q0y
2887-
c1x, c1y = q0x + 2./3. * (q1x - q0x), q0y + 2./3. * (q1y - q0y)
2888-
c2x, c2y = c1x + 1./3. * (q2x - q0x), c1y + 1./3. * (q2y - q0y)
2889-
# c3x, c3y = q2x, q2y
2890-
return q0x, q0y, c1x, c1y, c2x, c2y, q2x, q2y

0 commit comments

Comments
 (0)