[yt-svn] commit/yt: MatthewTurk: Hot fix for grey_opacity only being in ColorTransferFunction.
Bitbucket
commits-noreply at bitbucket.org
Wed Aug 1 19:43:37 PDT 2012
1 new commit in yt:
https://bitbucket.org/yt_analysis/yt/changeset/3c09edcdbd78/
changeset: 3c09edcdbd78
branch: yt
user: MatthewTurk
date: 2012-08-02 04:42:32
summary: Hot fix for grey_opacity only being in ColorTransferFunction.
affected #: 1 file
diff -r 3c2ce08a863303a80b057f8f9fba38af0866b5b6 -r 3c09edcdbd786c368f89461e3f152ac042cc9526 yt/utilities/lib/grid_traversal.pyx
--- a/yt/utilities/lib/grid_traversal.pyx
+++ b/yt/utilities/lib/grid_traversal.pyx
@@ -691,7 +691,7 @@
malloc(sizeof(FieldInterpolationTable) * 6)
self.vra.n_fits = tf_obj.n_field_tables
assert(self.vra.n_fits <= 6)
- self.vra.grey_opacity = tf_obj.grey_opacity
+ self.vra.grey_opacity = getattr(tf_obj, "grey_opacity", 0)
self.vra.n_samples = n_samples
self.my_field_tables = []
for i in range(self.vra.n_fits):
@@ -757,7 +757,7 @@
malloc(sizeof(FieldInterpolationTable) * 6)
self.vra.n_fits = tf_obj.n_field_tables
assert(self.vra.n_fits <= 6)
- self.vra.grey_opacity = tf_obj.grey_opacity
+ self.vra.grey_opacity = getattr(tf_obj, "grey_opacity", 0)
self.vra.n_samples = n_samples
self.vra.light_dir = <np.float64_t *> malloc(sizeof(np.float64_t) * 3)
self.vra.light_rgba = <np.float64_t *> malloc(sizeof(np.float64_t) * 4)
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