MCPcopy Index your code
hub / github.com/matplotlib/matplotlib / draw

Method draw

lib/mpl_toolkits/mplot3d/art3d.py:356–372  ·  view source on GitHub ↗
(self, renderer)

Source from the content-addressed store, hash-verified

354
355 @artist.allow_rasterization
356 def draw(self, renderer):
357 scale_mask = _scale_invalid_mask(*self._verts3d, self.axes)
358 if self._axlim_clip:
359 scale_mask |= _viewlim_mask(*self._verts3d, self.axes)
360 if np.any(scale_mask):
361 mask = np.broadcast_to(
362 scale_mask,
363 (len(self._verts3d), *self._verts3d[0].shape)
364 )
365 xs3d, ys3d, zs3d = np.ma.array(self._verts3d,
366 dtype=float, mask=mask).filled(np.nan)
367 else:
368 xs3d, ys3d, zs3d = self._verts3d
369 xs, ys, zs, tis = proj3d._scale_proj_transform_clip(xs3d, ys3d, zs3d, self.axes)
370 self.set_data(xs, ys)
371 super().draw(renderer)
372 self.stale = False
373
374
375def line_2d_to_3d(line, zs=0, zdir='z', axlim_clip=False):

Callers

nothing calls this directly

Calls 4

_scale_invalid_maskFunction · 0.85
_viewlim_maskFunction · 0.85
set_dataMethod · 0.45
drawMethod · 0.45

Tested by

no test coverage detected