[Ves] VTK pipelines in VES

Aashish Chaudhary aashish.chaudhary at kitware.com
Wed Sep 4 15:16:26 EDT 2013


On Wed, Sep 4, 2013 at 3:05 PM, Matthias Baitsch <
matthias.baitsch at uni-kassel.de> wrote:

> Dear Aashish
>
> On Sep 4, 2013, at 3:05 PM, Aashish Chaudhary <
> aashish.chaudhary at kitware.com> wrote:
>
> Dear Matthias,
>
> On Wed, Sep 4, 2013 at 6:26 AM, Matthias Baitsch <
> matthias.baitsch at uni-kassel.de> wrote:
>
>> Dear VES developers,
>>
>> we are working on a VES based iPad app where the data to be visualised is
>> created and modified interactively (works great, thanks). However, we need
>> to set up VTK style pipelines (source-filter-mapper-actor) which are
>> updated automatically when rendering occurs.
>>
>> As far as I can see, vesKiwiPolyDataRepresentation operates on a
>> vtkPolyData object and cannot be connected to a VTK algorithm.
>>
>> Did I miss something here?
>>
>
> No. You are correct.
>
>>
>> Attached the code for our workaround, maybe it could be useful. We
>> subclassed vesMapper and vesRenderer. The mapper class updates the pipeline
>> and handles the conversion from vtkPolyData to vesGeometryData (using some
>> code borrowed from Kiwi). Our renderer invokes the mapper's update method
>> if needed (code attached).
>>
>
> So it sounds like this strategy worked for you? Based on your description
> and code attached (thanks), it sounds to be me as a reasonable approach.
> However, do you not use vesKiwiPolyDataRepresentation then?
>
>
> It works fine, no problems at all (however, we did copy/paste code and
> setting up the vesMaterial attributes is a bit cumbersome).
>

I would suggest creating higher level material classes something like
vesPlasticMaterial, vesShinyMetalMaterial, vesBoneMaterial or more general
vesGoroudShadingMaterial and in there set everything you need.  In that way
your code would be cleaner and re-usable.


> And yes, vesKiwiPolyDataRepresentation is not used.
>

I see. We had some discussions on how to reform Kiwi. Actually it would
have been nice to have these representations derived from vesNode and thus
become part of the SG itself but it didn't happen for many reasons.

- Aashish


>
> Matthias
>
>
>
> - Aashish
>
>
>
>>
>>
>> Best,
>>
>> Matthias
>>
>>
>>
>>
>>
>> ---
>> Vertr.-Prof. Dr.-Ing. Matthias Baitsch
>>
>> Universität Kassel
>> FB 14 – FG Baustatik
>> Raum 2512
>> Mönchebergstr. 7
>> D-34125 Kassel
>>
>> Tel: +49 561 804 3475
>>
>>
>>
>>
>> _______________________________________________
>> Ves mailing list
>> Ves at public.kitware.com
>> http://public.kitware.com/cgi-bin/mailman/listinfo/ves
>>
>>
>
>
> --
> | Aashish Chaudhary
> | R&D Engineer
> | Kitware Inc.
> | www.kitware.com
>
>
> ---
> Vertr.-Prof. Dr.-Ing. Matthias Baitsch
>
> Universität Kassel
> FB 14 – FG Baustatik
> Raum 2512
> Mönchebergstr. 7
> D-34125 Kassel
>
> Tel: +49 561 804 3475
>
>
>
>
>


-- 
| Aashish Chaudhary
| R&D Engineer
| Kitware Inc.
| www.kitware.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/ves/attachments/20130904/8e9cf7cc/attachment-0001.html>


More information about the Ves mailing list