Computer Assisted Medical Intervention Tool Kit  version 5.2
VRMLComponentExtension Class Reference

This VRML Component allows you to manipulate VRML files (unstructured grid and polydata files). More...

#include <VRMLComponentExtension.h>

+ Inheritance diagram for VRMLComponentExtension:
+ Collaboration diagram for VRMLComponentExtension:

Public Member Functions

virtual QString getDescription () const override
 get the plugin description (can be html) More...
 
virtual QStringList getFileExtensions () const override
 get the list of managed extensions More...
 
virtual QString getName () const override
 get the plugin name More...
 
virtual camitk::Componentopen (const QString &) override
 get a new instance from data stored in a file This method may throw an AbortException if a problem occurs. More...
 
virtual bool save (camitk::Component *) const override
 save the given MeshComponent to VRML (does not have to be top-level). More...
 
 VRMLComponentExtension ()
 the constructor (do nothing really) More...
 
- Public Member Functions inherited from camitk::ComponentExtension
 ~ComponentExtension () override=default
 protected destructor, More...
 
virtual bool hasDataDirectory () const
 return true if this component manages directory instead of individual files (e.g. Dicom series are stored in directories, not files) More...
 
QString getLocation () const
 get the file path (location of the .dll/.so/.dylib) of this plugin More...
 
void setLocation (const QString loc)
 set the file path (once loaded as a dynamic library) More...
 
void initResources ()
 Load, for the selected langage (asked to the Application), the associated .qm file. More...
 

Protected Member Functions

virtual ~VRMLComponentExtension ()=default
 the destructor More...
 
- Protected Member Functions inherited from camitk::MeshComponentExtension
 MeshComponentExtension ()
 Constructor protected because the class is virtual. More...
 
 ~MeshComponentExtension ()=default
 the destructor More...
 
- Protected Member Functions inherited from camitk::ComponentExtension
 ComponentExtension ()
 protected constructor, More...
 

Detailed Description

This VRML Component allows you to manipulate VRML files (unstructured grid and polydata files).

This component shows:

  • how to build subcomponents
  • how to extend a MeshComponent
  • add an save to facility,
    See also
    save()
    Thanks to this extension, any mesh component of CamiTK can now be exported to VRML (Although this is not really a good example as VTK does not know how to export a single component to VRML but can only export the whole scene, see save() comment).

Constructor & Destructor Documentation

◆ VRMLComponentExtension()

VRMLComponentExtension::VRMLComponentExtension ( )
inline

the constructor (do nothing really)

◆ ~VRMLComponentExtension()

virtual VRMLComponentExtension::~VRMLComponentExtension ( )
protectedvirtualdefault

the destructor

Member Function Documentation

◆ getDescription()

QString VRMLComponentExtension::getDescription ( ) const
overridevirtual

get the plugin description (can be html)

Reimplemented from camitk::MeshComponentExtension.

◆ getFileExtensions()

QStringList VRMLComponentExtension::getFileExtensions ( ) const
overridevirtual

get the list of managed extensions

Implements camitk::ComponentExtension.

◆ getName()

QString VRMLComponentExtension::getName ( ) const
overridevirtual

get the plugin name

Reimplemented from camitk::MeshComponentExtension.

◆ open()

Component * VRMLComponentExtension::open ( const QString &  fileName)
overridevirtual

get a new instance from data stored in a file This method may throw an AbortException if a problem occurs.

Implements camitk::MeshComponentExtension.

◆ save()

bool VRMLComponentExtension::save ( camitk::Component component) const
overridevirtual

save the given MeshComponent to VRML (does not have to be top-level).

Returns
false if the operation was not performed properly or not performed at all.

Reimplemented from camitk::ComponentExtension.

References CAMITK_ERROR, camitk::Component::getFileName(), camitk::InterfaceGeometry::getPointSet(), camitk::InteractiveViewer::getRendererWidget(), and camitk::Application::getViewer().

+ Here is the call graph for this function:

The documentation for this class was generated from the following files: