<div dir="ltr">Hi Matt, yes I was able to resolve the issue, I need to first rotate the domain (an operation that is specific to my problem) before applying the inverse of the transformation (as I wanted to rotate the domain a certain way, the operation requires applying the inverse transformation to the camera position). For future reference, and because this wasn't clear to me, for FLASH data at least setting the normal vector to [0,0,1] and the north vector to [0,1,0] are the "natural" coordinates, i.e. the image x/y will equal the domain x/y. By default, the image and domain coordinates do not match.<div>

<br></div><div>Thanks for the help,</div><div>- James</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Jan 10, 2014 at 9:25 AM, Matthew Turk <span dir="ltr"><<a href="mailto:matthewturk@gmail.com" target="_blank">matthewturk@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi James,<div><div class="h5"><br><br>On Thursday, January 9, 2014, James Guillochon  wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div dir="ltr">Hi everyone,<div><br></div><div>
I have a 3D simulation FLASH that I wish to rotate and then project using YT. I know the transformation matrix needed to rotate the domain such that the projection is correct, depicted in this image: <a href="http://i.imgur.com/AOmY6Ao.png" target="_blank">http://i.imgur.com/AOmY6Ao.png</a>. In the image, the dashed lines are the original coordinate system, where the original "north_vector" is the red dashed line, and the original "normal_vector" is a green dashed line that points out of the plane (not visible). The rotated coordinates are shown by the solid lines. The transformation matrix A is:</div>




<div><br></div><div>A =</div><div>0.0478113<span style="white-space:pre-wrap">      </span>-0.345249<span style="white-space:pre-wrap">       </span>0.937292</div><div>0.912293<span style="white-space:pre-wrap"> </span>-0.367011<span style="white-space:pre-wrap">       </span>-0.181724</div>




<div>-0.406737<span style="white-space:pre-wrap"> </span>-0.863774<span style="white-space:pre-wrap">       </span>-0.297421</div><div><br></div><div>My question is what should I set "normal_vector" and "north_vector" to to get the proper projection. I tried just doing A.normal and A.north, but the projection I get is not correct. I've also tried multiplying by A_inverse, or just multiplying normal and/or north by A (or A_inverse), and setting the other vector to a trivial direction (such as [0,0,1]), but none of these projections seem to be correct.</div>




<div><br></div><div>Another thing I have tried is opening the data in Visit and rotating the domain manually, taking note of what Visit calls the "view normal" and the "up vector". The "up vector" matches the "north vector" I calculate using A.north, but the "view normal" does not match A.normal.</div>




<div><br></div><div>Does anyone know the proper way to go about this? Thanks!</div></div></blockquote><div><br></div></div></div><div>I saw that you had some discussion about this on IRC yesterday evening -- did the issues get resolved?</div>


<div><br></div><div>-Matt</div><div class="HOEnZb"><div class="h5"><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>- James<br><div><div>

<br></div>-- <br><div dir="ltr">James Guillochon<br>
<span style="font-family:arial;font-size:small">Einstein Fellow at the Harvard-Smithsonian CfA</span><br>

<a>jguillochon@cfa.harvard.edu</a><br></div>
</div></div></div>
</blockquote>
</div></div><br>_______________________________________________<br>
yt-users mailing list<br>
<a href="mailto:yt-users@lists.spacepope.org">yt-users@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr">James Guillochon<br><span style="font-family:arial;font-size:small">Einstein Fellow at the Harvard-Smithsonian CfA</span><br><a href="mailto:jguillochon@cfa.harvard.edu" target="_blank">jguillochon@cfa.harvard.edu</a></div>


</div>