[Paraview] problems getting ParaView to use my reader plugin

Christine Corbett Moran corbett at physik.uzh.ch
Tue Sep 15 04:25:25 EDT 2009


Hi,

I am having some basic problems getting Paraview to use my simple reader
plugin. After loading the two plugins (one  for the server side and one for
the client side) in my GUI, if I try to open a new file with my new
extension (txt or txts) it neither recognizes the extension, nor displays my
new reader as a choice among the selection of possible readers for
unrecognized extensions.

I followed the process for writing a reader plugin  in chapter 19.4 of the
Paraview guide, creating the files TxtReader.qrc, TxtReaderGUI.xml, and
TxtReaderSM.xml along with the code vtkTxtReader.cxx and vtkTxtReader.h
(which are identical to vtkSimplePointsReader with the only the class name
changed). The both client and server side build without problems. I then
load both the server side plugin and the client side plugin, in that order,
in my Paraview GUI, which also goes without problems or errors. But after
all this neither my new file extension nor my new reader are displayed when
I go to open a sample .txt file.

Any ideas how to debug? Below I have included my .qrc, .xml, and
CMakeLists.txt files

Thanks,
Christine

CMakeLists.txt:
cmake_minimum_required(VERSION 2.4)
FIND_PACKAGE(ParaView REQUIRED)
INCLUDE(${PARAVIEW_USE_FILE})
#define the server-side portion of the reader plugin
ADD_PARAVIEW_PLUGIN(TxtReaderSMPlugin "1.0"
        SERVER_MANAGER_SOURCES vtkTxtReader.cxx
        SERVER_MANAGER_XML  TxtReaderSM.xml)
#define the client-side portion of the reader plugin
ADD_PARAVIEW_PLUGIN(TxtReaderGUIPlugin "1.0"
        GUI_RESOURCES TxtReader.qrc)

 TxtReader.qrc:
<RCC>
        <qresource>
                <file>TxtReaderGUI.xml</file>
        </qresource>
</RCC>

TxtReaderSM.xml:
<ServerManagerConfiguration>
        <ProxyGroup name="sources">
                <SourceProxy name="TxtReader" class="vtkTxtReader">
                        <StringVectorProperty
                                name="FileName"
                                command="SetFileName"
                                number_of_elements="1">
                                <FileListDomain name="files"/>
                                <Documentation>
                                        Reads in points from ascii file.
                                </Documentation>
                        </StringVectorProperty>
                </SourceProxy>
        </ProxyGroup>
</ServerManagerConfiguration>

TxtReaderGUI.xml:
<ParaViewReaders>
        <Reader name="TxtReader"
                        extensions="txt txts"
                        file_description="reads in ascii, one point per
line">
        </Reader>
<ParaViewReaders>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20090915/bc9b63da/attachment-0001.htm>


More information about the ParaView mailing list