The models and other data points are usually in a East,North,Elevation coordinate system, but often some datasets will be in a West,South,Depth or some variant in between, due to legacy reasons.<div><br></div><div>I would like to be able to just flick a switch and have everything displayed the "right way" around, however if its going to involve vtkTransformPolyData, what I might be forced to do is flip everything around at the point of importing/loading the data, and then flip the numbers around again when I display grids, coordinates and stuff in tables...</div>
<div><br></div><div>However it would be ideal if I could just tell VTK which way around the world coordinates are, without worrying about normals pointing the wrong way etc.<br><br><div class="gmail_quote">On 17 October 2010 11:11, Bill Lorensen <span dir="ltr"><<a href="mailto:bill.lorensen@gmail.com">bill.lorensen@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">The vtk coordinate system is right-handed. Are your models in a left<br>
handed system?<br>
<div><div></div><div class="h5"><br>
On Sat, Oct 16, 2010 at 11:10 PM, Bill Lorensen <<a href="mailto:bill.lorensen@gmail.com">bill.lorensen@gmail.com</a>> wrote:<br>
> Yes, user matrix should work. But a negative scale will mess up the<br>
> shading calculation. The user matrix is used by opengl. Not sure why<br>
> reverse sense did not work.<br>
><br>
> Try the same thing (as an experiment) with vtkTransformPolyData.<br>
><br>
> On Sat, Oct 16, 2010 at 7:46 PM, Paul Harris <<a href="mailto:harris.pc@gmail.com">harris.pc@gmail.com</a>> wrote:<br>
>> On 16 October 2010 21:25, Bill Lorensen <<a href="mailto:bill.lorensen@gmail.com">bill.lorensen@gmail.com</a>> wrote:<br>
>>><br>
>>> You can use the vtkTransformPolyDataFilter<br>
>>><br>
>><br>
>> That will make a copy of the points and then adjust all the values, right?<br>
>><br>
>> There is quite a lot of points to plot, I was hoping to use an approach that<br>
>> wouldn't involve using more memory.<br>
>><br>
>> Earlier, I tried this approach:<br>
>> vtkTransform * flipform = vtkTransform::New();<br>
>> flipform->Identity();<br>
>> flipform->Scale(1,1,-1);<br>
>> actor_flip->SetUserMatrix( flipform->GetMatrix() );<br>
>><br>
>> And that worked find *except* that all of the surfaces look dark, as if they<br>
>> are facing away from the camera.<br>
>><br>
>> I looked around and tried adding vtkReverseSense to the chain, but that<br>
>> didn't make any difference at all.<br>
>><br>
>> Should I be able to use SetUserMatrix?<br>
>><br>
>><br>
>><br>
>>><br>
>>> On Sat, Oct 16, 2010 at 9:06 AM, Paul Harris <<a href="mailto:harris.pc@gmail.com">harris.pc@gmail.com</a>> wrote:<br>
>>> > The models themselves. Flipping the ViewUp seems to be the same as<br>
>>> > turning<br>
>>> > the monitor upside down, but that is not the result I want.<br>
>>> > The problem is that Z in model coordinates is "downwards", but vtk seems<br>
>>> > to<br>
>>> > insist that Z is "upwards".<br>
>>> > This problem is not just for Z either,<br>
>>> > I also have the situation where in some circumstances, the Y should<br>
>>> > point<br>
>>> > the other way. ie, Y means South rather than North.<br>
>>> ><br>
>>> ><br>
>>> > On 16 October 2010 03:32, Bill Lorensen <<a href="mailto:bill.lorensen@gmail.com">bill.lorensen@gmail.com</a>> wrote:<br>
>>> >><br>
>>> >> Do you want the models flipped, or just the view of the models?<br>
>>> >><br>
>>> >> If it is the latter, you can set the ViewUp of the camera to 0,0,-1.<br>
>>> >><br>
>>> >><br>
>>> >> On Fri, Oct 15, 2010 at 3:17 PM, Paul Harris <<a href="mailto:harris.pc@gmail.com">harris.pc@gmail.com</a>><br>
>>> >> wrote:<br>
>>> >> > Hi all,<br>
>>> >> ><br>
>>> >> > I have a VTK scene with some vtkPolyDataMappers and actors, plus an<br>
>>> >> > orientation widget.<br>
>>> >> ><br>
>>> >> > I want to change the fundamental direction of the Z axis, so that it<br>
>>> >> > points<br>
>>> >> > down rather than up. I want all of the models, the orientation<br>
>>> >> > widget,<br>
>>> >> > etc<br>
>>> >> > to flip, so that they point down instead of up.<br>
>>> >> ><br>
>>> >> > I've tried lots of things but have gotten nowhere...<br>
>>> >> ><br>
>>> >> > how do I make this happen?<br>
>>> >> ><br>
>>> >> > thanks<br>
>>> >> > Paul<br>
>>> >> ><br>
>>> >> ><br>
>>> >> ><br>
>>> >> > _______________________________________________<br>
>>> >> > Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
>>> >> ><br>
>>> >> > Visit other Kitware open-source projects at<br>
>>> >> > <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
>>> >> ><br>
>>> >> > Please keep messages on-topic and check the VTK FAQ at:<br>
>>> >> > <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
>>> >> ><br>
>>> >> > Follow this link to subscribe/unsubscribe:<br>
>>> >> > <a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
>>> >> ><br>
>>> >> ><br>
>>> ><br>
>>> ><br>
>><br>
>><br>
><br>
</div></div></blockquote></div><br></div>