[vtkusers] simple vtk application

Dženan Zukić dzenanz at gmail.com
Wed Aug 24 07:08:35 EDT 2011


I really cannot answer that because I do not like the filter pipeline
approach and I don't use it extensively - I mostly use it to produce their
output which I then keep in memory and use it as needed.

2011/8/24 Florian Bruckner <e0425375 at gmail.com>

> ah, ok! a (hopefully) last question: i just implemented the first
> prototype of my application and i was facing the following problem: How
> can i add/remove a filter in the middle of a pipeline?
>
> i first create a pipeline which draws my geometry as well as some
> glyphs, ... But then there should be a switch which allows to apply a
> clipping filter. I know the object that the filter should act on. But i
> do not know which other objects have been connected to the original
> one.
>
> is there a method to find in a general way, what parts are connected to
> a given vtkAlgorithm? or do i have to do the bookkeeping on my own?
>
> greetings
> Florian
>
>
> On Wed, 2011-08-24 at 12:17 +0200, Dženan Zukić wrote:
> > Hundred independent actors is quite normal, the performance problems
> > start occurring with many thousands of actors.
> >
> >
> > You don't have to remove actors, you can turn off  their visibility
> >
> > actor->SetVisibility(0);
> >
> >
> > On Wed, Aug 24, 2011 at 04:04, Florian Bruckner <e0425375 at gmail.com>
> > wrote:
> >         ok, but can you tell which one of the 2 designs is more
> >         efficient for
> >         some cases:
> >
> >         In my case i have multiple files that should be displayed at
> >         once (say
> >         max. 16. If I have time-series then there will always be
> >         max.16 files
> >         at a time). These files contain an unstructured grid as well
> >         as some
> >         vector / scalar data. Mainly I want to be able to display the
> >         grid and
> >         then toggle the vectordata (glyph) on and off. The scalar data
> >         should
> >         only change the color. So my intention was to create one
> >         mapper/actor
> >         for the structure and one mapper/actor for the glyph per file.
> >         Switching glyph on and off is then done by simple adding /
> >         removing
> >         the mapper to the proper renderer (there could be more than
> >         one if
> >         some files should be displayed next to each other). so this
> >         approximately would give 2*16 actors which are active at a
> >         time. do
> >         you think this could be a performance problem?
> >
> >         if i would use this combine-filter i cannot control the color
> >         settings
> >         of structure and glyph seperately, right? because then this
> >         method is
> >         no option for me. E.g. I would like display the geometry with
> >         opacity
> >         and gray color if the glyph is switched on.
> >
> >         thanks Alex for your fast reply
> >         FloB
> >
> >
> >
> >         On Wed, Aug 24, 2011 at 1:43 AM, Alex Malyushytskyy
> >         <alexmalvtk at gmail.com> wrote:
> >         > First, there are a multiple ways you can do things in vtk.
> >         >
> >         > Using multiple actors make sense only if you need an ability
> >         easy
> >         > separate object from other objects and might be not
> >         efficient
> >         > if you have large number of objects ( if your data has more
> >         than few
> >         > hundred objects (pieces/files,) I will avoid using one actor
> >         per
> >         > object.
> >         >
> >         > You also probably don't need multiple renderers.
> >         >
> >         > In my practice mostly often I used 2 designs:
> >         >
> >         > 1.  per file: Reader -> filter -> actor
> >         > One window and one renderer per application
> >         >
> >         > 2  per file: Reader -> filter ->
> >         >
> >         > every filter(s) output goes to combining filter as an input
> >         (for
> >         > example vtkAppendPolyData)
> >         >
> >         > combining filter-> actor ->
> >         > still one  window and one renderer per application
> >         >
> >         >
> >         >
> >         >
> >         >
> >         > On Tue, Aug 23, 2011 at 3:26 AM, Florian Bruckner
> >         <e0425375 at gmail.com> wrote:
> >         >> hi, i'm new to vtk and i have a few design questions. I
> >         want to write a
> >         >> simple visualization tool for our data. It should support
> >         multiple input
> >         >> files and different filters for each input file. Each
> >         filter then needs
> >         >> a mapper and an actor, if I understand that correctly. All
> >         those things
> >         >> should be put into an new class asdf_input.
> >         >>
> >         >> Finally there is an renderer window where the data should
> >         be displayed.
> >         >> So I would add the proper actors from the asdf_input object
> >         and add them
> >         >> to multiple renderers. Then these multiple renderers are
> >         added to the
> >         >> renderer window. All these things are put into another
> >         class
> >         >> asdf_output.
> >         >>
> >         >> So this is the first plan. But after looking over the vtk
> >         class
> >         >> reference i found vtkView, vtkDataRepresentation, ... and i
> >         was
> >         >> wondering whether there is already something very similar
> >         available.
> >         >>
> >         >> So my question is whether there is already some top-level
> >         class
> >         >> available, which allows to simplify the handling of
> >         multiple
> >         >> input/filters/renderers.
> >         >>
> >         >> greetings
> >         >> Florian
> >         >>
> >         >>
> >         >> _______________________________________________
> >         >> Powered by www.kitware.com
> >         >>
> >         >> Visit other Kitware open-source projects at
> >         http://www.kitware.com/opensource/opensource.html
> >         >>
> >         >> Please keep messages on-topic and check the VTK FAQ at:
> >         http://www.vtk.org/Wiki/VTK_FAQ
> >         >>
> >         >> Follow this link to subscribe/unsubscribe:
> >         >> http://www.vtk.org/mailman/listinfo/vtkusers
> >         >>
> >         > _______________________________________________
> >         > Powered by www.kitware.com
> >         >
> >         > Visit other Kitware open-source projects at
> >         http://www.kitware.com/opensource/opensource.html
> >         >
> >         > Please keep messages on-topic and check the VTK FAQ at:
> >         http://www.vtk.org/Wiki/VTK_FAQ
> >         >
> >         > Follow this link to subscribe/unsubscribe:
> >         > http://www.vtk.org/mailman/listinfo/vtkusers
> >         >
> >         _______________________________________________
> >         Powered by www.kitware.com
> >
> >         Visit other Kitware open-source projects at
> >         http://www.kitware.com/opensource/opensource.html
> >
> >         Please keep messages on-topic and check the VTK FAQ at:
> >         http://www.vtk.org/Wiki/VTK_FAQ
> >
> >         Follow this link to subscribe/unsubscribe:
> >         http://www.vtk.org/mailman/listinfo/vtkusers
> >
> >
> >
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20110824/ca0bc7c2/attachment.htm>


More information about the vtkusers mailing list