Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 6b55a0f

Browse filesBrowse files
committed
Add proj3d deprecations to mark progress
1 parent 1c1eb22 commit 6b55a0f
Copy full SHA for 6b55a0f

File tree

1 file changed

+13
-0
lines changed
Filter options

1 file changed

+13
-0
lines changed

‎lib/mpl_toolkits/mplot3d/proj3d.py

Copy file name to clipboardExpand all lines: lib/mpl_toolkits/mplot3d/proj3d.py
+13Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
from matplotlib import _api
88

99

10+
@_api.deprecated("3.10")
1011
def world_transformation(xmin, xmax,
1112
ymin, ymax,
1213
zmin, zmax, pb_aspect=None):
@@ -37,6 +38,7 @@ def rotation_about_vector(v, angle):
3738
return _rotation_about_vector(v, angle)
3839

3940

41+
@_api.deprecated("3.10")
4042
def _rotation_about_vector(v, angle):
4143
"""
4244
Produce a rotation matrix for an angle in radians about a vector.
@@ -93,6 +95,7 @@ def _view_axes(E, R, V, roll):
9395
return u, v, w
9496

9597

98+
@_api.deprecated("3.10")
9699
def _view_transformation_uvw(u, v, w, E):
97100
"""
98101
Return the view transformation matrix.
@@ -142,6 +145,7 @@ def persp_transformation(zfront, zback, focal_length):
142145
return _persp_transformation(zfront, zback, focal_length)
143146

144147

148+
@_api.deprecated("3.10")
145149
def _persp_transformation(zfront, zback, focal_length):
146150
e = focal_length
147151
a = 1 # aspect ratio
@@ -159,6 +163,7 @@ def ortho_transformation(zfront, zback):
159163
return _ortho_transformation(zfront, zback)
160164

161165

166+
@_api.deprecated("3.10")
162167
def _ortho_transformation(zfront, zback):
163168
# note: w component in the resulting vector will be (zback-zfront), not 1
164169
a = -(zfront + zback)
@@ -170,6 +175,7 @@ def _ortho_transformation(zfront, zback):
170175
return proj_matrix
171176

172177

178+
@_api.deprecated("3.10")
173179
def _proj_transform_vec(vec, M):
174180
vecw = np.dot(M, vec)
175181
w = vecw[3]
@@ -178,6 +184,7 @@ def _proj_transform_vec(vec, M):
178184
return txs, tys, tzs
179185

180186

187+
@_api.deprecated("3.10")
181188
def _proj_transform_vec_clip(vec, M):
182189
vecw = np.dot(M, vec)
183190
w = vecw[3]
@@ -189,6 +196,7 @@ def _proj_transform_vec_clip(vec, M):
189196
return txs, tys, tzs, tis
190197

191198

199+
@_api.deprecated("3.10")
192200
def inv_transform(xs, ys, zs, invM):
193201
"""
194202
Transform the points by the inverse of the projection matrix, *invM*.
@@ -203,10 +211,12 @@ def inv_transform(xs, ys, zs, invM):
203211
return vecr[0], vecr[1], vecr[2]
204212

205213

214+
@_api.deprecated("3.10")
206215
def _vec_pad_ones(xs, ys, zs):
207216
return np.array([xs, ys, zs, np.ones_like(xs)])
208217

209218

219+
@_api.deprecated("3.10")
210220
def proj_transform(xs, ys, zs, M):
211221
"""
212222
Transform the points by the projection matrix *M*.
@@ -220,6 +230,7 @@ def proj_transform(xs, ys, zs, M):
220230
alternative="proj_transform")(proj_transform)
221231

222232

233+
@_api.deprecated("3.10")
223234
def proj_transform_clip(xs, ys, zs, M):
224235
"""
225236
Transform the points by the projection matrix
@@ -235,6 +246,7 @@ def proj_points(points, M):
235246
return _proj_points(points, M)
236247

237248

249+
@_api.deprecated("3.10")
238250
def _proj_points(points, M):
239251
return np.column_stack(_proj_trans_points(points, M))
240252

@@ -244,6 +256,7 @@ def proj_trans_points(points, M):
244256
return _proj_trans_points(points, M)
245257

246258

259+
@_api.deprecated("3.10")
247260
def _proj_trans_points(points, M):
248261
xs, ys, zs = zip(*points)
249262
return proj_transform(xs, ys, zs, M)

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.