[Paraview-developers] Filter plugin, xml properties for arrays

Lodron, Gerald Gerald.Lodron at joanneum.at
Thu Oct 31 04:11:37 EDT 2013


Hi

I want to make a filter plugin where i do not know how to set the xml file for the properties panel, may some expert can give me a hint:

The filter has has two inputs (both vtkPolyData Objects ) with optional point based arrays. The user should optionally be able to select none ore an arbitrary amount of these arrays with an additional float value, so the member function of my filter has this signature:

    void EnableAttributeArray( const char* pcArrName, float fFactor );
    void ClearAttributeArrays();

It would also be nice if only those arrays would be displayed which are have same name in both inputs...

Currently i have made a list with array names of first input, no check for beeing in both inputs and no possibility of selection of the fFactor float value:

<InputProperty
         name="Target"
         command="AddInputConnection"
         clean_command="RemoveAllInputs">
        <ProxyGroupDomain name="groups">
          <Group name="sources"/>
          <Group name="filters"/>
        </ProxyGroupDomain>
        <DataTypeDomain name="input_type">
          <DataType value="vtkPolyData"/>
        </DataTypeDomain>
        <!--<InputArrayDomain name="input_array" attribute_type="point"/>-->
        <InputArrayDomain name="input_array" />
</InputProperty>
<InputProperty
         name="Source"
         command="AddSourceConnection"
         clean_command="RemoveAllSources">
        <ProxyGroupDomain name="groups">
          <Group name="sources"/>
          <Group name="filters"/>
        </ProxyGroupDomain>
        <DataTypeDomain name="input_type">
          <DataType value="vtkPolyData"/>
        </DataTypeDomain>
</InputProperty>

<StringVectorProperty clean_command="ClearAttributeArrays"
                            command="EnableAttributeArray"
                            label="Add array to distance measure"
                            name="SelectArrays"
                            default_values="0"
                            number_of_elements_per_command="1"
                            repeat_command="1" >
        <ArrayListDomain name="input_array">
                <RequiredProperties>
                <Property function="Input"
                      name="Source" />
                 <Property function="Input"
                      name="Target" />
                </RequiredProperties>
        </ArrayListDomain>
</StringVectorProperty>

If someone could help me it would be great
_________________________________________________________________

JOANNEUM RESEARCH Forschungsgesellschaft mbH

DIGITAL - Institute for Information and Communication Technologies
Steyrergasse 17, 8010 Graz, Austria

phone: +43 316 876-1751
fax: +43 316 8769-1751
e-mail: gerald.lodron at joanneum.at<mailto:gerald.lodron at joanneum.at>
web: www.joanneum.at/digital<http://www.joanneum.at/digital>
_________________________________________________________________

This message and any attached files are confidential and intended solely for the addressee(s). Any publication, transmission or other use of the information by a person or entity other than the intended addressee(s) is prohibited. If you receive this in error please contact the sender and delete the material. The sender does not accept liability for any errors or omissions as a result of the transmission.

Please consider the environment before printing this page.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview-developers/attachments/20131031/ea852129/attachment.htm>


More information about the Paraview-developers mailing list