Not sure if this is what you need....<br><br># If you want the currently selected object in the menu<br>set currentlyViewedObject [[$application GetMainWindow] GetCurrentPVSource]<br><br># Or loop through all menu objects applying your pipeline
<br>set sources [[$application GetMainWindow] GetSourceList Sources]<br>set num [$sources GetNumberOfItems]<br><br>for {set i 0} {$i < $num} {incr i} {<br> set eachObject [$sources GetItemAsObject $i]<br>
<br> # run your pipeline on the eachObject obtained from the list<br>}<br><br>Shawn<br><br><br><div><span class="gmail_quote">On 7/20/06, <b class="gmail_sendername">Mike Jackson</b> <<a href="mailto:imikejackson@gmail.com">
imikejackson@gmail.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">No wait,<br> we are missing my point. My point is that I have an existing Pipeline
<br>defined. I want to be able to apply that pipeline to any dataset that<br>is loaded up in paraview. Right now I have .vti files of the data. I<br>also have a program that will convert those .vti files into surface<br>meshes (Actually, it takes data from an HDF5 file and creates the Mesh
<br>using VTK as the pipeline.) I started dumping VTI files during the<br>process when I figured out Paraview could read them.<br><br> If there was a way the tcl could get the "currently opened dataset",<br>then the remainder is cake. But from what I am hearing from this list
<br>is that there isn't a way for the TCL scripting to get at the<br>currently opened dataset. It must start from a data file on disk. Is<br>that right?<br><br>Mike Jackson<br><br>On 7/20/06, Berk Geveci <<a href="mailto:berk.geveci@gmail.com">
berk.geveci@gmail.com</a>> wrote:<br>> This requires writing a state and then editing it. The state is a Tcl script<br>> so it should be relatively easy to put a loop around it. Just a warning,<br>> creating 600 pipeline objects in a loop might not work well
<br>> performance-wise. I would recommend deleting the pipeline objects at the end<br>> of each iteration.<br>> Also, working with trace as opposed to state might be easier. Trace does not<br>> save out as much info as state.
<br>><br>> -Berk<br>><br>><br>> On 7/20/06, Mike Jackson < <a href="mailto:imikejackson@gmail.com">imikejackson@gmail.com</a>> wrote:<br>> > What I want to be able to do is load up one of these data sets and
<br>> > just apply the pipeline to it. The end result is a Triangle Surface<br>> > mesh for 3D viewing and saving.<br>> ><br>> > I actually already have a program written with VTK that does just<br>
> > this. Except that the program is on one machine and Paraview is on<br>> > another. I was hoping that if I could just have the pipeline ready in<br>> > a script file, the scientists could bring me their .vti file, and then
<br>> > I can just apply the script and out pops my triangle mesh complete<br>> > with proper coloring and all that.<br>> ><br>> > Also, Time animation is something that we would like to look at doing.
<br>> > I fiddled with some of it over the weekend but not ready to go much<br>> > further with it right now.<br>> ><br>> > I was just hoping to be able to apply a script to an already loaded<br>> dataset.
<br>> ><br>> > Mike Jackson<br>> ><br>> > On 7/20/06, Andy Cedilnik <<a href="mailto:andy.cedilnik@kitware.com">andy.cedilnik@kitware.com</a>> wrote:<br>> > > Hi Mike,<br>> > >
<br>> > > You can write a script that will generate 600 states.<br>> > ><br>> > > What is really your end result? Do you want to animate? If so, just<br>> > > click on timesteps and generate a time series out of your dataset.
<br>> > ><br>> > > Andy<br>> > ><br>> > > Mike Jackson wrote:<br>> > > > Hello,<br>> > > > I have a pipeline that was developed (Thanks Andy) in paraview for
<br>> > > > a given data set. I now have about 600 of those datasets. I see that I<br>> > > > can save a session state from paraview and reload it when I relaunch<br>> > > > Paraview. But the session state seems to be really tied to the
<br>> > > > datafile on disk. What I really want is to be able to load one of<br>> > > > those data sets, then load up a script that acts on that dataset, not<br>> > > > the original dataset from the disk.
<br>> > > > How would I best accomplish this.<br>> > > ><br>> > > > Thanks<br>> > > ><br>> > > > ------<br>> > > > Mike Jackson<br>> > > > Senior Research Engineer/New Visualization Engineer
<br>> > > > <a href="mailto:mike.jackson@imts.us">mike.jackson@imts.us</a><br>> > > ><br>> > > ><br>> > > > _______________________________________________<br>> > > > ParaView mailing list
<br>> > > > <a href="mailto:ParaView@paraview.org">ParaView@paraview.org</a><br>> > > > <a href="http://www.paraview.org/mailman/listinfo/paraview">http://www.paraview.org/mailman/listinfo/paraview
</a><br>> > ><br>> > ><br>> > > --<br>> > > Andy Cedilnik<br>> > > Kitware Inc.<br>> > ><br>> > ><br>> ><br>> ><br>> > --<br>> > Mike Jackson
<br>> > imikejackson _at_ gee-mail dot com<br>> > _______________________________________________<br>> > ParaView mailing list<br>> > <a href="mailto:ParaView@paraview.org">ParaView@paraview.org</a>
<br>> > <a href="http://www.paraview.org/mailman/listinfo/paraview">http://www.paraview.org/mailman/listinfo/paraview</a><br>> ><br>><br>><br><br><br>--<br>Mike Jackson<br>imikejackson _at_ gee-mail dot com
<br>_______________________________________________<br>ParaView mailing list<br><a href="mailto:ParaView@paraview.org">ParaView@paraview.org</a><br><a href="http://www.paraview.org/mailman/listinfo/paraview">http://www.paraview.org/mailman/listinfo/paraview
</a><br></blockquote></div><br>