Commit 32b502b8 authored by Alexander Wiebel's avatar Alexander Wiebel

[STYLE #42] adapt name of module to common use

parent 4cfa4be2
ADD_MODULE( data )
ADD_MODULE( exportGeometry )
ADD_MODULE( readMesh )
ADD_MODULE( readRawData )
ADD_MODULE( writeDendrogram )
ADD_MODULE( writeGeometry )
ADD_MODULE( writeMesh )
ADD_MODULE( writeTracts )
......@@ -28,47 +28,47 @@
#include "core/common/WPropertyHelper.h"
#include "core/graphicsEngine/WTriangleMesh.h"
#include "core/kernel/WKernel.h"
#include "WMExportGeometry.xpm"
#include "WMWriteGeometry.xpm"
#include "WMExportGeometry.h"
#include "WMWriteGeometry.h"
// This line is needed by the module loader to actually find your module. Do not remove. Do NOT add a ";" here.
W_LOADABLE_MODULE( WMExportGeometry )
W_LOADABLE_MODULE( WMWriteGeometry )
WMExportGeometry::WMExportGeometry():
WMWriteGeometry::WMWriteGeometry():
WModule()
{
}
WMExportGeometry::~WMExportGeometry()
WMWriteGeometry::~WMWriteGeometry()
{
// Cleanup!
}
boost::shared_ptr< WModule > WMExportGeometry::factory() const
boost::shared_ptr< WModule > WMWriteGeometry::factory() const
{
// See "src/modules/template/" for an extensively documented example.
return boost::shared_ptr< WModule >( new WMExportGeometry() );
return boost::shared_ptr< WModule >( new WMWriteGeometry() );
}
const char** WMExportGeometry::getXPMIcon() const
const char** WMWriteGeometry::getXPMIcon() const
{
return WMExportGeometry_xpm;
return WMWriteGeometry_xpm;
}
const std::string WMExportGeometry::getName() const
const std::string WMWriteGeometry::getName() const
{
// Specify your module name here. This name must be UNIQUE!
return "Export Geometry";
return "Write Geometry";
}
const std::string WMExportGeometry::getDescription() const
const std::string WMWriteGeometry::getDescription() const
{
// Specify your module description here. Be detailed. This text is read by the user.
// See "src/modules/template/" for an extensively documented example.
return "Exports triangle meshes to certain file formats. VRML implemented so far.";
}
void WMExportGeometry::connectors()
void WMWriteGeometry::connectors()
{
m_input = boost::shared_ptr< WModuleInputData < WTriangleMesh > >(
new WModuleInputData< WTriangleMesh >( shared_from_this(), "Triangle Mesh", "The mesh that will be stored." )
......@@ -80,7 +80,7 @@ void WMExportGeometry::connectors()
WModule::connectors();
}
void WMExportGeometry::properties()
void WMWriteGeometry::properties()
{
m_savePath = m_properties->addProperty( "Save Path", "Where to save the result", boost::filesystem::path( "/tmp/test.wrl" ) );
WPropertyHelper::PC_NOTEMPTY::addTo( m_savePath );
......@@ -88,7 +88,7 @@ void WMExportGeometry::properties()
WModule::properties();
}
void WMExportGeometry::moduleMain()
void WMWriteGeometry::moduleMain()
{
m_moduleState.add( m_input->getDataChangedCondition() );
......@@ -114,7 +114,7 @@ void WMExportGeometry::moduleMain()
}
}
void WMExportGeometry::writeFile()
void WMWriteGeometry::writeFile()
{
boost::shared_ptr< WTriangleMesh > mesh = m_input->getData();
using std::fstream;
......
......@@ -22,8 +22,8 @@
//
//---------------------------------------------------------------------------
#ifndef WMEXPORTGEOMETRY_H
#define WMEXPORTGEOMETRY_H
#ifndef WMWRITEGEOMETRY_H
#define WMWRITEGEOMETRY_H
#include <string>
......@@ -36,29 +36,24 @@
class WTriangleMesh;
/**
* Someone should add some documentation here.
* Probably the best person would be the module's
* creator, i.e. "wiebel".
*
* This is only an empty template for a new module. For
* an example module containing many interesting concepts
* and extensive documentation have a look at "src/modules/template"
* This module writes out geomtry, e.g. surfaces to various
* geomtry file formats. At the moment only VRML.
*
* \ingroup modules
*/
class WMExportGeometry: public WModule
class WMWriteGeometry: public WModule
{
public:
/**
*
*/
WMExportGeometry();
WMWriteGeometry();
/**
*
*/
virtual ~WMExportGeometry();
virtual ~WMWriteGeometry();
/**
* Gives back the name of this module.
......@@ -118,4 +113,4 @@ private:
WPropFilename m_savePath; //!< Path where geometry should be stored
};
#endif // WMEXPORTGEOMETRY_H
#endif // WMWRITEGEOMETRY_H
/* XPM */
static const char * WMExportGeometry_xpm[] = {
static const char * WMWriteGeometry_xpm[] = {
"32 32 27 1",
" c None",
". c #CDCDCD",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment