From: Teemu Ikonen <tpikonen@gmail.com>
Subject: Hardcode shadersDir to the correct path in Debian in various plugins
X-git-branch: p/shadersdir

 meshlab/src/fgt/render_rfx/render_rfx.cpp          |    2 +-
 meshlab/src/meshlabplugins/filter_ao/filter_ao.cpp |    2 +-
 .../src/meshlabplugins/render_gdp/meshrender.cpp   |    2 +-
 .../src/meshlabplugins/render_gdp/shaderDialog.cpp |    2 +-
 .../meshlabplugins/render_splatpyramid/dialog.cpp  |    2 +-
 meshlab/src/old/render_rm/rmmeshrender.cpp         |    2 +-
 6 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/meshlab/src/fgt/render_rfx/render_rfx.cpp b/meshlab/src/fgt/render_rfx/render_rfx.cpp
index c393f7a..6889249 100755
--- a/meshlab/src/fgt/render_rfx/render_rfx.cpp
+++ b/meshlab/src/fgt/render_rfx/render_rfx.cpp
@@ -55,7 +55,7 @@ QList<QAction*> RenderRFX::actions()
 
 void RenderRFX::initActionList()
 {
-	QDir shadersDir = PluginManager::getBaseDirPath();
+	QDir shadersDir = QDir("/usr/share/meshlab");
 
 #if defined(Q_OS_WIN)
 	if (shadersDir.dirName() == "debug"   ||
diff --git a/meshlab/src/meshlabplugins/filter_ao/filter_ao.cpp b/meshlab/src/meshlabplugins/filter_ao/filter_ao.cpp
index 5150154..ee16c92 100644
--- a/meshlab/src/meshlabplugins/filter_ao/filter_ao.cpp
+++ b/meshlab/src/meshlabplugins/filter_ao/filter_ao.cpp
@@ -808,7 +808,7 @@ void AmbientOcclusionPlugin::applyOcclusionHW(MeshModel &m)
 
 void AmbientOcclusionPlugin::set_shaders(char *shaderName, GLuint &v, GLuint &f, GLuint &pr)
 {	
-	QDir shadersDir = QDir(qApp->applicationDirPath());
+	QDir shadersDir = QDir("/usr/share/meshlab");
 
 
 #if defined(Q_OS_WIN)
diff --git a/meshlab/src/meshlabplugins/render_gdp/meshrender.cpp b/meshlab/src/meshlabplugins/render_gdp/meshrender.cpp
index 82885e1..822a0fc 100644
--- a/meshlab/src/meshlabplugins/render_gdp/meshrender.cpp
+++ b/meshlab/src/meshlabplugins/render_gdp/meshrender.cpp
@@ -39,7 +39,7 @@ void MeshShaderRenderPlugin::initActionList() {
 	qaNone->setCheckable(false);
 	actionList << qaNone;
 
-	QDir shadersDir = QDir(qApp->applicationDirPath());
+	QDir shadersDir = QDir("/usr/share/meshlab");
 #if defined(Q_OS_WIN)
 	if (shadersDir.dirName() == "debug" || shadersDir.dirName() == "release" || shadersDir.dirName() == "plugins"  )
 		shadersDir.cdUp();
diff --git a/meshlab/src/meshlabplugins/render_gdp/shaderDialog.cpp b/meshlab/src/meshlabplugins/render_gdp/shaderDialog.cpp
index 9c45981..0256805 100644
--- a/meshlab/src/meshlabplugins/render_gdp/shaderDialog.cpp
+++ b/meshlab/src/meshlabplugins/render_gdp/shaderDialog.cpp
@@ -323,7 +323,7 @@ void ShaderDialog::changeTexturePath(int i) {
 void ShaderDialog::browseTexturePath(int i) {
 	QFileDialog fd(0,"Choose new texture");
 
-	QDir shadersDir = QDir(qApp->applicationDirPath());
+	QDir shadersDir = QDir("/usr/share/meshlab");
 #if defined(Q_OS_WIN)
 	if (shadersDir.dirName() == "debug" || shadersDir.dirName() == "release")
 		shadersDir.cdUp();
diff --git a/meshlab/src/meshlabplugins/render_splatpyramid/dialog.cpp b/meshlab/src/meshlabplugins/render_splatpyramid/dialog.cpp
index 589ba48..b7eb1f0 100644
--- a/meshlab/src/meshlabplugins/render_splatpyramid/dialog.cpp
+++ b/meshlab/src/meshlabplugins/render_splatpyramid/dialog.cpp
@@ -123,7 +123,7 @@ void Dialog::changeTexturePath(int i) {
 void Dialog::browseTexturePath(int i) {
   QFileDialog fd(0,"Choose new texture");
 
-  QDir shadersDir = QDir(qApp->applicationDirPath());
+  QDir shadersDir = QDir("/usr/share/meshlab");
 #if defined(Q_OS_WIN)
   if (shadersDir.dirName() == "debug" || shadersDir.dirName() == "release")
 	shadersDir.cdUp();
diff --git a/meshlab/src/old/render_rm/rmmeshrender.cpp b/meshlab/src/old/render_rm/rmmeshrender.cpp
index 9e516d2..076adb2 100644
--- a/meshlab/src/old/render_rm/rmmeshrender.cpp
+++ b/meshlab/src/old/render_rm/rmmeshrender.cpp
@@ -63,7 +63,7 @@ QList<QAction*> RmMeshShaderRenderPlugin::actions()
 
 void RmMeshShaderRenderPlugin::initActionList() {
 
-	QDir shadersDir = QDir(qApp->applicationDirPath());
+	QDir shadersDir = QDir("/usr/share/meshlab");
 #if defined(Q_OS_WIN)
 	if (shadersDir.dirName() == "debug" ||
 	    shadersDir.dirName() == "release" ||
