<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
</style>
</head>
<body class='hmmessage'>
Hi!<br>I got it to work with saving every component of the input array in a separate vtkDoubleArray. <br><br>input1 -&gt; GetPointData() -&gt; GetArray(arr1) -&gt; GetData(0,numOfTuples1,0,0, scalars1comp0);<br>input1 -&gt; GetPointData() -&gt; GetArray(arr1) -&gt; GetData(0,numOfTuples1,1,1, scalars1comp1);<br>input1 -&gt; GetPointData() -&gt; GetArray(arr1) -&gt; GetData(0,numOfTuples1,2,2, scalars1comp2);<br><br>input2 -&gt; GetPointData() -&gt; GetArray(arr2) -&gt; GetData(0,numOfTuples2,0,0, scalars2comp0);<br>input2 -&gt; GetPointData() -&gt; GetArray(arr2) -&gt; GetData(0,numOfTuples2,1,1, scalars2comp1);<br>input2 -&gt; GetPointData() -&gt; GetArray(arr2) -&gt; GetData(0,numOfTuples2,2,2, scalars2comp2);<br><br>Then I´m working with those arrays. <br><br>greetings,<br>Natalie<br>&gt; Date: Mon, 20 Apr 2009 07:27:57 -0400<br>&gt; Subject: Re: [Paraview] Retrieving tuples from dataset<br>&gt; From: berk.geveci@kitware.com<br>&gt; To: nataliehapp@hotmail.com<br>&gt; CC: paraview@paraview.org<br>&gt; <br>&gt; Natalie,<br>&gt; <br>&gt; Those methods definitely work otherwise our dashboards would be<br>&gt; showing it. You must be doing something wrong. Make sure that tuple[]<br>&gt; is a double array.<br>&gt; <br>&gt; -berk<br>&gt; <br>&gt; On Mon, Apr 20, 2009 at 3:50 AM, Natalie Happenhofer<br>&gt; &lt;nataliehapp@hotmail.com&gt; wrote:<br>&gt; &gt; Hi!<br>&gt; &gt; Thanks, retrieving works now, but the next problem is inserting:<br>&gt; &gt; I tried the following:<br>&gt; &gt;<br>&gt; &gt; result -&gt; InsertTuple3(i,tuple[0],tuple[1],tuple[2]);<br>&gt; &gt;<br>&gt; &gt; or<br>&gt; &gt;<br>&gt; &gt; result -&gt; InsertNextTuple(tuple);<br>&gt; &gt;<br>&gt; &gt; but none of those methods work correctly. I checked the values of tuple,<br>&gt; &gt; they are correct, but in the output - dataset, the values are wrong..<br>&gt; &gt;<br>&gt; &gt; thx,<br>&gt; &gt; Natalie<br>&gt; &gt;<br>&gt; &gt;<br>&gt; &gt;&gt; Date: Sat, 18 Apr 2009 16:51:49 -0400<br>&gt; &gt;&gt; Subject: Re: [Paraview] Retrieving tuples from dataset<br>&gt; &gt;&gt; From: berk.geveci@kitware.com<br>&gt; &gt;&gt; To: nataliehapp@hotmail.com<br>&gt; &gt;&gt; CC: paraview@paraview.org<br>&gt; &gt;&gt;<br>&gt; &gt;&gt; For sanity check, what do these return?<br>&gt; &gt;&gt;<br>&gt; &gt;&gt; scalars-&gt;GetValue(i*3+1)<br>&gt; &gt;&gt; scalars-&gt;GetValue(i*3+2)<br>&gt; &gt;&gt;<br>&gt; &gt;&gt; scalars-&gt;GetTuple(i)[1]<br>&gt; &gt;&gt; scalars-&gt;GetTuple(i)[2]<br>&gt; &gt;&gt;<br>&gt; &gt;&gt; -berk<br>&gt; &gt;&gt;<br>&gt; &gt;&gt; On Fri, Apr 17, 2009 at 8:58 AM, Natalie Happenhofer<br>&gt; &gt;&gt; &lt;nataliehapp@hotmail.com&gt; wrote:<br>&gt; &gt;&gt; &gt; Hi!<br>&gt; &gt;&gt; &gt; I´m having trouble retrieving the data from a vector-valued<br>&gt; &gt;&gt; &gt; vtkDoubleArray,<br>&gt; &gt;&gt; &gt; my code looks like this:<br>&gt; &gt;&gt; &gt;<br>&gt; &gt;&gt; &gt; double tuple[3]; //tuple should be stored in this array<br>&gt; &gt;&gt; &gt; scalars -&gt; GetTupleValue(i,tuple);<br>&gt; &gt;&gt; &gt;<br>&gt; &gt;&gt; &gt; The first component, i.e. tuple[0] is retrieved properly, but tuple[1]<br>&gt; &gt;&gt; &gt; and<br>&gt; &gt;&gt; &gt; tuple[2] are definitely wrong, does anyone see the reason?<br>&gt; &gt;&gt; &gt; (the array has 3 components, that´s checked).<br>&gt; &gt;&gt; &gt; Or is there any other method I could use?<br>&gt; &gt;&gt; &gt;<br>&gt; &gt;&gt; &gt; thx,<br>&gt; &gt;&gt; &gt; Natalie<br>&gt; &gt;&gt; &gt;<br>&gt; &gt;&gt; &gt; ________________________________<br>&gt; &gt;&gt; &gt; Hay un nuevo Messenger que tienes que conocer... ¡Mira las novedades!<br>&gt; &gt;&gt; &gt; _______________________________________________<br>&gt; &gt;&gt; &gt; Powered by www.kitware.com<br>&gt; &gt;&gt; &gt;<br>&gt; &gt;&gt; &gt; Visit other Kitware open-source projects at<br>&gt; &gt;&gt; &gt; http://www.kitware.com/opensource/opensource.html<br>&gt; &gt;&gt; &gt;<br>&gt; &gt;&gt; &gt; Please keep messages on-topic and check the ParaView Wiki at:<br>&gt; &gt;&gt; &gt; http://paraview.org/Wiki/ParaView<br>&gt; &gt;&gt; &gt;<br>&gt; &gt;&gt; &gt; Follow this link to subscribe/unsubscribe:<br>&gt; &gt;&gt; &gt; http://www.paraview.org/mailman/listinfo/paraview<br>&gt; &gt;&gt; &gt;<br>&gt; &gt;&gt; &gt;<br>&gt; &gt;<br>&gt; &gt; ________________________________<br>&gt; &gt; ¿Quieres saber cómo va a estar el clima mañana? ¡Ingresa ahora a MSN!<br>&gt; &gt; _______________________________________________<br>&gt; &gt; Powered by www.kitware.com<br>&gt; &gt;<br>&gt; &gt; Visit other Kitware open-source projects at<br>&gt; &gt; http://www.kitware.com/opensource/opensource.html<br>&gt; &gt;<br>&gt; &gt; Please keep messages on-topic and check the ParaView Wiki at:<br>&gt; &gt; http://paraview.org/Wiki/ParaView<br>&gt; &gt;<br>&gt; &gt; Follow this link to subscribe/unsubscribe:<br>&gt; &gt; http://www.paraview.org/mailman/listinfo/paraview<br>&gt; &gt;<br>&gt; &gt;<br><br /><hr />Casi 50 razones para tener el nuevo Messenger. <a href='http://www.nuevomessenger2009.com/' target='_new'>¡Conócelas aquí y bájate el nuevo!</a></body>
</html>