[yt-svn] commit/yt: samskillman: Transposing image so that the camera north vector works as expected. This is caused by the standard of having an image (0, 0) being in the upper right
Bitbucket
commits-noreply at bitbucket.org
Tue May 1 12:52:05 PDT 2012
1 new commit in yt:
https://bitbucket.org/yt_analysis/yt/changeset/a819e968ca86/
changeset: a819e968ca86
branch: yt
user: samskillman
date: 2012-05-01 21:51:16
summary: Transposing image so that the camera north vector works as expected. This is caused by the standard of having an image (0,0) being in the upper right
affected #: 1 file
diff -r b48beb25efe03efaf578d6b968798e87548afef9 -r a819e968ca86e24ee966f96f0c388132d50d5ed4 yt/visualization/image_writer.py
--- a/yt/visualization/image_writer.py
+++ b/yt/visualization/image_writer.py
@@ -150,6 +150,8 @@
s1, s2 = bitmap_array.shape[:2]
alpha_channel = 255*na.ones((s1,s2,1), dtype='uint8')
bitmap_array = na.concatenate([bitmap_array, alpha_channel], axis=-1)
+ for channel in range(bitmap_array.shape[2]):
+ bitmap_array[:,:,channel] = bitmap_array[:,:,channel].T
au.write_png(bitmap_array.copy(), filename)
return bitmap_array
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