[yt-svn] commit/yt: ngoldbaum: Fixing the case when north_vector is not defined by the user.
Bitbucket
commits-noreply at bitbucket.org
Wed Sep 26 12:48:09 PDT 2012
1 new commit in yt:
https://bitbucket.org/yt_analysis/yt/changeset/5af7cb598179/
changeset: 5af7cb598179
branch: yt
user: ngoldbaum
date: 2012-09-26 21:47:04
summary: Fixing the case when north_vector is not defined by the user.
affected #: 1 file
diff -r e6915de3e4eb9416758acf2203d281c71319b40b -r 5af7cb598179b93a2162b6aa8605d70cb2776b90 yt/visualization/volume_rendering/camera.py
--- a/yt/visualization/volume_rendering/camera.py
+++ b/yt/visualization/volume_rendering/camera.py
@@ -195,7 +195,7 @@
if not iterable(width):
width = (width, width, width) # left/right, top/bottom, front/back
self.orienter = Orientation(normal_vector, north_vector=north_vector, steady_north=steady_north)
- self.rotation_vector = self.orienter.north_vector
+ self.rotation_vector = self.orienter.unit_vectors[1]
self._setup_box_properties(width, center, self.orienter.unit_vectors)
if fields is None: fields = ["Density"]
self.fields = fields
@@ -282,7 +282,7 @@
if center is not None:
self.center = center
if north_vector is None:
- north_vector = self.orienter.north_vector
+ north_vector = self.orienter.unit_vectors[1]
if normal_vector is None:
normal_vector = self.orienter.normal_vector
self.orienter.switch_orientation(normal_vector = normal_vector,
@@ -587,7 +587,7 @@
"""
rot_vector = self.orienter.normal_vector
R = get_rotation_matrix(theta, rot_vector)
- north_vector = self.orienter.north_vector
+ north_vector = self.orienter.unit_vectors[1]
self.switch_view(north_vector=np.dot(R, north_vector))
def rotation(self, theta, n_steps, rot_vector=None, clip_ratio = None):
Repository URL: https://bitbucket.org/yt_analysis/yt/
--
This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.
More information about the yt-svn
mailing list