From 84bc25ffd158b54b4038433b482982fd71951a56 Mon Sep 17 00:00:00 2001 From: Isaak Lim Date: Thu, 30 May 2013 15:11:38 +0000 Subject: [PATCH] - added an explanation on how to use multiple modules to the commandlineDecimater help output - added decimater related help output to DecimaterGui when 'h' is pressed as the application is running refs #1580 git-svn-id: http://www.openmesh.org/svnrepo/OpenMesh/trunk@827 fdac6126-5c0c-442c-9429-916003d36597 --- src/OpenMesh/Apps/Decimating/DecimaterViewerWidget.cc | 7 +++++++ src/OpenMesh/Apps/Decimating/decimater.cc | 7 ++++++- src/OpenMesh/Apps/Decimating/decimaterviewer.cc | 3 ++- 3 files changed, 15 insertions(+), 2 deletions(-) diff --git a/src/OpenMesh/Apps/Decimating/DecimaterViewerWidget.cc b/src/OpenMesh/Apps/Decimating/DecimaterViewerWidget.cc index e431bfdd..f2f88dfd 100644 --- a/src/OpenMesh/Apps/Decimating/DecimaterViewerWidget.cc +++ b/src/OpenMesh/Apps/Decimating/DecimaterViewerWidget.cc @@ -67,6 +67,13 @@ void DecimaterViewerWidget::keyPressEvent(QKeyEvent* _event) { switch (_event->key()) { + case Key_H: + std::cout << "Press '+' to increase the number of decimating steps\n" + << "Press '-' to decrease the number of decimating steps\n" + << "Press 'd' to perform the set number of decimating steps\n" + << "Press 'S' to save the mesh to 'result.off'\n" + << "Press 'q' or 'Esc' quit the application" << std::endl; + break; case Key_D: { int rc; diff --git a/src/OpenMesh/Apps/Decimating/decimater.cc b/src/OpenMesh/Apps/Decimating/decimater.cc index 3ec60659..64807aac 100644 --- a/src/OpenMesh/Apps/Decimating/decimater.cc +++ b/src/OpenMesh/Apps/Decimating/decimater.cc @@ -533,7 +533,12 @@ void usage_and_exit(int xcode) << " Decimating a mesh using quadrics and normal flipping.\n" << std::endl; std::cerr << "Options\n" << std::endl; std::cerr << " -M \"{Module-Name}[:Value]}\"\n" - << " Use named module with eventually given parameterization\n" << std::endl; + << " Use named module with eventually given parameterization\n" + << " Several modules can also be used in order to introduce further constraints\n" + << " Note that -M has to be given before each new module \n" + << " An example with ModQuadric as a priority module\n" + << " and ModRoundness as a binary module could look like this:\n" + << " commandlineDecimater -M Q -M R:40.0 -n 0.1 -i inputfile.obj -o outputfile.obj\n" << std::endl; std::cerr << " -n \n" << " N >= 1: do N halfedge collapses.\n" << " N <=-1: decimate down to |N| vertices.\n" diff --git a/src/OpenMesh/Apps/Decimating/decimaterviewer.cc b/src/OpenMesh/Apps/Decimating/decimaterviewer.cc index a1ff13a6..f93c8a23 100644 --- a/src/OpenMesh/Apps/Decimating/decimaterviewer.cc +++ b/src/OpenMesh/Apps/Decimating/decimaterviewer.cc @@ -134,10 +134,11 @@ int main(int argc, char **argv) void usage_and_exit(int xcode) { - std::cout << "Usage: decimaterviewer [-s] [mesh] [texture]\n" << std::endl; + std::cout << "Usage: DecimaterGui [-s] [mesh] [texture]\n" << std::endl; std::cout << "Options:\n" << " -s\n" << " Reverse byte order, when reading binary files.\n" + << " Press 'h' when the application is running for more options.\n" << std::endl; exit(xcode); }