Commit bb9204b3 authored by Jan Möbius's avatar Jan Möbius

The strange typos fix

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@5077 383ad7c9-94d9-4d36-a494-682f7c89f535
parent b167e436
......@@ -24,29 +24,29 @@
//== IMPLEMENTATION ==========================================================
bool
bool
DecimaterPlugin::
initializeToolbox(QWidget*& _widget)
{
tool_ = new DecimaterToolbarWidget();
_widget = tool_;
QSize size(100, 100);
tool_->resize(size);
tool_->resize(size);
// connect signals->slots
connect(tool_->pbDecimate,SIGNAL(clicked() ),this,SLOT(slot_decimate()));
return true;
}
//-----------------------------------------------------------------------------
void
void
DecimaterPlugin::
slot_decimate()
slot_decimate()
{
for ( PluginFunctions::ObjectIterator o_it(PluginFunctions::TARGET_OBJECTS,DATA_TRIANGLE_MESH) ;
for ( PluginFunctions::ObjectIterator o_it(PluginFunctions::TARGET_OBJECTS,DATA_TRIANGLE_MESH) ;
o_it != PluginFunctions::objectsEnd(); ++o_it) {
//initialize
......@@ -56,16 +56,16 @@ slot_decimate()
emit log(LOGWARN , "Unable to get object");
DecimaterInfo* decimater = dynamic_cast< DecimaterInfo* > ( o_it->objectData(DECIMATER) );
if (decimater == 0){
TriMesh* mesh = PluginFunctions::triMesh(*o_it);
decimater = new DecimaterInfo( tool_, mesh );
o_it->setObjectData(DECIMATER, decimater);
}
decimater->update();
if( ! decimater->decimater()->is_initialized() ){
emit log(LOGWARN, "Decimater could not be initialized");
continue;
......@@ -76,7 +76,7 @@ slot_decimate()
decimater->decimater()->decimate_to( tool_->triangleCount->value() ); // do decimation
else
decimater->decimater()->decimate(); // do decimation
object->mesh()->garbage_collection();
object->mesh()->update_normals();
object->update();
......@@ -91,7 +91,7 @@ slot_decimate()
void DecimaterPlugin::decimate(int _objID, QString _constraints, QString _values){
BaseObjectData* baseObjectData;
if ( ! PluginFunctions::getObject(_objID,baseObjectData) ) {
emit log(LOGERR,"Unable to get Object");
......@@ -107,18 +107,18 @@ void DecimaterPlugin::decimate(int _objID, QString _constraints, QString _values
}
DecimaterInfo* decimater = dynamic_cast< DecimaterInfo* > ( object->objectData(DECIMATER) );
if (decimater == 0){
TriMesh* mesh = PluginFunctions::triMesh(*object);
TriMesh* mesh = PluginFunctions::triMesh(baseObjectData);
decimater = new DecimaterInfo( tool_, mesh );
object->setObjectData(DECIMATER, decimater);
}
decimater->update();
if( ! decimater->decimater()->is_initialized() ){
emit log(LOGWARN, "Decimater could not be initialized");
continue;
return;
}
//decimate
......@@ -126,7 +126,7 @@ void DecimaterPlugin::decimate(int _objID, QString _constraints, QString _values
decimater->decimater()->decimate_to( tool_->triangleCount->value() ); // do decimation
else
decimater->decimater()->decimate(); // do decimation
object->mesh()->garbage_collection();
object->mesh()->update_normals();
object->update();
......
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