You can subscribe to this list here.
2009 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(144) |
Jul
(5) |
Aug
(23) |
Sep
(3) |
Oct
(8) |
Nov
(6) |
Dec
(3) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2010 |
Jan
(4) |
Feb
|
Mar
(34) |
Apr
(1) |
May
(10) |
Jun
(12) |
Jul
(17) |
Aug
(28) |
Sep
(2) |
Oct
|
Nov
(2) |
Dec
(3) |
2011 |
Jan
(4) |
Feb
(7) |
Mar
(5) |
Apr
(1) |
May
|
Jun
(15) |
Jul
(1) |
Aug
(7) |
Sep
(9) |
Oct
(3) |
Nov
|
Dec
(1) |
2012 |
Jan
(1) |
Feb
(13) |
Mar
(6) |
Apr
|
May
(1) |
Jun
|
Jul
(1) |
Aug
(9) |
Sep
(7) |
Oct
(2) |
Nov
|
Dec
|
2013 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: <wol...@us...> - 2012-03-02 10:32:01
|
Revision: 404 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=404&view=rev Author: wolfspindler Date: 2012-03-02 10:31:55 +0000 (Fri, 02 Mar 2012) Log Message: ----------- Trial to fix platform incompatibility Modified Paths: -------------- trunk/UMD/METK/Sources/Inventor/UMDSoMeasurement/UMDMeasurementInit.h Modified: trunk/UMD/METK/Sources/Inventor/UMDSoMeasurement/UMDMeasurementInit.h =================================================================== --- trunk/UMD/METK/Sources/Inventor/UMDSoMeasurement/UMDMeasurementInit.h 2012-03-02 10:30:45 UTC (rev 403) +++ trunk/UMD/METK/Sources/Inventor/UMDSoMeasurement/UMDMeasurementInit.h 2012-03-02 10:31:55 UTC (rev 404) @@ -114,8 +114,7 @@ #else -#include <mstring.h> -#include <windows.h> +// For example Mac OS X #include <string> #include <stdio.h> #include <stdlib.h> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wol...@us...> - 2012-03-02 10:30:51
|
Revision: 403 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=403&view=rev Author: wolfspindler Date: 2012-03-02 10:30:45 +0000 (Fri, 02 Mar 2012) Log Message: ----------- Trial to fix platform incompatibility Modified Paths: -------------- trunk/UMD/METK/Sources/Inventor/UMDViewerTrigger/UMDViewerTriggerInit.h Modified: trunk/UMD/METK/Sources/Inventor/UMDViewerTrigger/UMDViewerTriggerInit.h =================================================================== --- trunk/UMD/METK/Sources/Inventor/UMDViewerTrigger/UMDViewerTriggerInit.h 2012-02-23 13:36:03 UTC (rev 402) +++ trunk/UMD/METK/Sources/Inventor/UMDViewerTrigger/UMDViewerTriggerInit.h 2012-03-02 10:30:45 UTC (rev 403) @@ -93,8 +93,7 @@ #else -#include <mstring.h> -#include <windows.h> +// For example MacOS: #include <string> #include <stdio.h> #include <stdlib.h> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wol...@us...> - 2012-02-23 13:36:14
|
Revision: 402 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=402&view=rev Author: wolfspindler Date: 2012-02-23 13:36:03 +0000 (Thu, 23 Feb 2012) Log Message: ----------- First steps for port to MeVsiLab2.3: -Unsafe and platform dependent abs usage causing trouble in MeVisLab2.3 replaced by fabs. -Some unclear function signatures changed to more precise matching signature. -Some code fragements ported for forward compatibility to new reference counted base and CSOList pointers. Modified Paths: -------------- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.cpp trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.h Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.cpp =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.cpp 2012-02-23 13:30:05 UTC (rev 401) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.cpp 2012-02-23 13:36:03 UTC (rev 402) @@ -144,12 +144,15 @@ { ML_TRACE_IN("CSOImageStatistics::~CSOImageStatistics()"); - // Remove calback function + // Remove callback function if (m_InCSOList != NULL){ m_InCSOList->removeNotificationObserver(CsoListNotifyObserverCB, this); } if (!f_WorkDirectlyOnInputList->getBoolValue()){ +#if MEVISLAB_VERSION < 203 ML_DELETE(m_OutCSOList); +#endif + m_OutCSOList = NULL; } // Remove any existing curves @@ -198,7 +201,11 @@ bool hasChangedToOn = f_WorkDirectlyOnInputList->getBoolValue(); if (m_InCSOList != NULL){ if (hasChangedToOn){ +#if MEVISLAB_VERSION < 203 ML_DELETE(m_OutCSOList); +#endif + m_OutCSOList = NULL; + m_OutCSOList = m_InCSOList; } else { ML_CHECK_NEW(m_OutCSOList, CSOList(*m_InCSOList)); @@ -206,12 +213,19 @@ } else { // no input, nothing to put out if (hasChangedToOn){ if (m_OutCSOList != NULL){ +#if MEVISLAB_VERSION < 203 ML_DELETE(m_OutCSOList); +#endif + m_OutCSOList = NULL; } } m_OutCSOList = NULL; } +#if MEVISLAB_VERSION < 203 f_OutputCSOList->setBaseValue(m_OutCSOList); +#else + f_OutputCSOList->setBaseValue(m_OutCSOList.get()); +#endif if ( inputImageValid ){ ProcessCSOList(false); } @@ -249,14 +263,19 @@ if (workDirectlyOnInputCSOList){ m_OutCSOList = NULL; } else { +#if MEVISLAB_VERSION < 203 ML_DELETE(m_OutCSOList); +#endif m_OutCSOList = NULL; } } if (m_InCSOList != NULL){ if (!workDirectlyOnInputCSOList){ // make copy +#if MEVISLAB_VERSION < 203 ML_DELETE(m_OutCSOList); +#endif + m_OutCSOList = NULL; ML_CHECK_NEW(m_OutCSOList, CSOList(*m_InCSOList)); } else { // use pointer m_OutCSOList = m_InCSOList; @@ -266,7 +285,11 @@ m_InCSOList->addNotificationObserver(CsoListNotifyObserverCB, this); } } +#if MEVISLAB_VERSION < 203 f_OutputCSOList->setBaseValue(m_OutCSOList); +#else + f_OutputCSOList->setBaseValue(m_OutCSOList.get()); +#endif } @@ -573,11 +596,11 @@ const MLint offset = currentPos.dot( strideVector ); double* currentValue = inputTile+offset; sum += *currentValue; - absSum += abs(*currentValue); + absSum += fabs(*currentValue); minimum = ML_MIN(minimum, *currentValue ); - absMin = ML_MIN(minimum, abs(*currentValue) ); + absMin = ML_MIN(minimum, fabs(*currentValue) ); maximum = ML_MAX(maximum, *currentValue ); - absMax = ML_MAX(maximum, abs(*currentValue) ); + absMax = ML_MAX(maximum, fabs(*currentValue) ); } const double csoArea = ( f_UseAllPointsInsideCSO->getBoolValue() ? cso->getArea():cso->getLength() ); @@ -607,12 +630,12 @@ if ( f_OutputCurve->getBoolValue() ) { if ( f_OutputSum->getBoolValue() ) { CurveData *outputCurve = new CurveData; - outputCurve->setY( m_SumSeries.size(), &m_SumSeries[0], 1 ); + outputCurve->setY( static_cast<MLssize_t>(m_SumSeries.size()), &m_SumSeries[0], static_cast<MLssize_t>(1) ); m_OutCurveList->getCurveList().push_back( outputCurve ); } if ( f_OutputAverage->getBoolValue() ) { CurveData *outputCurve = new CurveData; - outputCurve->setY( m_AverageSeries.size(), &m_AverageSeries[0], 1 ); + outputCurve->setY( static_cast<MLssize_t>(m_AverageSeries.size()), &m_AverageSeries[0], static_cast<MLssize_t>(1) ); m_OutCurveList->getCurveList().push_back( outputCurve ); } } Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.h =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.h 2012-02-23 13:30:05 UTC (rev 401) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.h 2012-02-23 13:36:03 UTC (rev 402) @@ -209,7 +209,11 @@ CSOList* m_InCSOList; //! A pointer to the output CSOList. +#if MEVISLAB_VERSION < 203 CSOList* m_OutCSOList; +#else + CSOListPtr m_OutCSOList; +#endif //! The ids of the selected CSOs. std::vector<unsigned int> m_SelectedCSOIds; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wol...@us...> - 2012-02-23 13:30:14
|
Revision: 401 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=401&view=rev Author: wolfspindler Date: 2012-02-23 13:30:05 +0000 (Thu, 23 Feb 2012) Log Message: ----------- First steps for port to MeVsiLab2.3: Unsafe and platform dependent abs usage causing trouble in MeVisLab2.3 replaced by fabs. Modified Paths: -------------- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp 2012-02-23 12:01:40 UTC (rev 400) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp 2012-02-23 13:30:05 UTC (rev 401) @@ -424,8 +424,8 @@ vec3 normal = cso->getPlaneNormal(); normal.normalize(); const vec3 matchingPoint = cso->getFirstSeedPoint()->worldPosition; - const double angleError = 1- abs( currentNormal.dot( normal )); - const double distanceError = abs(currentNormal.dot( matchingPoint - currentPoint )); + const double angleError = 1- fabs( currentNormal.dot( normal )); + const double distanceError = fabs(currentNormal.dot( matchingPoint - currentPoint )); const double currentError = angleError + distanceError; if ( currentError < minError && angleError < tollerance && distanceError < 10*tollerance ) { minError = currentError; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wol...@us...> - 2012-02-23 12:01:51
|
Revision: 400 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=400&view=rev Author: wolfspindler Date: 2012-02-23 12:01:40 +0000 (Thu, 23 Feb 2012) Log Message: ----------- Trial to fix a platform incompatibility against old apple gcc4.2. Modified Paths: -------------- trunk/Community/General/Sources/ML/MLCMCurveList/CMCurveFilter/mlCMCurveFilter.cpp Modified: trunk/Community/General/Sources/ML/MLCMCurveList/CMCurveFilter/mlCMCurveFilter.cpp =================================================================== --- trunk/Community/General/Sources/ML/MLCMCurveList/CMCurveFilter/mlCMCurveFilter.cpp 2012-02-21 14:24:32 UTC (rev 399) +++ trunk/Community/General/Sources/ML/MLCMCurveList/CMCurveFilter/mlCMCurveFilter.cpp 2012-02-23 12:01:40 UTC (rev 400) @@ -221,8 +221,8 @@ xSeries.push_back( xValue ); } } - outputCurve->setX( xSeries.size(),&xSeries[0], 1 ); - outputCurve->setY( ySeries.size(),&ySeries[0], 1 ); + outputCurve->setX( static_cast<MLssize_t>(xSeries.size()),&xSeries[0], static_cast<MLssize_t>(1) ); + outputCurve->setY( static_cast<MLssize_t>(ySeries.size()),&ySeries[0], static_cast<MLssize_t>(1) ); m_OutCurveList->getCurveList().push_back( outputCurve ); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wol...@us...> - 2012-02-21 14:24:43
|
Revision: 399 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=399&view=rev Author: wolfspindler Date: 2012-02-21 14:24:32 +0000 (Tue, 21 Feb 2012) Log Message: ----------- Typo fixed. Modified Paths: -------------- trunk/Community/General/Documentation/Sources/KnownIssues.txt Modified: trunk/Community/General/Documentation/Sources/KnownIssues.txt =================================================================== --- trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 14:23:16 UTC (rev 398) +++ trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 14:24:32 UTC (rev 399) @@ -10,7 +10,7 @@ The project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/Community/General/Sources/ML/MLCSOToRTStructure According to a bug in the windows installers of the MeVislab2.2.1 release - the library files oslog.lib and oflog_d.lib are missing. Since these files + the library files oflog.lib and oflog_d.lib are missing. Since these files are not needed by this project its link statement was manually removed from the windows <MeVisLabInstallPath>\Packages\MeVis\ThirdParty\Configuration\MeVis_ThirdParty.pri files in the installed MeVisLab versions. In this way this project can also This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wol...@us...> - 2012-02-21 14:23:26
|
Revision: 398 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=398&view=rev Author: wolfspindler Date: 2012-02-21 14:23:16 +0000 (Tue, 21 Feb 2012) Log Message: ----------- Described NSIS version problem. Modified Paths: -------------- trunk/Community/General/Documentation/Sources/KnownIssues.txt Modified: trunk/Community/General/Documentation/Sources/KnownIssues.txt =================================================================== --- trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 12:14:31 UTC (rev 397) +++ trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 14:23:16 UTC (rev 398) @@ -7,26 +7,29 @@ and can be changed by all people with permissions to change contents of the Community Sources. 1) MeVisLab2.2.1-Release - The project - https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/Community/General/Sources/ML/MLCSOToRTStructure - According to a bug in the windows installers of the MeVislab2.2.1 release - the library files oslog.lib and oflog_d.lib are missing. Since these files - are not needed by this project its link statement was manually removed - from the windows <MeVisLabInstallPath>\Packages\MeVis\ThirdParty\Configuration\MeVis_ThirdParty.pri - files in the installed MeVisLab versions. In this way this project can also - be compiled if you check out this project on your own. + The project + https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/Community/General/Sources/ML/MLCSOToRTStructure + According to a bug in the windows installers of the MeVislab2.2.1 release + the library files oslog.lib and oflog_d.lib are missing. Since these files + are not needed by this project its link statement was manually removed + from the windows <MeVisLabInstallPath>\Packages\MeVis\ThirdParty\Configuration\MeVis_ThirdParty.pri + files in the installed MeVisLab versions. In this way this project can also + be compiled if you check out this project on your own. 2) MeVisLab2.2.1-Release, VC10-64: - The projects - Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/UMD/METK/Sources/common/, - Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/UMD/METK/Sources/ML/METKLiftChart - and some other (dependent) projects fail due to a complex linker symbol - problem in the MLObjMgr project in the VC10-64 release of MeVisLab2.2.1. - This will be correctly fixed in the MeVisLab2.3 release, in the current VC10-64-setup it is done with a workaround - in the file - https://svn-mms.mt.mevis.lokal/dev/branches/mevislab/integration/MeVisLab/Standard/Configuration/MeVisLab_Standard.pri - by adding a linker flag allowing multiple linker symbols in the MLObjMgr project settings (l. 285): - contains(QMAKE_COMPILER_DEFINES, _MSC_VER=1600) { - win32:QMAKE_LFLAGS += /FORCE:MULTIPLE - } + The projects + Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/UMD/METK/Sources/common/, + Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/UMD/METK/Sources/ML/METKLiftChart + and some other (dependent) projects fail due to a complex linker symbol + problem in the MLObjMgr project in the VC10-64 release of MeVisLab2.2.1. + This will be correctly fixed in the MeVisLab2.3 release, in the current VC10-64-setup it is done with a workaround + in the file + https://svn-mms.mt.mevis.lokal/dev/branches/mevislab/integration/MeVisLab/Standard/Configuration/MeVisLab_Standard.pri + by adding a linker flag allowing multiple linker symbols in the MLObjMgr project settings (l. 285): + contains(QMAKE_COMPILER_DEFINES, _MSC_VER=1600) { + win32:QMAKE_LFLAGS += /FORCE:MULTIPLE + } +3) Although the ToolRunner of MeVisLab2.2.1 requires an NSIS version 2.36 or higher it must be a version 2.43 or + higher if you build your own installers against the release MeVisLab2.2.1 versions. An appropriate NSIS version + is installed on the CommunityBuild server. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wol...@us...> - 2012-02-21 12:14:40
|
Revision: 397 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=397&view=rev Author: wolfspindler Date: 2012-02-21 12:14:31 +0000 (Tue, 21 Feb 2012) Log Message: ----------- Added description for a linker problem workaround for VC10. Modified Paths: -------------- trunk/Community/General/Documentation/Sources/KnownIssues.txt Modified: trunk/Community/General/Documentation/Sources/KnownIssues.txt =================================================================== --- trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 10:56:16 UTC (rev 396) +++ trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 12:14:31 UTC (rev 397) @@ -9,7 +9,7 @@ 1) MeVisLab2.2.1-Release The project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/Community/General/Sources/ML/MLCSOToRTStructure - According to a bug in the the windows installers of the MeVislab2.2.1 release + According to a bug in the windows installers of the MeVislab2.2.1 release the library files oslog.lib and oflog_d.lib are missing. Since these files are not needed by this project its link statement was manually removed from the windows <MeVisLabInstallPath>\Packages\MeVis\ThirdParty\Configuration\MeVis_ThirdParty.pri @@ -22,5 +22,11 @@ Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/UMD/METK/Sources/ML/METKLiftChart and some other (dependent) projects fail due to a complex linker symbol problem in the MLObjMgr project in the VC10-64 release of MeVisLab2.2.1. - This will be fixed in the MeVisLab2.3 release. + This will be correctly fixed in the MeVisLab2.3 release, in the current VC10-64-setup it is done with a workaround + in the file + https://svn-mms.mt.mevis.lokal/dev/branches/mevislab/integration/MeVisLab/Standard/Configuration/MeVisLab_Standard.pri + by adding a linker flag allowing multiple linker symbols in the MLObjMgr project settings (l. 285): + contains(QMAKE_COMPILER_DEFINES, _MSC_VER=1600) { + win32:QMAKE_LFLAGS += /FORCE:MULTIPLE + } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wol...@us...> - 2012-02-21 10:56:22
|
Revision: 396 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=396&view=rev Author: wolfspindler Date: 2012-02-21 10:56:16 +0000 (Tue, 21 Feb 2012) Log Message: ----------- Minor changes for readability. Modified Paths: -------------- trunk/Community/General/Documentation/Sources/KnownIssues.txt Modified: trunk/Community/General/Documentation/Sources/KnownIssues.txt =================================================================== --- trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 10:54:50 UTC (rev 395) +++ trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 10:56:16 UTC (rev 396) @@ -7,19 +7,20 @@ and can be changed by all people with permissions to change contents of the Community Sources. 1) MeVisLab2.2.1-Release -Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/Community/General/Sources/ML/MLCSOToRTStructure -According to a bug in the the windows installers of the MeVislab2.2.1 release -the library files oslog.lib and oflog_d.lib are missing. Since these files -are not needed by this project its link statement was manually removed -from the windows <MeVisLabInstallPath>\Packages\MeVis\ThirdParty\Configuration\MeVis_ThirdParty.pri -files in the installed MeVisLab versions. In this way this project can also -be compiled if you check out this project on your own. + The project + https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/Community/General/Sources/ML/MLCSOToRTStructure + According to a bug in the the windows installers of the MeVislab2.2.1 release + the library files oslog.lib and oflog_d.lib are missing. Since these files + are not needed by this project its link statement was manually removed + from the windows <MeVisLabInstallPath>\Packages\MeVis\ThirdParty\Configuration\MeVis_ThirdParty.pri + files in the installed MeVisLab versions. In this way this project can also + be compiled if you check out this project on your own. 2) MeVisLab2.2.1-Release, VC10-64: -The projects -Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/UMD/METK/Sources/common/, -Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/UMD/METK/Sources/ML/METKLiftChart -and some other (dependent) projects fail due to a complex linker symbol -problem in the MLObjMgr project in the VC10-64 release of MeVisLab2.2.1. -This will be fixed in the MeVisLab2.3 release. + The projects + Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/UMD/METK/Sources/common/, + Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/UMD/METK/Sources/ML/METKLiftChart + and some other (dependent) projects fail due to a complex linker symbol + problem in the MLObjMgr project in the VC10-64 release of MeVisLab2.2.1. + This will be fixed in the MeVisLab2.3 release. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wol...@us...> - 2012-02-21 10:55:00
|
Revision: 395 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=395&view=rev Author: wolfspindler Date: 2012-02-21 10:54:50 +0000 (Tue, 21 Feb 2012) Log Message: ----------- Some project paths corrected. Modified Paths: -------------- trunk/Community/General/Documentation/Sources/KnownIssues.txt Modified: trunk/Community/General/Documentation/Sources/KnownIssues.txt =================================================================== --- trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 10:50:08 UTC (rev 394) +++ trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 10:54:50 UTC (rev 395) @@ -7,18 +7,18 @@ and can be changed by all people with permissions to change contents of the Community Sources. 1) MeVisLab2.2.1-Release -Project .../Packages/Community/General/Sources/ML/MLCSOToRTStructure +Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/Community/General/Sources/ML/MLCSOToRTStructure According to a bug in the the windows installers of the MeVislab2.2.1 release the library files oslog.lib and oflog_d.lib are missing. Since these files are not needed by this project its link statement was manually removed -from the windows Packages\MeVis\ThirdParty\Configuration\MeVis_ThirdParty.pri +from the windows <MeVisLabInstallPath>\Packages\MeVis\ThirdParty\Configuration\MeVis_ThirdParty.pri files in the installed MeVisLab versions. In this way this project can also be compiled if you check out this project on your own. 2) MeVisLab2.2.1-Release, VC10-64: The projects -Project .../Packages/UMD/METK/Sources/common, -Project .../Packages/UMD/METK/Sources/ML/METKLiftChart +Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/UMD/METK/Sources/common/, +Project https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/UMD/METK/Sources/ML/METKLiftChart and some other (dependent) projects fail due to a complex linker symbol problem in the MLObjMgr project in the VC10-64 release of MeVisLab2.2.1. This will be fixed in the MeVisLab2.3 release. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wol...@us...> - 2012-02-21 10:50:18
|
Revision: 394 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=394&view=rev Author: wolfspindler Date: 2012-02-21 10:50:08 +0000 (Tue, 21 Feb 2012) Log Message: ----------- Location link added. Modified Paths: -------------- trunk/Community/General/Documentation/Sources/KnownIssues.txt Modified: trunk/Community/General/Documentation/Sources/KnownIssues.txt =================================================================== --- trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 10:43:08 UTC (rev 393) +++ trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 10:50:08 UTC (rev 394) @@ -1,6 +1,11 @@ In this file known issues of the MeVisLab Community Builds are listed. +It is located in the Community sources repository under + https://mevislabmodules.svn.sourceforge.net/svnroot/mevislabmodules/trunk/Community/General/Documentation/Sources/KnownIssues.txt + +and can be changed by all people with permissions to change contents of the Community Sources. + 1) MeVisLab2.2.1-Release Project .../Packages/Community/General/Sources/ML/MLCSOToRTStructure According to a bug in the the windows installers of the MeVislab2.2.1 release This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wol...@us...> - 2012-02-21 10:43:19
|
Revision: 393 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=393&view=rev Author: wolfspindler Date: 2012-02-21 10:43:08 +0000 (Tue, 21 Feb 2012) Log Message: ----------- Added a file listing known issues of current community builds. Added Paths: ----------- trunk/Community/General/Documentation/Sources/KnownIssues.txt Added: trunk/Community/General/Documentation/Sources/KnownIssues.txt =================================================================== --- trunk/Community/General/Documentation/Sources/KnownIssues.txt (rev 0) +++ trunk/Community/General/Documentation/Sources/KnownIssues.txt 2012-02-21 10:43:08 UTC (rev 393) @@ -0,0 +1,20 @@ + +In this file known issues of the MeVisLab Community Builds are listed. + +1) MeVisLab2.2.1-Release +Project .../Packages/Community/General/Sources/ML/MLCSOToRTStructure +According to a bug in the the windows installers of the MeVislab2.2.1 release +the library files oslog.lib and oflog_d.lib are missing. Since these files +are not needed by this project its link statement was manually removed +from the windows Packages\MeVis\ThirdParty\Configuration\MeVis_ThirdParty.pri +files in the installed MeVisLab versions. In this way this project can also +be compiled if you check out this project on your own. + +2) MeVisLab2.2.1-Release, VC10-64: +The projects +Project .../Packages/UMD/METK/Sources/common, +Project .../Packages/UMD/METK/Sources/ML/METKLiftChart +and some other (dependent) projects fail due to a complex linker symbol +problem in the MLObjMgr project in the VC10-64 release of MeVisLab2.2.1. +This will be fixed in the MeVisLab2.3 release. + Property changes on: trunk/Community/General/Documentation/Sources/KnownIssues.txt ___________________________________________________________________ Added: svn:eol-style + native This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <bro...@us...> - 2012-02-06 16:23:43
|
Revision: 392 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=392&view=rev Author: broersen Date: 2012-02-06 16:23:32 +0000 (Mon, 06 Feb 2012) Log Message: ----------- ENH: Implemented patch to fix 'Hazardous situation' in the third point from the list of Jens Kaftan Added Paths: ----------- trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/mlMatlabScriptWrapperOutputData.h Added: trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/mlMatlabScriptWrapperOutputData.h =================================================================== --- trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/mlMatlabScriptWrapperOutputData.h (rev 0) +++ trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/mlMatlabScriptWrapperOutputData.h 2012-02-06 16:23:32 UTC (rev 392) @@ -0,0 +1,105 @@ +//---------------------------------------------------------------------------------- +//! The ML module class MatlabScriptWrapper. +/*! +// \file mlMatlabScriptWrapperOutputData.h +// \author Jens Kaftan, Alexander Broersen +// \date 2010-09-15 +// +// Class for storing output data created in Matlab +*/ +//---------------------------------------------------------------------------------- + + +#ifndef __mlMatlabScriptWrapperOutputData_H +#define __mlMatlabScriptWrapperOutputData_H + +// SDK includes +#include <mlBasics.h> + +// Include the Matlab engine. Note that the correct path to this +// file must be set in the MLMatlabScriptWrapper.pro file. +#include "engine.h" + +ML_START_NAMESPACE + +//! The output memory management class used in MatlabScriptWrapper +class MatlabScriptWrapperOutputData +{ +public: + //! Constructor. + MatlabScriptWrapperOutputData (void) + { + _data = NULL; + _dataClass = ML_BAD_DATA_TYPE; + _ext = Vector(); + _minval = 0; + _maxval = 0; + }; + //! Destructor. + ~MatlabScriptWrapperOutputData () + { + if(_data) { + delete []_data; + _data = NULL; + } + }; + + //! Copy new data to class (and deallocate old data if existent) + void SetData(const Vector& extend, const MLPhysicalDataType datatype, const double* data) + { + if(_data != NULL) { + delete []_data; + _data = NULL; + } + _ext = extend; + _dataClass = datatype; + + SubImgBox temp = SubImgBox(extend); + int elementSize = 0; + try { + switch (_dataClass) { + case MLdoubleType: elementSize = sizeof(double); _data = new double[temp.getSize()]; break; + case MLfloatType: elementSize = sizeof(float); _data = new float[temp.getSize()]; break; + case MLint8Type: elementSize = sizeof(int8_T); _data = new int8_T[temp.getSize()]; break; + case MLuint8Type: elementSize = sizeof(uint8_T); _data = new uint8_T[temp.getSize()]; break; + case MLint16Type: elementSize = sizeof(int16_T); _data = new int16_T[temp.getSize()]; break; + case MLuint16Type: elementSize = sizeof(uint16_T); _data = new uint16_T[temp.getSize()]; break; + case MLint32Type: elementSize = sizeof(int32_T); _data = new int32_T[temp.getSize()]; break; + case MLuint32Type: elementSize = sizeof(uint32_T); _data = new uint32_T[temp.getSize()]; break; + case MLint64Type: + default: + std::cerr << "MatlabScriptWrapperOutputData::SetData - Output type from Matlab not supported" << std::endl; + } + if(_data != NULL) { + memcpy(_data, data, temp.getSize()*elementSize); + } + } + catch(std::bad_alloc) { + std::cerr << "MatlabScriptWrapperOutputData::SetData - " << "error during memory allocation" << std::endl; + } + }; + + void SetMinMaxValue(const MLldouble min, const MLldouble max) + { + _minval = min; + _maxval = max; + }; + + inline void* GetData() { return(_data); }; + inline MLPhysicalDataType GetDataType() { return(_dataClass); }; + inline Vector GetExtend() { return(_ext); }; + inline MLldouble GetMinValue() { return(_minval); }; + inline MLldouble GetMaxValue() { return(_maxval); }; + +private: + void* _data; + MLPhysicalDataType _dataClass; + Vector _ext; + MLldouble _minval; + MLldouble _maxval; +}; + +ML_END_NAMESPACE + + +#endif // __mlMatlabScriptWrapperOutputData_H This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <bro...@us...> - 2012-02-06 16:19:38
|
Revision: 391 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=391&view=rev Author: broersen Date: 2012-02-06 16:19:28 +0000 (Mon, 06 Feb 2012) Log Message: ----------- DOC: Updated documentation Modified Paths: -------------- trunk/Community/General/Modules/ML/MLMatlabScriptWrapper/MLMatlabScriptWrapper.def trunk/Community/General/Modules/ML/MLMatlabScriptWrapper/html/MatlabScriptWrapper.html trunk/Community/General/Modules/ML/MLMatlabScriptWrapper/mhelp/MatlabScriptWrapper.mhelp Modified: trunk/Community/General/Modules/ML/MLMatlabScriptWrapper/MLMatlabScriptWrapper.def =================================================================== --- trunk/Community/General/Modules/ML/MLMatlabScriptWrapper/MLMatlabScriptWrapper.def 2012-02-06 16:18:30 UTC (rev 390) +++ trunk/Community/General/Modules/ML/MLMatlabScriptWrapper/MLMatlabScriptWrapper.def 2012-02-06 16:19:28 UTC (rev 391) @@ -23,6 +23,11 @@ documentation = "$(LOCAL)/html/MatlabScriptWrapper.html" exampleNetwork = "$(LOCAL)/networks/MatlabScriptWrapperExample.mlab" + Description { + Field status { persistent = No } + Field matlabOutput { persistent = No } + } + Window { width = 600 Category Main { Modified: trunk/Community/General/Modules/ML/MLMatlabScriptWrapper/html/MatlabScriptWrapper.html =================================================================== --- trunk/Community/General/Modules/ML/MLMatlabScriptWrapper/html/MatlabScriptWrapper.html 2012-02-06 16:18:30 UTC (rev 390) +++ trunk/Community/General/Modules/ML/MLMatlabScriptWrapper/html/MatlabScriptWrapper.html 2012-02-06 16:19:28 UTC (rev 391) @@ -145,7 +145,7 @@ <h3><a name="inputs"></a>Inputs</h3> <blockquote style="margin-top: 5pt; margin-bottom: 5pt;"> -Up to three input images and one CurveData, CurveList, XMarkerList , or WEM can be attached to the module. +Up to three input images and one CurveData, CurveList, XMarkerList, or WEM can be attached to the module. Input to the module from MeVisLab is optional, the output can be generated entirely in Matlab without input from MeVisLab (see the example network for examples). </blockquote> Modified: trunk/Community/General/Modules/ML/MLMatlabScriptWrapper/mhelp/MatlabScriptWrapper.mhelp =================================================================== --- trunk/Community/General/Modules/ML/MLMatlabScriptWrapper/mhelp/MatlabScriptWrapper.mhelp 2012-02-06 16:18:30 UTC (rev 390) +++ trunk/Community/General/Modules/ML/MLMatlabScriptWrapper/mhelp/MatlabScriptWrapper.mhelp 2012-02-06 16:19:28 UTC (rev 391) @@ -1,3 +1,4 @@ +// MDL v1 latin1 ModuleHelp { MetaInformation { definition = Modules/MLMatlabScriptWrapper.def @@ -53,24 +54,12 @@ - **WEMs:** A Winged Edge Mesh (`WEM <http://www.mevislab.de/docs/2.0/MeVisLab/Resources/Documentation/Publish/SDK/ToolBoxReference/WEMPage.html>`_) is an object that contains a representation of a surface. In Matlab, a WEM is represented as a cell array - of structures with nodes (markers of vertices with a color, size, and style), faces (with a diffuse color - and alpha), edges (with a color, size, and style), a description (`Tag <http://www.mathworks.com/help/techdoc/ref/patch_props.html#Tag>`_) - and a label (`DisplayName <http://www.mathworks.com/help/techdoc/ref/patch_props.html#DisplayName>`_). + of structures with nodes (markers of vertices), faces, and edges. Optionally, if a WEM contains a Look Up Table (`LUT <http://www.mevislab.de/docs/2.0/MeVisLab/Resources/Documentation/Publish/SDK/ToolBoxReference/MLLUTPage.html>`_), - this data will be put into the `CData <http://www.mathworks.com/help/techdoc/ref/patch_props.html#CData>`_ + this data will be put into the `FaceVertexCData <http://www.mathworks.com/help/techdoc/ref/patch_props.html#FaceVertexCData>`_ field. These structures can be exchanged directly with the `Matlab Patch Properties <http://www.mathworks.com/help/techdoc/ref/patch_props.html>`_. See the example network for an example. -- **Mat4Lists (input only):** - A `Mat4List <http://www.mevislab.de/docs/2.0/MeVisLab/Resources/Documentation/Publish/SDK/ToolBoxReference/mlLinearAlgebraPage.html>`_ - is an object that contains a list of 4x4 matrices. In Matlab, a Mat4List is represented as a cell array - with in each cell a 4x4 integer matrix. - -- **CSOLists (input only):** - A Contour Segmentation Object (`CSO <http://www.mevislab.de/docs/2.0/MeVisLab/Resources/Documentation/Publish/SDK/ToolBoxReference/CSOPage.html>`_)List - is an object that contains a list of CSOs. In Matlab, a CSOList is represented as a cell array with in - each cell an *N* x3 integer matrix with the position coordinates of one CSO. - - **Scalars:** Double precision. These can be used both as input and ouput variables. Field notifications will be sent in MeVisLab only if a scalar has changed its value after the Matlab script execution. @@ -113,20 +102,20 @@ text = "" } Tips { - text = "" + text = "The example network shows a number of different uses of the :module:`MatlabScriptWrapper` module." } Windows { text = "" Window _default { - title = "" + title = "The default panel of the MatlabScriptWrapper." text = ".. screenshot:: _default" } } Inputs { - text = "Up to three input images and one CurveData, CurveList, XMarkerList , or WEM can be attached to the module. Input to the module from MeVisLab is optional, the output can be generated entirely in Matlab without input from MeVisLab (see the example network for examples)." + text = "Up to three input Images and one CurveData, CurveList, XMarkerList , or WEM can be attached to the module. Input to the module from MeVisLab is optional, the output can be generated entirely in Matlab without input from MeVisLab (see the example network for examples)." Field input0 { type = Image - text = "" + text = "The input image." } Field input1 { type = Image @@ -150,10 +139,10 @@ } } Outputs { - text = "Up to three output images and one CurveList, one XMarkerList, or one WEM." + text = "Up to three output Images and one CurveList, one XMarkerList, or one WEM." Field output0 { type = Image - text = "" + text = "The output Image." } Field output1 { type = Image @@ -196,7 +185,7 @@ } Field useExternalScript { type = Bool - text = "Enables the possibility to use an external Matlab script file (.m)." + text = "Enables the possibility to use an external Matlab script file (`.m`)." title = "Use External Script" visibleInGUI = Yes persistent = Yes @@ -204,7 +193,7 @@ } Field matlabScriptPath { type = String - text = "" + text = "The path and the name of the external Matlab script file (`.m`)." title = "Matlab Script" visibleInGUI = Yes persistent = Yes @@ -316,7 +305,7 @@ } Field autoUpdate { type = Bool - text = "Execute the script automatically on input change (only for input images, CurveData, CurveList, XMarkerList, and WEM, not for changes in the names)." + text = "Execute the script automatically on input change (only for input Images, CurveData, CurveList, XMarkerList, and WEM, not for changes in the names)." title = "Auto update" visibleInGUI = Yes persistent = Yes @@ -343,8 +332,8 @@ text = "This field gives information whether the Matlab script was executed correctly or not." title = Status visibleInGUI = Yes - persistent = Yes - default = Ready. + persistent = No + default = "" } Field scalarName0 { type = String @@ -708,7 +697,7 @@ text = "Displays the output of executed Matlab script." title = "Matlab Output" visibleInGUI = Yes - persistent = Yes + persistent = No default = "" } Field showSessionWindow { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <bro...@us...> - 2012-02-06 16:18:41
|
Revision: 390 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=390&view=rev Author: broersen Date: 2012-02-06 16:18:30 +0000 (Mon, 06 Feb 2012) Log Message: ----------- ENH: Implemented patch to fix 'Hazardous situation' in the third point from the list of Jens Kaftan Modified Paths: -------------- trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/MLMatlabScriptWrapper.pro trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/mlMatlabScriptWrapper.cpp trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/mlMatlabScriptWrapper.h Modified: trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/MLMatlabScriptWrapper.pro =================================================================== --- trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/MLMatlabScriptWrapper.pro 2012-01-24 13:27:49 UTC (rev 389) +++ trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/MLMatlabScriptWrapper.pro 2012-02-06 16:18:30 UTC (rev 390) @@ -122,7 +122,8 @@ HEADERS += \ MLMatlabScriptWrapperInit.h \ MLMatlabScriptWrapperSystem.h \ - mlMatlabScriptWrapper.h + mlMatlabScriptWrapper.h \ + mlMatlabScriptWrapperOutputData.h SOURCES += \ MLMatlabScriptWrapperInit.cpp \ @@ -131,5 +132,4 @@ # additional files that are NOT compiled RELATEDFILES += \ ../../../Modules/ML/MLMatlabScriptWrapper/MLMatlabScriptWrapper.def - Modified: trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/mlMatlabScriptWrapper.cpp =================================================================== --- trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/mlMatlabScriptWrapper.cpp 2012-01-24 13:27:49 UTC (rev 389) +++ trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/mlMatlabScriptWrapper.cpp 2012-02-06 16:18:30 UTC (rev 390) @@ -26,7 +26,7 @@ //! The ML module class MatlabScriptWrapper. /*! // \file mlMatlabScriptWrapper.cpp -// \author Alexander Gryanik, Markus Harz, Ola Friman, Felix Ritter, Alexander Broersen +// \author Alexander Gryanik, Markus Harz, Ola Friman, Felix Ritter, Alexander Broersen, Jens Kaftan // \date 2009-02-23 // // Module for executing Matlab scripts in MeVisLab. @@ -99,6 +99,11 @@ (_outDataNameFld[0] = fields->addString("outDataName0"))->setStringValue("Output0"); (_outDataNameFld[1] = fields->addString("outDataName1"))->setStringValue("Output1"); (_outDataNameFld[2] = fields->addString("outDataName2"))->setStringValue("Output2"); + + //! Init output subimg array. + for(int i=0; i<3; i++) { + _outDataArray[i] = NULL; + } //! Set input and output XMarker names used in Matlab. (_inXMarkerNameFld = fields->addString("inXMarkerName"))->setStringValue("inXMarker"); (_outXMarkerNameFld = fields->addString("outXMarkerName"))->setStringValue("outXMarker"); @@ -244,6 +249,13 @@ { ML_TRACE_IN("MatlabScriptWrapper::~MatlabScriptWrapper()"); + for(int i=0; i<3; i++) { + if(_outDataArray[i] != NULL) { + delete(_outDataArray[i]); + _outDataArray[i] = NULL; + } + } + if (m_pEngine != NULL) { engClose(m_pEngine); } @@ -458,6 +470,8 @@ // Notify image attachments that are new images calculated so that they // update themselves and call the calcOutSubImage() + _getOutputImageDataBackFromMatlab(); + getOutField(0)->notifyAttachments(); getOutField(1)->notifyAttachments(); getOutField(2)->notifyAttachments(); @@ -519,69 +533,24 @@ return; } - // Get variable name in the Matlab workspace of the output image - std::string outname = _outDataNameFld[outIndex]->getStringValue(); - mxArray *m_pImage = engGetVariable(m_pEngine, outname.c_str()); - // If we can find the variable and calculate its size, go on. - if(m_pImage != NULL) - { - const mwSize m_numDims = mxGetNumberOfDimensions(m_pImage); - if(m_numDims>6) { - std::cerr << "calcOutImageProps(): Too many dimensions in Matlab image!" << std::endl << std::flush; - return; - } - Vector outExt = Vector(1,1,1,1,1,1); - for (size_t i=0; i<m_numDims; i++) { - outExt[i] = static_cast<MLint>(mxGetDimensions(m_pImage)[i]); - } + if((_outDataArray[outIndex] != NULL)) { + Vector outExt = _outDataArray[outIndex]->GetExtend(); // Set page size. getOutImg(outIndex)->setPageExt(outExt); // Set output image size. getOutImg(outIndex)->setImgExt(outExt); - // Set output image datatypes. - switch (mxGetClassID(m_pImage)) { - case mxDOUBLE_CLASS: getOutImg(outIndex)->setDataType(MLdoubleType); __setInSubImageDataType(MLdoubleType); break; - case mxSINGLE_CLASS: getOutImg(outIndex)->setDataType(MLfloatType); __setInSubImageDataType(MLdoubleType); break; - case mxINT8_CLASS: getOutImg(outIndex)->setDataType(MLint8Type); __setInSubImageDataType(MLdoubleType); break; - case mxUINT8_CLASS: getOutImg(outIndex)->setDataType(MLuint8Type); __setInSubImageDataType(MLdoubleType); break; - case mxINT16_CLASS: getOutImg(outIndex)->setDataType(MLint16Type); __setInSubImageDataType(MLdoubleType); break; - case mxUINT16_CLASS: getOutImg(outIndex)->setDataType(MLuint16Type); __setInSubImageDataType(MLdoubleType); break; - case mxINT32_CLASS: getOutImg(outIndex)->setDataType(MLint32Type); __setInSubImageDataType(MLdoubleType); break; - case mxUINT32_CLASS: getOutImg(outIndex)->setDataType(MLuint32Type); __setInSubImageDataType(MLdoubleType); break; - case mxINT64_CLASS: // Matlab does not support basic operations on this type - //getOutImg(outIndex)->setDataType(MLint64Type); - //break; - default: - getOutImg(outIndex)->setDataType(ML_BAD_DATA_TYPE); - std::cerr << "calcOutImageProps(): Output type from Matlab not supported" << std::endl << std::flush; - } - mxDestroyArray(m_pImage); m_pImage = NULL; + // Set output image datatype. + getOutImg(outIndex)->setDataType( _outDataArray[outIndex]->GetDataType() ); __setInSubImageDataType(MLdoubleType); // Get min and max values in Matlab workspace and set them in MeVisLab - std::ostringstream minmaxCommand; - minmaxCommand << "mevtmpminval = min(" << outname << "(:));" << "mevtmpmaxval = max(" << outname << "(:));"; - engEvalString(m_pEngine, minmaxCommand.str().c_str()); - mxArray *minVal = engGetVariable(m_pEngine, "mevtmpminval"); - mxArray *maxVal = engGetVariable(m_pEngine, "mevtmpmaxval"); - // if min and max are not defined, set default values - if ((minVal==NULL) || (minVal==NULL)) { - getOutImg(outIndex)->setMinVoxelValue(0); - getOutImg(outIndex)->setMaxVoxelValue(127); - } else { - getOutImg(outIndex)->setMinVoxelValue(mxGetScalar(minVal)); - getOutImg(outIndex)->setMaxVoxelValue(mxGetScalar(maxVal)); - } - mxDestroyArray(minVal); minVal = NULL; - mxDestroyArray(maxVal); maxVal = NULL; - engEvalString(m_pEngine, "clear mevtmpminval mevtmpmaxval"); - } else { + getOutImg(outIndex)->setMinVoxelValue( _outDataArray[outIndex]->GetMinValue() ); + getOutImg(outIndex)->setMaxVoxelValue( _outDataArray[outIndex]->GetMaxValue() ); + } // if((_outDataArray[outIndex] != NULL)) + else { getOutImg(outIndex)->setOutOfDate(); getOutImg(outIndex)->setStateInfo("Cannot set output size, because variable could not be found in Matlab workspace.",ML_BAD_DATA_TYPE); - std::ostringstream msg; - msg << "Could not find the variable " << outname << " for output image number " << outIndex << " in the Matlab workspace."; - ML_PRINT_ERROR("MatlabScriptWrapper::calcOutImageProps", msg.str().c_str(), "Output will be invalid."); } } @@ -608,7 +577,7 @@ { ML_TRACE_IN("MatlabScriptWrapper::calcInSubImageBox ()"); - return outSubImgBox; + return SubImgBox(Vector(0), Vector(-1)); } //---------------------------------------------------------------------------------- @@ -625,38 +594,13 @@ return; } - // Get matlab image data. - const std::string matlabVariableName = _outDataNameFld[outIndex]->getStringValue(); - mxArray *m_pImage = engGetVariable(m_pEngine, matlabVariableName.c_str()); - - if ( m_pImage != NULL) { - // Copy different types of images from Matlab. - MLPhysicalDataType outputClass; - switch (mxGetClassID(m_pImage)) { - case mxDOUBLE_CLASS: outputClass = MLdoubleType; break; - case mxSINGLE_CLASS: outputClass = MLfloatType; break; - case mxINT8_CLASS: outputClass = MLint8Type; break; - case mxUINT8_CLASS: outputClass = MLuint8Type; break; - case mxINT16_CLASS: outputClass = MLint16Type; break; - case mxUINT16_CLASS: outputClass = MLuint16Type; break; - case mxINT32_CLASS: outputClass = MLint32Type; break; - case mxUINT32_CLASS: outputClass = MLuint32Type; break; - case mxINT64_CLASS: // Matlab does not support basic operations on this type - //outputClass = MLint64Type; - //break; - default: - outputClass = ML_BAD_DATA_TYPE; - std::cerr << "calcOutSubImage(): Output type from Matlab not supported" << std::endl << std::flush; - } - SubImg subImgBuf(outSubImg->getBox(), outputClass, mxGetPr(m_pImage)); + if ( (_outDataArray[outIndex] != NULL) ) { + SubImg subImgBuf(SubImgBox(_outDataArray[outIndex]->GetExtend()), _outDataArray[outIndex]->GetDataType(), _outDataArray[outIndex]->GetData()); outSubImg->copySubImage(subImgBuf); - mxDestroyArray(m_pImage); m_pImage = NULL; } else { // Throw error if the variable could not be found in the Matlab workspace. - // NOTE: This is also checked in calcOutSubImgProps() above, so execution should never enter here. - std::ostringstream msg; - msg << "Could not find the variable " << matlabVariableName << " for output number " << outIndex << " in the Matlab workspace."; - ML_PRINT_ERROR("MatlabScriptWrapper::calcOutSubImage()", msg.str().c_str(), "Output will be empty"); + outSubImg->fillSubImg(0.0); + //ML_PRINT_ERROR("MatlabScriptWrapper::calcOutSubImage()", ML_BAD_INPUT_IMAGE_POINTER, "Cannot copy from Matlab data."); } } @@ -843,7 +787,7 @@ } // Need also to have storage for complete output image. - const MLuint inDataSize = imgSize.x*imgSize.y*imgSize.z*imgSize.c*imgSize.t*imgSize.u; + const MLuint32 inDataSize = imgSize.x*imgSize.y*imgSize.z*imgSize.c*imgSize.t*imgSize.u; // Set Matlab image extent. const mwSize insizesArray[6] = {imgSize.x, imgSize.y, imgSize.z, imgSize.c, imgSize.t, imgSize.u}; @@ -866,30 +810,20 @@ elementSize = sizeof(double); std::cerr << "_copyInputImageDataToMatlab(): Output type from MeVisLab not supported" << std::endl << std::flush; } - + // Create numeric array mxArray *m_pImage = mxCreateNumericArray(6, insizesArray, inputClass, mxREAL); - if(m_pImage == NULL) { - std::ostringstream msg; - msg << "Could not allocate matrix for input image " << i << " in Matlab."; - ML_PRINT_ERROR("MatlabScriptWrapper::copyInputImageDataToMatlab()", msg.str().c_str(), "Matrix will not be created in Matlab."); - } else { - // Copy data to Matlab array. - memcpy((void*)mxGetPr(m_pImage), data, inDataSize*elementSize); - // Get input names from GUI. - const std::string inputName = _inDataNameFld[i]->getStringValue(); + // Copy data to Matlab array. + memcpy((void*)mxGetPr(m_pImage), data, inDataSize*elementSize); - // Write data to Matlab. - int status = engPutVariable(m_pEngine, inputName.c_str(), m_pImage); - if(status != 0) { - std::ostringstream msg; - msg << "Could not put data for image " << i << " in Matlab."; - ML_PRINT_ERROR("MatlabScriptWrapper::copyInputImageDataToMatlab()", msg.str().c_str(), "Matrix will not be created in Matlab."); - } + // Get input names from GUI. + std::string inputName = _inDataNameFld[i]->getStringValue(); + // Write data to Matlab. + engPutVariable(m_pEngine, inputName.c_str(), m_pImage); - mxDestroyArray(m_pImage); m_pImage = NULL; - } + mxDestroyArray(m_pImage); m_pImage = NULL; + // Free allocated memory for holding a slice. freeTile(data); data = NULL; @@ -897,6 +831,84 @@ } } +void MatlabScriptWrapper::_getOutputImageDataBackFromMatlab() +{ + for(int i=0; i<3; i++) { + if(_outDataArray[i] != NULL) { + delete(_outDataArray[i]); + _outDataArray[i] = NULL; + } + } + + // Check if Matlab is started. + if (!_checkMatlabIsStarted()) + { + std::cerr << "_getOutputImageDataBackFromMatlab(): Cannot find Matlab engine!" << std::endl << std::flush; + return; + } + + for(int outIndex=0; outIndex<3; outIndex++) { + // Get Matlab image data. + std::string outname = _outDataNameFld[outIndex]->getStringValue(); + mxArray *m_pImage = engGetVariable(m_pEngine, outname.c_str()); + + if ( (m_pImage != NULL) ) { + const mwSize m_numDims = mxGetNumberOfDimensions(m_pImage); + if(m_numDims>6) { + std::cerr << "_getOutputImageDataBackFromMatlab(): Too many dimensions in Matlab image!" << std::endl << std::flush; + return; + } + Vector outExt = Vector(1,1,1,1,1,1); + for (size_t i=0; i<m_numDims; i++) { + outExt[i] = static_cast<MLint>(mxGetDimensions(m_pImage)[i]); + } + + // Copy different types of images from Matlab. + MLPhysicalDataType outputClass; + switch (mxGetClassID(m_pImage)) { + case mxDOUBLE_CLASS: outputClass = MLdoubleType; break; + case mxSINGLE_CLASS: outputClass = MLfloatType; break; + case mxINT8_CLASS: outputClass = MLint8Type; break; + case mxUINT8_CLASS: outputClass = MLuint8Type; break; + case mxINT16_CLASS: outputClass = MLint16Type; break; + case mxUINT16_CLASS: outputClass = MLuint16Type; break; + case mxINT32_CLASS: outputClass = MLint32Type; break; + case mxUINT32_CLASS: outputClass = MLuint32Type; break; + default: + outputClass = ML_BAD_DATA_TYPE; + std::cerr << "_getOutputImageDataBackFromMatlab(): Output type from Matlab not supported" << std::endl << std::flush; + } + + _outDataArray[outIndex] = new MatlabScriptWrapperOutputData(); + _outDataArray[outIndex]->SetData( outExt, outputClass, mxGetPr(m_pImage) ); + + mxDestroyArray(m_pImage); + m_pImage = NULL; + + // Get min and max values in Matlab workspace and set them in MeVisLab + std::ostringstream minmaxCommand; + minmaxCommand << "mevtmpminval = min(" << outname << "(:));" << "mevtmpmaxval = max(" << outname << "(:));"; + engEvalString(m_pEngine, minmaxCommand.str().c_str()); + mxArray *minVal = engGetVariable(m_pEngine, "mevtmpminval"); + mxArray *maxVal = engGetVariable(m_pEngine, "mevtmpmaxval"); + // if min and max are not defined, set default values + if ((minVal==NULL) || (minVal==NULL)) { + _outDataArray[outIndex]->SetMinMaxValue(0,127); + } else { + _outDataArray[outIndex]->SetMinMaxValue(mxGetScalar(minVal), mxGetScalar(maxVal)); + } + mxDestroyArray(minVal); minVal = NULL; + mxDestroyArray(maxVal); maxVal = NULL; + engEvalString(m_pEngine, "clear mevtmpminval mevtmpmaxval"); + } // if ( (m_pImage != NULL) ) + else + { + // Throw error, if no data available. + // ML_PRINT_ERROR("MatlabScriptWrapper::calcOutSubImage()", ML_BAD_INPUT_IMAGE_POINTER, "Cannot copy from Matlab data."); + } + } // for outindex +} + //! Copy input CurveData or CurveList to Matlab. void MatlabScriptWrapper::_copyInputCurveToMatlab() { Modified: trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/mlMatlabScriptWrapper.h =================================================================== --- trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/mlMatlabScriptWrapper.h 2012-01-24 13:27:49 UTC (rev 389) +++ trunk/Community/General/Sources/ML/MLMatlabScriptWrapper/mlMatlabScriptWrapper.h 2012-02-06 16:18:30 UTC (rev 390) @@ -26,7 +26,7 @@ //! The ML module class MatlabScriptWrapper. /*! // \file mlMatlabScriptWrapper.h -// \author Alexander Gryanik, Markus Harz, Ola Friman, Felix Ritter, Alexander Broersen +// \author Alexander Gryanik, Markus Harz, Ola Friman, Felix Ritter, Alexander Broersen, Jens Kaftan // \date 2009-02-23 // // Module for executing Matlab scripts in MeVisLab. @@ -40,6 +40,7 @@ // Local includes #include "MLMatlabScriptWrapperSystem.h" +#include "mlMatlabScriptWrapperOutputData.h" // SDK includes #include <mlVersion.h> @@ -51,10 +52,6 @@ // System includes #include <string> -// Include the Matlab engine. Note that the correct path to this -// file must be set in the MLMatlabScriptWrapper.pro file. -#include "engine.h" - ML_START_NAMESPACE //! The ML module class MatlabScriptWrapper. @@ -134,6 +131,9 @@ //! Copies input image data to Matlab. void _copyInputImageDataToMatlab(); + //! Copies output image from Matlab. + void _getOutputImageDataBackFromMatlab(); + //! Copies input CurveData or CurveList to Matlab. void _copyInputCurveToMatlab(); //! Copies structure from Matlab and copies results into output CurveList. @@ -204,6 +204,10 @@ StringField *_inDataNameFld[3]; StringField *_outDataNameFld[3]; //@} + //{@ The interal variables with the temporary output images. + MatlabScriptWrapperOutputData *_outDataArray[3]; + //@} + //{@ Set matlab names for input and output CurveList. StringField *_inCurveNameFld; StringField *_outCurveNameFld; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rha...@us...> - 2012-01-24 13:27:58
|
Revision: 389 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=389&view=rev Author: rhameeteman Date: 2012-01-24 13:27:49 +0000 (Tue, 24 Jan 2012) Log Message: ----------- KH. * Added the average values of the minimum, mean and maximum CSO distances. Modified Paths: -------------- trunk/Community/General/Modules/ML/MLCSOCommunityModules/MLCSOCommunityModules.def trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.h Modified: trunk/Community/General/Modules/ML/MLCSOCommunityModules/MLCSOCommunityModules.def =================================================================== --- trunk/Community/General/Modules/ML/MLCSOCommunityModules/MLCSOCommunityModules.def 2011-12-16 16:31:05 UTC (rev 388) +++ trunk/Community/General/Modules/ML/MLCSOCommunityModules/MLCSOCommunityModules.def 2012-01-24 13:27:49 UTC (rev 389) @@ -21,6 +21,9 @@ Window { Category Totals { Field minimumDistance { edit = NO minLength = 10 } + Field averageMinimumDistance { edit = NO minLength = 10 } + Field averageMeanDistance { edit = NO minLength = 10 } + Field averageMaximumDistance { edit = NO minLength = 10 } Separator { direction = Horizontal } Field minimumDistancePoint1 { minLength = 10 } Field minimumDistancePoint2 { minLength = 10 } @@ -50,6 +53,7 @@ ListView distances { expandY = Yes columnSeparator = "," + //sortByColumn = 0 } } } Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp 2011-12-16 16:31:05 UTC (rev 388) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp 2012-01-24 13:27:49 UTC (rev 389) @@ -41,6 +41,10 @@ (_minimumDistancePoint2Fld = fieldC->addVec3f("minimumDistancePoint2"))->setVec3fValue(vec3(0.0,0.0,0.0)); _distancesFld = addString("distances",_tableHeader ); + _AverageMinimumDistanceFld = addFloat("averageMinimumDistance", 0.0f ); + _AverageMeanDistanceFld = addFloat("averageMeanDistance", 0.0f ); + _AverageMaxDistanceFld = addFloat("averageMaximumDistance", 0.0f ); + ////////////////////////////////////////////////////////////////////////// _tolleranceFld = addDouble("tollerance", 0.0001 ); @@ -248,6 +252,9 @@ double minDist = ML_DOUBLE_MAX; vec3 point1; vec3 point2; + float averageMinDistance = 0.0f; + float averageMeanDistance = 0.0f; + float averageMaxDistance = 0.0f; for ( int iCSO = 0; iCSO<nCSOs; ++iCSO ){ CSO* currentCSO = _csoList0->getCSOAt( iCSO ); CSO* matchingCSO = _findMatchingCSO(iCSO); @@ -264,6 +271,10 @@ minDistance,maxDistance,avgDistance,stdDevDistance, minPoint1,minPoint2,maxPoint1,maxPoint2); + averageMinDistance += minDistance; + averageMeanDistance += avgDistance; + averageMaxDistance += maxDistance; + distances << currentCSO->getId() << "," << matchingCSO->getId() << "," << minDistance << "," @@ -299,6 +310,10 @@ break; } } // iCSO + averageMinDistance /= (nCSOs != 0 ? nCSOs : 1.0); + averageMeanDistance /= (nCSOs != 0 ? nCSOs : 1.0); + averageMaxDistance /= (nCSOs != 0 ? nCSOs : 1.0); + outputCurve->setY( nCSOs, yValues); delete[] yValues; _outputCurveList->getCurveList().push_back( outputCurve ); @@ -306,6 +321,13 @@ _minimumDistancePoint1Fld->setVec3fValue(point1); _minimumDistancePoint2Fld->setVec3fValue(point2); _minimumDistanceFld->setFloatValue( static_cast<float>(minDistance) ); + + _AverageMinimumDistanceFld->setFloatValue( averageMinDistance ); + _AverageMeanDistanceFld->setFloatValue( averageMeanDistance ); + _AverageMaxDistanceFld->setFloatValue( averageMaxDistance ); + + + break; } default: Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.h =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.h 2011-12-16 16:31:05 UTC (rev 388) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.h 2012-01-24 13:27:49 UTC (rev 389) @@ -69,6 +69,10 @@ //! Field for holding the distances per cso StringField* _distancesFld; + FloatField* _AverageMinimumDistanceFld; + FloatField* _AverageMeanDistanceFld; + FloatField* _AverageMaxDistanceFld; + //! Apply field NotifyField* _applyFld; //! Auto apply field This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <coe...@us...> - 2011-12-16 16:31:16
|
Revision: 388 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=388&view=rev Author: coertmetz Date: 2011-12-16 16:31:05 +0000 (Fri, 16 Dec 2011) Log Message: ----------- CM: There was an unwanted space added. Modified Paths: -------------- trunk/Community/General/Modules/Macros/Strings/FormatFloat.py Modified: trunk/Community/General/Modules/Macros/Strings/FormatFloat.py =================================================================== --- trunk/Community/General/Modules/Macros/Strings/FormatFloat.py 2011-10-11 07:41:11 UTC (rev 387) +++ trunk/Community/General/Modules/Macros/Strings/FormatFloat.py 2011-12-16 16:31:05 UTC (rev 388) @@ -43,10 +43,14 @@ stringList = stringValue.split() outString = '' format = ctx.field("format").stringValue() + first = True for string in stringList : try: value = float(string) - outString += format % value + ' ' + outString += format % value + if not first: + outString += ' ' + first = False except : outString += ' ' ctx.field("output").setStringValue( outString ) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rha...@us...> - 2011-10-11 07:41:22
|
Revision: 387 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=387&view=rev Author: rhameeteman Date: 2011-10-11 07:41:11 +0000 (Tue, 11 Oct 2011) Log Message: ----------- KH. * Added match on index of two lists Modified Paths: -------------- trunk/Community/General/Modules/ML/MLCSOCommunityModules/MLCSOCommunityModules.def trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.h Modified: trunk/Community/General/Modules/ML/MLCSOCommunityModules/MLCSOCommunityModules.def =================================================================== --- trunk/Community/General/Modules/ML/MLCSOCommunityModules/MLCSOCommunityModules.def 2011-10-11 07:39:39 UTC (rev 386) +++ trunk/Community/General/Modules/ML/MLCSOCommunityModules/MLCSOCommunityModules.def 2011-10-11 07:41:11 UTC (rev 387) @@ -12,6 +12,12 @@ exampleNetwork = "$(LOCAL)/CSODistance/CSODistanceExample.mlab" documentation = "$(LOCAL)/CSODistance/CSODistance.html" + Description { + Field minimumDistance { persistent = No } + Field minimumDistancePoint1 { persistent = No } + Field minimumDistancePoint2 { persistent = No } + } + Window { Category Totals { Field minimumDistance { edit = NO minLength = 10 } Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp 2011-10-11 07:39:39 UTC (rev 386) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp 2011-10-11 07:41:11 UTC (rev 387) @@ -29,8 +29,8 @@ char* distanceModes[LASTMODE]; distanceModes[ FIRST2 ] = "First 2 CSOs"; - distanceModes[ INPLANE ] = "Match in plane CSOs"; - distanceModes[ TWOINPUTS ] = "Match index of two CSOLists"; + distanceModes[ INPLANE ] = "Match in plane"; + distanceModes[ INDEX ] = "Match index"; _modeFld = fieldC->addEnum("mode",distanceModes,LASTMODE); _modeFld->setEnumValue( FIRST2 ); @@ -240,6 +240,7 @@ break; } case INPLANE: + case INDEX: { CurveData *outputCurve = new CurveData; double *yValues = new double[ nCSOs ]; @@ -381,7 +382,7 @@ { CSO* matchingCSO = NULL; - if ( _modeFld->getEnumValue() == TWOINPUTS && _csoList0 != NULL && _csoList1 != NULL) { + if ( _modeFld->getEnumValue() == INDEX && _csoList0 != NULL && _csoList1 != NULL) { if (findCSO < static_cast<int>( _csoList1->numCSO()) ){ matchingCSO = _csoList1->getCSOAt( findCSO ); } Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.h =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.h 2011-10-11 07:39:39 UTC (rev 386) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.h 2011-10-11 07:41:11 UTC (rev 387) @@ -24,7 +24,7 @@ //! Standard constructor. CSODistance(); - enum {FIRST2=0, INPLANE, TWOINPUTS, LASTMODE}; + enum {FIRST2=0, INPLANE, INDEX, LASTMODE}; protected: This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rha...@us...> - 2011-10-11 07:39:45
|
Revision: 386 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=386&view=rev Author: rhameeteman Date: 2011-10-11 07:39:39 +0000 (Tue, 11 Oct 2011) Log Message: ----------- KH. * Added some interface parameters Modified Paths: -------------- trunk/Community/General/Modules/Macros/Viewers/View2DMPRPath.mlab trunk/Community/General/Modules/Macros/Viewers/View2DMPRPath.script Modified: trunk/Community/General/Modules/Macros/Viewers/View2DMPRPath.mlab =================================================================== --- trunk/Community/General/Modules/Macros/Viewers/View2DMPRPath.mlab 2011-10-04 06:51:31 UTC (rev 385) +++ trunk/Community/General/Modules/Macros/Viewers/View2DMPRPath.mlab 2011-10-11 07:39:39 UTC (rev 386) @@ -2,6 +2,81 @@ network { watchlist = "" } +module BoolInt { + internal { + frame = "-251 441 168 64" + moduleGroupName = "" + windows { + window _default { + geometry = "995 698 262 218" + sizeHint = "200 218" + wasOpen = yes + } + } + } + fields { + instanceName = ShowCurrentImageSlice + boolValue = TRUE + invBoolValue = FALSE + intValue = 1 + offValue = 0 + onValue = 1 + defaultBool = Unchanged + } +} +module FieldBypass { + internal { + frame = "-59 421 104 56" + moduleGroupName = "" + windows { + window _default { + geometry = "661 174 173 323" + sizeHint = "173 323" + wasOpen = yes + } + } + } + fields { + instanceName = FieldBypass2 + inputString0 = 0 + inputString1 = 1 + inputString2 = "" + inputString3 = "" + inputString4 = "" + inputNumber = 1 + outputString = 1 + noBypass = FALSE + onlyIfChanged = TRUE + } +} +module WorldVoxelConvert { + internal { + frame = "453 501 136 56" + moduleGroupName = "" + windows { + window _default { + geometry = "1007 321 414 234" + sizeHint = "414 234" + wasOpen = yes + } + } + } + fields { + instanceName = WorldVoxelConvert + voxelX = 0 + voxelY = 0 + voxelZ = 1 + worldX = 0.5 + worldY = 0.5 + worldZ = 1.5 + voxelPos = "0 0 1" + worldPos = "0.5 0.5 1.5" + voxelMode = FALSE + worldMode = TRUE + intVoxelCoords = TRUE + keepConstant = World + } +} module SoView2D { internal { frame = "325 213 88 56" @@ -23,6 +98,7 @@ plane = "0 0 1 0" sliceZoom = 1 sliceZoomSynchronized = 1 + zoomCenter = "0.5 0.5" minSliceZoomKeyboard = 1 sliceOrigin = "0 0" viewingCenter = "0 0 0" @@ -61,7 +137,7 @@ cineMode = CINE_Z cineDirection = CINE_PINGPONG cineRepeat = CINE_ONCE - cineSpeed = 0.1000000015 + cineSpeed = 0.1 cineFullRangeZ = TRUE cineFullRangeT = TRUE cineAlwaysReset = TRUE @@ -103,6 +179,7 @@ autoUpdateML = FALSE showSnapshotWithShell = FALSE snapCount = 0 + inputDevicesList = "" } } module SoGroup { @@ -120,10 +197,9 @@ moduleGroupName = "" windows { window _default { - geometry = "114 175 470 665" - sizeHint = "470 665" + geometry = "114 175 446 713" + sizeHint = "446 713" wasOpen = no - wasActive = no } } } @@ -133,7 +209,7 @@ editingOn = TRUE maskValid = FALSE fixZOn = TRUE - color = "1 0.8667280077934265 0.2914040088653564" + color = "1 0.866728007793427 0.291404008865356" selectionTolerance = 4 needsValidVoxel = TRUE button1 = PRESSED @@ -155,13 +231,15 @@ firstSliceWorldPosition = "-1 -1 -1" drawingModel = DRAWINGMODEL_CROSSHAIRS drawingModelSize = -1 + crossHairSpacing = 0 + drawEditingRect = FALSE blendOnto = 1 blendOutside = 0 lineWidth = 1 colorAxes = FALSE sagittalColor = "1 0 0" - coronalColor = "0.1725489944219589 0.8862749934196472 0.01176500041037798" - axialColor = "0.007842999882996082 0.9529410004615784 0.9686269760131836" + coronalColor = "0.172548994421959 0.886274993419647 0.011765000410378" + axialColor = "0.00784299988299608 0.952941000461578 0.968626976013184" updateOnPress = TRUE updateOnMotion = TRUE updateOnRelease = TRUE @@ -179,7 +257,6 @@ geometry = "740 846 151 85" sizeHint = "151 85" wasOpen = no - wasActive = no } } } @@ -191,8 +268,8 @@ minValue = 0 maxValue = 10 increment = -1 + fields = "" } - internalFields = "" } module Increment { internal { @@ -203,7 +280,6 @@ geometry = "737 730 151 85" sizeHint = "151 85" wasOpen = no - wasActive = no } } } @@ -215,8 +291,8 @@ minValue = 0 maxValue = 10 increment = 1 + fields = "" } - internalFields = "" } module SoKeyGrabber { internal { @@ -227,7 +303,6 @@ geometry = "688 345 380 226" sizeHint = "380 226" wasOpen = no - wasActive = no } } } @@ -254,7 +329,6 @@ geometry = "441 656 190 280" sizeHint = "190 280" wasOpen = no - wasActive = no } } } @@ -280,7 +354,6 @@ geometry = "940 324 291 315" sizeHint = "259 315" wasOpen = no - wasActive = no } } } @@ -309,7 +382,6 @@ output8 = "" output9 = "" } - internalFields = "" } module FieldBypass { internal { @@ -317,10 +389,9 @@ moduleGroupName = "" windows { window _default { - geometry = "661 174 190 280" - sizeHint = "190 280" + geometry = "661 174 173 323" + sizeHint = "173 323" wasOpen = no - wasActive = no } } } @@ -366,18 +437,19 @@ autoUpdateML = FALSE showSnapshotWithShell = FALSE snapCount = 0 + inputDevicesList = "" headlight = TRUE decoration = TRUE popupMenuEnabled = FALSE viewing = TRUE autoClipping = TRUE - externalCamera = FALSE drawStyle = VIEW_AS_IS interactiveDrawStyle = VIEW_LOW_COMPLEXITY viewAllFlag = FALSE initialCameraOrientation = CAMERA_KEEP_AS_IS applyCameraOrientation = CAMERA_KEEP_AS_IS cameraType = CAMERA_PERSPECTIVE + autoApplyUserSettingOrientation = FALSE userSettingOrientation = "0 0 1 0" automaticViewAll = FALSE storeCurrentState = TRUE @@ -415,10 +487,9 @@ moduleGroupName = "" windows { window _default { - geometry = "356 371 199 66" - sizeHint = "199 66" - wasOpen = no - wasActive = no + geometry = "356 371 200 64" + sizeHint = "200 64" + wasOpen = yes } } } @@ -426,7 +497,6 @@ instanceName = Switch currentInput = 0 numberOfInputs = 5 - maxInput = 4 } } module SoGroup { @@ -465,7 +535,6 @@ geometry = "51 97 350 495" sizeHint = "470 495" wasOpen = no - wasActive = no } } } @@ -497,18 +566,17 @@ moduleGroupName = "" windows { window _default { - geometry = "134 107 449 580" - sizeHint = "449 580" - wasOpen = no - wasActive = no + geometry = "134 107 433 586" + sizeHint = "426 586" + wasOpen = yes } } } fields { instanceName = MPRPath - rotation = "-0.997501603966892 0.0163167111006986 0.0687336527643707 1.57859108282801" - translation = "-27.9044 -198.011 0" - plane = "-0.0851343759417393 -0.00752636682328935 -0.996341051967373 3.86592710107502" + rotation = "0 0 0 0" + translation = "0 0 0" + plane = "0 1 0 0" enablePlaneEdit = FALSE fillValue = 0 fieldOfView = 30 @@ -551,13 +619,11 @@ geometry = "552 188 637 669" sizeHint = "637 669" wasOpen = no - wasActive = no } window _automatic { geometry = "587 124 354 440" sizeHint = "354 440" wasOpen = no - wasActive = no } } } @@ -567,7 +633,7 @@ zoomOn = TRUE panOn = TRUE autoCenterOn = TRUE - position = "-3.984270095825195 -7.729000091552734 32.68109893798828" + position = "-3.9842700958252 -7.72900009155273 32.6810989379883" positionMode = Off lutOn = TRUE lutMouseOn = TRUE @@ -591,30 +657,31 @@ lutEnableNegWidth = FALSE lutSetDefaultOnce = TRUE lutTrCol0 = "1 1 1" - lutTrCol1 = "0.5019609928131104 0.5019609928131104 0.5019609928131104" - lutTrCol2 = "0.8627449870109558 0 0.1725489944219589" - lutTrCol3 = "1 0.4627450108528137 0.4901959896087646" - lutTrCol4 = "0 0.8196079730987549 0.1607840061187744" - lutTrCol5 = "0.5607839822769165 1 0.4352940022945404" - lutTrCol6 = "0.1843139976263046 0.2392159998416901 0.9294120073318481" - lutTrCol7 = "0.4901959896087646 0.5411760210990906 1" - lutTrCol8 = "0.6313729882240295 0 0.67843097448349" - lutTrCol9 = "0.8941180109977722 0.3803919851779938 1" - lutTrColA = "0 0.6823530197143555 0.756862998008728" - lutTrColB = "0.5019609928131104 1 0.9803919792175293" - lutTrColC = "0.6156859993934631 0.6000000238418579 0.1960780024528503" - lutTrColD = "1 0.9764710068702698 0.3686270117759705" + lutTrCol1 = "0.50196099281311 0.50196099281311 0.50196099281311" + lutTrCol2 = "0.862744987010956 0 0.172548994421959" + lutTrCol3 = "1 0.462745010852814 0.490195989608765" + lutTrCol4 = "0 0.819607973098755 0.160784006118774" + lutTrCol5 = "0.560783982276917 1 0.43529400229454" + lutTrCol6 = "0.184313997626305 0.23921599984169 0.929412007331848" + lutTrCol7 = "0.490195989608765 0.541176021099091 1" + lutTrCol8 = "0.63137298822403 0 0.67843097448349" + lutTrCol9 = "0.894118010997772 0.380391985177994 1" + lutTrColA = "0 0.682353019714355 0.756862998008728" + lutTrColB = "0.50196099281311 1 0.980391979217529" + lutTrColC = "0.615685999393463 0.600000023841858 0.19607800245285" + lutTrColD = "1 0.97647100687027 0.36862701177597" lutTrColE = "1 1 1" lutTrColF = "1 1 1" annotationOn = TRUE annoCoords = World annoCTValue = AsIs valueHighPrecision = FALSE + maxPrecision = 4 annotFontSize = ANNO_SIZE_AUTO annotShowOrientation = ANNO_ORIENTATION_SIZE_WEIGHTED annotVerticalRuler = TRUE annotHorizontalRuler = FALSE - annotationCol = "0.8999999761581421 0.8999999761581421 0.8999999761581421" + annotationCol = "0.899999976158142 0.899999976158142 0.899999976158142" annotationMode = ANNO_MODE_USER annotShowAnnot = ANNO_SHOW_DETAILED annotUserTopLeft = "$(PatientsName) @@ -640,26 +707,59 @@ annotShortTopRight = $(Modality) annotShortBottomLeft = "Slice: $(input09)" annotShortBottomRight = "LUT C/W: $(input03) / $(input04)" + annotMRTopLeft = "$(PatientsName) +$(PatientsBirthDate) $(PatientsSex) +$(PatientID) +($(input00)): +$(input01) GV" + annotMRTopRight = "$(InstitutionName) +$(ManufacturersModelName) +$(Modality)" + annotMRBottomLeft = "Slice: $(slice) +Timepoint: $(timepoint) +$(sizex),$(sizey),$(sizez),$(sizec),$(sizet) +$(voxelx),$(voxely),$(voxelz) +$(SeriesDescription) +$(ImageComments)" + annotMRBottomRight = "MR Mode +Scan: $(AcquisitionDate) +LUT C/W: $(input03) / $(input04)" + annotCTTopLeft = "$(PatientsName) +$(PatientsBirthDate) $(PatientsSex) +$(PatientID) +($(input00)): +$(input02) $(input09)" + annotCTTopRight = "$(InstitutionName) +$(ManufacturersModelName) +$(Modality) " + annotCTBottomLeft = "Slice: $(slice) +Timepoint: $(timepoint) +$(sizex),$(sizey),$(sizez),$(sizec),$(sizet) +$(voxelx),$(voxely),$(voxelz) +$(SeriesDescription) +$(ImageComments)" + annotCTBottomRight = "CT Mode +Scan: $(AcquisitionDate) +LUT C/W: $(input07) / $(input08)" annoInput03 = 1 annoInput04 = 1 annoInput05 = 1 annoInput06 = 1 annoInput07 = 1 annoInput08 = 1 - annoInput09 = GV + annoInput09 = 1 annoMouseOn = TRUE annoReadPixFloorPos = "1025 764 0" - annoReadPixVoxelPos = "1025.339965820312 764.1619873046875 0.5" - annoReadPixWorldPos = "1025.339965820312 764.1619873046875 0.5" + annoReadPixVoxelPos = "1025.33996582031 764.161987304688 0.5" + annoReadPixWorldPos = "1025.33996582031 764.161987304688 0.5" borderOn = TRUE - borderColor = "0.8999999761581421 0.8999999761581421 0.8999999761581421" + borderColor = "0.899999976158142 0.899999976158142 0.899999976158142" borderWidth = 1 borderEvaluateFocus = FALSE borderFocusColor = "1 1 1" borderFocusWidth = 2 mouseGrabberMode = FALSE } - internalFields = "" } module SoMouseGrabber { internal { @@ -670,13 +770,11 @@ geometry = "-49 125 477 449" sizeHint = "477 449" wasOpen = no - wasActive = no } window _automatic { geometry = "768 153 366 744" sizeHint = "303 440" wasOpen = no - wasActive = no } } } @@ -700,7 +798,6 @@ cursorShape = UNDEFINED_CURSOR absX = 0 absY = 0 - y = 0 x = 0.5 y = 0 xmin = 0 @@ -741,7 +838,6 @@ geometry = "413 702 121 91" sizeHint = "121 91" wasOpen = no - wasActive = no } } } @@ -749,11 +845,14 @@ instanceName = SyncFloat1 float1 = 0 float2 = 0 - epsilon = 9.999999747e-05 + epsilon = 9.9999997e-05 } - internalFields = "" } connections { + FieldBypass2.inputString0 = MPRPath.currentKeyFrame + FieldBypass2.inputString1 = WorldVoxelConvert.voxelZ + FieldBypass2.inputNumber = ShowCurrentImageSlice.intValue + WorldVoxelConvert.worldPos = MPRPath.translation SoView2D.image = Switch.output0 scene.children = "SoGroup1.self SoGroup.self SoView2D.self invPostViewerIn.self" SoGroup.children = "invPostLUTIn.self pos.self" @@ -773,13 +872,10 @@ SoExaminerViewer.children = MPRPath.outputSlice Switch.input0 = MPRPath.output0 Switch.input1 = MPRPath.output2 - invPostViewerIn.children = "" - invPostLUTIn.children = "" - invPreLUTIn.children = "" MPRPath.currentKeyFrame = FieldSwitch.output0 MPRPath.pathAngle = FieldSwitch.output1 ext.inLUT = MPRPath.output0 - ext.annoInput09 = MPRPath.currentKeyFrame + ext.annoInput09 = FieldBypass2.outputString SoMouseGrabber.y = SoMouseGrabber.wheel SoMouseGrabber.ymax = FieldBypass.outputString SoMouseGrabber.wheel = SyncFloat1.float2 Modified: trunk/Community/General/Modules/Macros/Viewers/View2DMPRPath.script =================================================================== --- trunk/Community/General/Modules/Macros/Viewers/View2DMPRPath.script 2011-10-04 06:51:31 UTC (rev 385) +++ trunk/Community/General/Modules/Macros/Viewers/View2DMPRPath.script 2011-10-11 07:39:39 UTC (rev 386) @@ -40,6 +40,7 @@ Interface { Inputs { Field input0 { internalName = MPRPath.input0 } + Field input0 { internalName = WorldVoxelConvert.input0 } Field path { type = mlbase deprecatedName = input1 } Field inInvPreLUT { internalName = invPreLUTIn.child @@ -71,6 +72,8 @@ Field showOutputs { type = bool value = False } Field timePoint { internalName = SoView2D.timePoint } Field currentFrame { internalName = MPRPath.currentKeyFrame } + Field showImageSlice { internalName = ShowCurrentImageSlice.boolValue } + Field imageSlice { internalName = WorldVoxelConvert.voxelZ } Field maxFrames { internalName = MPRPath.maxKeyFrame } Field currentPlane { internalName = MPRPath.plane } Field rotation { internalName = MPRPath.rotation } @@ -79,6 +82,7 @@ Field pathAngle { internalName = MPRPath.pathAngle } Field fieldOfView { internalName = MPRPath.fieldOfView } Field outputSize { internalName = MPRPath.outputSize } + Field showCursor { internalName = pos.drawingOn } Field cursorAlpha { internalName = pos.blendOnto } Field lutCenter { internalName = ext.lutGreyCenter } Field lutWidth { internalName = ext.lutGreyWidth } @@ -133,12 +137,17 @@ h = 300 expandY = Yes Field viewContent {expandY = No} - Viewer scene.self { - type = SoRenderArea + Vertical { + panelName = view2D expandY = Yes - visibleOn = "*viewContent == /(MPRSlice|CMPR)/ *" + Viewer scene.self { + type = SoRenderArea + expandY = Yes + visibleOn = "*viewContent == /(MPRSlice|CMPR)/ *" + } } Vertical { + panelName = view3D visibleOn = "*viewContent == "Scene" *" expandY = Yes Viewer SoExaminerViewer.self { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rha...@us...> - 2011-10-04 06:51:38
|
Revision: 385 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=385&view=rev Author: rhameeteman Date: 2011-10-04 06:51:31 +0000 (Tue, 04 Oct 2011) Log Message: ----------- KH. * Added macro to calculate several (symmetric) distance measures between two WEMs Added Paths: ----------- trunk/Community/General/Modules/Macros/WEM/ trunk/Community/General/Modules/Macros/WEM/WEMDistances.def trunk/Community/General/Modules/Macros/WEM/WEMDistances.mlab trunk/Community/General/Modules/Macros/WEM/WEMDistances.py trunk/Community/General/Modules/Macros/WEM/WEMDistances.script trunk/Community/General/Modules/Macros/WEM/networks/ trunk/Community/General/Modules/Macros/WEM/networks/WEMDistancesExample.mlab Added: trunk/Community/General/Modules/Macros/WEM/WEMDistances.def =================================================================== --- trunk/Community/General/Modules/Macros/WEM/WEMDistances.def (rev 0) +++ trunk/Community/General/Modules/Macros/WEM/WEMDistances.def 2011-10-04 06:51:31 UTC (rev 385) @@ -0,0 +1,21 @@ +//---------------------------------------------------------------------------------- +//! WEMDistances module definition +/*! +// \file WEMDistances.def +// \author Reinhard +// \date 2011-10-03 +*/ +//---------------------------------------------------------------------------------- + +MacroModule WEMDistances { + genre = "" + author = "Reinhard" + status = "work-in-progress" + comment = "Calculate some distance measures on WEMs" + keywords = "WEM distance surface node symmetric hausdorff" + seeAlso = "WEMSurfaceDistance WEMNotdeTonodeDistance" + exampleNetwork = "$(LOCAL)/networks/WEMDistancesExample.mlab" + + externalDefinition = "$(LOCAL)/WEMDistances.script" + +} // MacroModule WEMDistances \ No newline at end of file Added: trunk/Community/General/Modules/Macros/WEM/WEMDistances.mlab =================================================================== --- trunk/Community/General/Modules/Macros/WEM/WEMDistances.mlab (rev 0) +++ trunk/Community/General/Modules/Macros/WEM/WEMDistances.mlab 2011-10-04 06:51:31 UTC (rev 385) @@ -0,0 +1,345 @@ +// MDL v1 utf8 +network { + watchlist = "" +} +module WEMInfo { + internal { + frame = "645 245 88 56" + moduleGroupName = "" + } + fields { + instanceName = WEMInfo1 + isProcessing = FALSE + elapsedTime = 0 + autoApply = TRUE + autoUpdate = TRUE + autoClear = TRUE + listenToFinishingNotifications = TRUE + listenToRepaintNotifications = FALSE + listenToSelectionChangedNotifications = TRUE + WEMs = "" + selectedWEMs = "" + informationFieldsValid = FALSE + globalInformationFieldsValid = FALSE + globalNumNodes = 0 + globalNumEdges = 0 + globalNumFaces = 0 + globalSurfaceArea = 0 + globalSurfaceVolume = 0 + globalCenter = "0 0 0" + globalMinimum = "3.40282346638529e+38 3.40282346638529e+38 3.40282346638529e+38" + globalMaximum = "-3.40282346638529e+38 -3.40282346638529e+38 -3.40282346638529e+38" + globalSize = "0 0 0" + globalRadius = 0 + numNodes = 0 + numEdges = 0 + numFaces = 0 + uniqueId = -1 + patchType = Unknown + hasEdges = FALSE + surfaceArea = 0 + surfaceVolume = 0 + label = "" + description = "" + show = TRUE + editable = TRUE + colorMode = "General " + drawFaces = TRUE + useFaceAmbientColor = TRUE + faceAmbientColor = "0.266667008399963 0.266667008399963 0.266667008399963" + useFaceDiffuseColor = TRUE + faceDiffuseColor = "0.792156994342804 0.792156994342804 0.792156994342804" + useFaceSpecularColor = TRUE + faceSpecularColor = "0.0666669979691505 0.0666669979691505 0.0666669979691505" + faceAlphaValue = 1 + faceShininessValue = 1 + drawFaceNormals = FALSE + faceNormalsColor = "1 1 1" + faceNormalsScale = 1 + drawEdges = FALSE + edgeColor = "0 0 0" + usePolygonOffset = FALSE + lineWidth = 1 + useEdgeColoringMode = FALSE + drawNodes = FALSE + nodeColor = "1 1 1" + drawNodeNormals = FALSE + nodeNormalsColor = "1 1 1" + nodeNormalsScale = 1 + pointSize = 1 + nodeRenderingMode = Normal + drawBoundingBox = FALSE + boundingBoxMode = "Axis Aligned" + boundingBoxColor = "1 1 1" + center = "0 0 0" + minimum = "0 0 0" + maximum = "0 0 0" + size = "0 0 0" + radius = 0 + mainAxisCenter = "0 0 0" + xMainAxis = "0 0 0" + yMainAxis = "0 0 0" + zMainAxis = "0 0 0" + xExt = 0 + yExt = 0 + zExt = 0 + primitiveValueLists = "" + selectedPrimitiveValueList = "" + primitiveValueListValid = FALSE + minPrimitiveValueList = 0 + maxPrimitiveValueList = 0 + meanPrimitiveValueList = 0 + stdPrimitiveValueList = 0 + rmsdPrimitiveValueList = 0 + primitiveValueListUnits = "" + edgeLengthUnits = mm + faceAreaUnits = mm2 + curveScaleFactor = 1 + selectedTab = 0 + } +} +module WEMInfo { + internal { + frame = "477 245 88 56" + moduleGroupName = "" + } + fields { + instanceName = WEMInfo + isProcessing = FALSE + elapsedTime = 0 + autoApply = TRUE + autoUpdate = TRUE + autoClear = TRUE + listenToFinishingNotifications = TRUE + listenToRepaintNotifications = FALSE + listenToSelectionChangedNotifications = TRUE + WEMs = "" + selectedWEMs = "" + informationFieldsValid = FALSE + globalInformationFieldsValid = FALSE + globalNumNodes = 0 + globalNumEdges = 0 + globalNumFaces = 0 + globalSurfaceArea = 0 + globalSurfaceVolume = 0 + globalCenter = "0 0 0" + globalMinimum = "3.40282346638529e+38 3.40282346638529e+38 3.40282346638529e+38" + globalMaximum = "-3.40282346638529e+38 -3.40282346638529e+38 -3.40282346638529e+38" + globalSize = "0 0 0" + globalRadius = 0 + numNodes = 0 + numEdges = 0 + numFaces = 0 + uniqueId = -1 + patchType = Unknown + hasEdges = FALSE + surfaceArea = 0 + surfaceVolume = 0 + label = "" + description = "" + show = TRUE + editable = TRUE + colorMode = "General " + drawFaces = TRUE + useFaceAmbientColor = TRUE + faceAmbientColor = "0.266667008399963 0.266667008399963 0.266667008399963" + useFaceDiffuseColor = TRUE + faceDiffuseColor = "0.792156994342804 0.792156994342804 0.792156994342804" + useFaceSpecularColor = TRUE + faceSpecularColor = "0.0666669979691505 0.0666669979691505 0.0666669979691505" + faceAlphaValue = 1 + faceShininessValue = 1 + drawFaceNormals = FALSE + faceNormalsColor = "1 1 1" + faceNormalsScale = 1 + drawEdges = FALSE + edgeColor = "0 0 0" + usePolygonOffset = FALSE + lineWidth = 1 + useEdgeColoringMode = FALSE + drawNodes = FALSE + nodeColor = "1 1 1" + drawNodeNormals = FALSE + nodeNormalsColor = "1 1 1" + nodeNormalsScale = 1 + pointSize = 1 + nodeRenderingMode = Normal + drawBoundingBox = FALSE + boundingBoxMode = "Axis Aligned" + boundingBoxColor = "1 1 1" + center = "0 0 0" + minimum = "0 0 0" + maximum = "0 0 0" + size = "0 0 0" + radius = 0 + mainAxisCenter = "0 0 0" + xMainAxis = "0 0 0" + yMainAxis = "0 0 0" + zMainAxis = "0 0 0" + xExt = 0 + yExt = 0 + zExt = 0 + primitiveValueLists = "" + selectedPrimitiveValueList = "" + primitiveValueListValid = FALSE + minPrimitiveValueList = 0 + maxPrimitiveValueList = 0 + meanPrimitiveValueList = 0 + stdPrimitiveValueList = 0 + rmsdPrimitiveValueList = 0 + primitiveValueListUnits = "" + edgeLengthUnits = mm + faceAreaUnits = mm2 + curveScaleFactor = 1 + selectedTab = 0 + } +} +module WEMSurfaceDistance { + internal { + frame = "609 349 160 56" + moduleGroupName = "" + windows { + window _default { + geometry = "947 420 316 482" + sizeHint = "316 482" + wasOpen = yes + } + } + } + fields { + instanceName = WEMSurfaceDistance1 + isProcessing = FALSE + elapsedTime = 0 + id = 0 + autoApply = TRUE + autoUpdate = TRUE + autoClear = FALSE + removePreviousWEMs = TRUE + label = "" + description = "" + show = TRUE + editable = TRUE + colorMode = "General " + drawFaces = TRUE + useFaceAmbientColor = TRUE + faceAmbientColor = "0.266667008399963 0.266667008399963 0.266667008399963" + useFaceDiffuseColor = TRUE + faceDiffuseColor = "0.792156994342804 0.792156994342804 0.792156994342804" + useFaceSpecularColor = TRUE + faceSpecularColor = "0.0666669979691505 0.0666669979691505 0.0666669979691505" + faceAlphaValue = 1 + faceShininessValue = 1 + drawFaceNormals = FALSE + faceNormalsColor = "1 1 1" + faceNormalsScale = 1 + drawEdges = FALSE + edgeColor = "0 0 0" + usePolygonOffset = FALSE + lineWidth = 1 + useEdgeColoringMode = FALSE + drawNodes = FALSE + nodeColor = "1 1 1" + drawNodeNormals = FALSE + nodeNormalsColor = "1 1 1" + nodeNormalsScale = 1 + pointSize = 1 + nodeRenderingMode = Normal + drawBoundingBoxes = FALSE + boundingBoxMode = "Axis Aligned" + boundingBoxColor = "1 1 1" + copyInputWEMs = FALSE + listenToFinishNotifications = TRUE + forwardRepaintNotifications = TRUE + forwardSelectionNotifications = TRUE + progress = 0 + triangulationMode = Strip + modifyAttributes = FALSE + relativeError = 0 + numEntries = 200 + shouldComputeSignedDistances = FALSE + addEdgesToNearestNodes = FALSE + shouldNormalizeDist = FALSE + useLUTPrimitiveValueList = TRUE + customPrimitiveValueList = "Surface Distance" + selectedTab = 0 + outputTabSelected = TRUE + } +} +module WEMSurfaceDistance { + internal { + frame = "445 349 152 56" + moduleGroupName = "" + windows { + window _default { + geometry = "184 374 316 482" + sizeHint = "316 482" + wasOpen = yes + } + } + } + fields { + instanceName = WEMSurfaceDistance + isProcessing = FALSE + elapsedTime = 0 + id = 0 + autoApply = TRUE + autoUpdate = TRUE + autoClear = FALSE + removePreviousWEMs = TRUE + label = "" + description = "" + show = TRUE + editable = TRUE + colorMode = "General " + drawFaces = TRUE + useFaceAmbientColor = TRUE + faceAmbientColor = "0.266667008399963 0.266667008399963 0.266667008399963" + useFaceDiffuseColor = TRUE + faceDiffuseColor = "0.792156994342804 0.792156994342804 0.792156994342804" + useFaceSpecularColor = TRUE + faceSpecularColor = "0.0666669979691505 0.0666669979691505 0.0666669979691505" + faceAlphaValue = 1 + faceShininessValue = 1 + drawFaceNormals = FALSE + faceNormalsColor = "1 1 1" + faceNormalsScale = 1 + drawEdges = FALSE + edgeColor = "0 0 0" + usePolygonOffset = FALSE + lineWidth = 1 + useEdgeColoringMode = FALSE + drawNodes = FALSE + nodeColor = "1 1 1" + drawNodeNormals = FALSE + nodeNormalsColor = "1 1 1" + nodeNormalsScale = 1 + pointSize = 1 + nodeRenderingMode = Normal + drawBoundingBoxes = FALSE + boundingBoxMode = "Axis Aligned" + boundingBoxColor = "1 1 1" + copyInputWEMs = FALSE + listenToFinishNotifications = TRUE + forwardRepaintNotifications = TRUE + forwardSelectionNotifications = TRUE + progress = 0 + triangulationMode = Strip + modifyAttributes = FALSE + relativeError = 0 + numEntries = 200 + shouldComputeSignedDistances = FALSE + addEdgesToNearestNodes = FALSE + shouldNormalizeDist = FALSE + useLUTPrimitiveValueList = TRUE + customPrimitiveValueList = "Surface Distance" + selectedTab = 0 + outputTabSelected = TRUE + } +} +connections { + WEMInfo1.inWEM = WEMSurfaceDistance1.outWEM + WEMInfo.inWEM = WEMSurfaceDistance.outWEM + WEMSurfaceDistance1.shouldComputeSignedDistances = WEMSurfaceDistance.shouldComputeSignedDistances + WEMSurfaceDistance1.shouldNormalizeDist = WEMSurfaceDistance.shouldNormalizeDist +} +networkModel = "" Added: trunk/Community/General/Modules/Macros/WEM/WEMDistances.py =================================================================== --- trunk/Community/General/Modules/Macros/WEM/WEMDistances.py (rev 0) +++ trunk/Community/General/Modules/Macros/WEM/WEMDistances.py 2011-10-04 06:51:31 UTC (rev 385) @@ -0,0 +1,26 @@ +#---------------------------------------------------------------------------------- +#! Macro module WEMDistances +#/*! +# \file WEMDistances.py +# \author Reinhard +# \date 2011-10-03 +# +# Calculate some distance measures on WEMs +# */ +#---------------------------------------------------------------------------------- + +from mevis import * + +def Update(): + ctx.field("symmetricMin").value = ( ctx.field("min01").value + ctx.field("min10").value )/2 + ctx.field("symmetricMean").value = ( ctx.field("mean01").value + ctx.field("mean10").value )/2 + ctx.field("symmetricMax").value = ( ctx.field("max01").value + ctx.field("max10").value )/2 + ctx.field("hausdorff").value = max( ctx.field("max01").value, ctx.field("max10").value ) + return + +#//# MeVis signature v1 +#//# key: MFowDQYJKoZIhvcNAQEBBQADSQAwRgJBANEfsmYse2e1dRhkQ9AQbreCq9uxwzWLoGom13MNYmyfwoJqQOEXljLFAgw2eEjaT12G4CdqKWhRxh9ANP6n7GMCARE=:VI/mB8bT4u+mRtf/ru8yUQi8BzpaS3UeL2x62YxsUYnVqCWuLrVNLiukIIjnJMKQXlc8ezmgOIcVAV7pgvgKpQ== +#//# owner: MeVis +#//# date: 2011-09-03T10:18:33 +#//# hash: weWl3qiFU5ceUmbFn9p9xqu/Ob8VqQnw2g9FJNivuXAw3W2CYRmKmSePsDHcRghebwpnlQjwl9LhzloxgzMANQ== +#//# MeVis end \ No newline at end of file Added: trunk/Community/General/Modules/Macros/WEM/WEMDistances.script =================================================================== --- trunk/Community/General/Modules/Macros/WEM/WEMDistances.script (rev 0) +++ trunk/Community/General/Modules/Macros/WEM/WEMDistances.script 2011-10-04 06:51:31 UTC (rev 385) @@ -0,0 +1,97 @@ +//---------------------------------------------------------------------------------- +//! Macro module WEMDistances +/*! +// \file WEMDistances.script +// \author Reinhard +// \date 2011-10-03 +// +// Calculate some distance measures on WEMs +*/ +//---------------------------------------------------------------------------------- + + +Interface { + Inputs { + Field WEM0 { internalName = WEMSurfaceDistance.inWEM } + Field WEM0 { internalName = WEMSurfaceDistance1.inWEM2 } + Field WEM1 { internalName = WEMSurfaceDistance.inWEM2 } + Field WEM1 { internalName = WEMSurfaceDistance1.inWEM } + } + Outputs { + Field outWEM0 { internalName = WEMSurfaceDistance.outWEM } + Field outWEM1 { internalName = WEMSurfaceDistance1.outWEM } + } + Parameters { + Field signed { internalName = WEMSurfaceDistance.shouldComputeSignedDistances } + field normalize { internalName = WEMSurfaceDistance.shouldNormalizeDist } + Field min01 { internalName = WEMInfo.minPrimitiveValueList } + Field mean01 { internalName = WEMInfo.meanPrimitiveValueList } + Field max01 { internalName = WEMInfo.maxPrimitiveValueList } + Field min10 { internalName = WEMInfo1.minPrimitiveValueList } + Field mean10 { internalName = WEMInfo1.meanPrimitiveValueList } + Field max10 { internalName = WEMInfo1.maxPrimitiveValueList } + Field symmetricMin { type = Float value = 0 } + Field symmetricMean { type = Float value = 0 } + Field symmetricMax { type = Float value = 0 } + Field hausdorff { type = Float value = 0 } + } +} + +Description { + Field min01 { persistent = No } + Field mean01 { persistent = No } + Field max01 { persistent = No } + Field min10 { persistent = No } + Field mean10 { persistent = No } + Field max10 { persistent = No } + Field symmetricMin { persistent = No } + Field symmetricMean { persistent = No } + Field symmetricMax { persistent = No } + Field hausdorff { persistent = No } +} + +Commands { + source = $(LOCAL)/WEMDistances.py + FieldListener { + listenField = WEM0 + listenField = WEM1 + listenField = signed + listenField = normalize + command = Update + } +} + +Window { + Vertical { + Box { + layout = Horizontal + CheckBox signed {} + CheckBox normalize {} + } + style { Prototype Field { expandX = Yes edit = No alignGroupX = c1 } } + Box "WEM0 --> WEM1" { + Field min01 { title = min } + Field mean01 { title = mean } + Field max01 { title = max } + } + Box "WEM1 --> WEM0" { + Field min10 { title = min } + Field mean10 { title = mean } + Field max10 { title = max } + } + Box "Symmetric" { + Field symmetricMin { title = min } + Field symmetricMean { title = mean } + Field symmetricMax { title = max } + Field hausdorff { title = hausdorff } + } + + } +} + +//# MeVis signature v1 +//# key: MFowDQYJKoZIhvcNAQEBBQADSQAwRgJBANEfsmYse2e1dRhkQ9AQbreCq9uxwzWLoGom13MNYmyfwoJqQOEXljLFAgw2eEjaT12G4CdqKWhRxh9ANP6n7GMCARE=:VI/mB8bT4u+mRtf/ru8yUQi8BzpaS3UeL2x62YxsUYnVqCWuLrVNLiukIIjnJMKQXlc8ezmgOIcVAV7pgvgKpQ== +//# owner: MeVis +//# date: 2011-09-03T10:18:33 +//# hash: DJ++WqFnx+m4YKzWvUkzzten5tz31tpZejKHtt4x0Ygmxmfz8s2RBn9n8P0DWCNrOKo2VgDOkXKOrjT1voTjgQ== +//# MeVis end \ No newline at end of file Added: trunk/Community/General/Modules/Macros/WEM/networks/WEMDistancesExample.mlab =================================================================== --- trunk/Community/General/Modules/Macros/WEM/networks/WEMDistancesExample.mlab (rev 0) +++ trunk/Community/General/Modules/Macros/WEM/networks/WEMDistancesExample.mlab 2011-10-04 06:51:31 UTC (rev 385) @@ -0,0 +1,769 @@ +// MDL v1 utf8 +network { + watchlist = "" +} +module WEMDistances { + internal { + frame = "421 285 120 56" + moduleGroupName = "" + windows { + window _default { + geometry = "1087 424 188 371" + sizeHint = "188 371" + wasOpen = no + } + } + } + fields { + instanceName = WEMDistances + signed = FALSE + normalize = FALSE + } +} +module SoWEMRenderer { + internal { + frame = "837 37 136 56" + moduleGroupName = "" + windows { + window _default { + geometry = "833 454 337 404" + sizeHint = "337 404" + wasOpen = no + } + } + } + fields { + instanceName = SoWEMRenderer1 + renderCaching = AUTO + boundingBoxCaching = AUTO + renderCulling = AUTO + pickCulling = AUTO + autoApply = TRUE + autoUpdate = TRUE + autoClear = TRUE + useHighlightSelected = FALSE + usePolygonOffset = TRUE + useShapeHints = TRUE + allowHits = TRUE + parameterOverwriteMode = OVERWRITE_MODE_ALL + overwriteColorMode = FALSE + overwriteFaceParameters = FALSE + overwriteEdgeParameters = FALSE + overwriteNodeParameters = FALSE + overwriteBoundingBoxParameters = FALSE + colorMode = WEM_COLOR_GENERAL + drawFaces = FALSE + faceDiffuseColor = "0.792156994342804 0.792156994342804 0.792156994342804" + useFaceAmbientColor = TRUE + faceAmbientColor = "0.266667008399963 0.266667008399963 0.266667008399963" + useFaceSpecularColor = TRUE + faceSpecularColor = "0.0666669979691505 0.0666669979691505 0.0666669979691505" + drawEdges = TRUE + edgeColor = "0 0 0" + drawNodes = FALSE + nodeColor = "1 1 1" + drawBoundingBoxes = FALSE + boundingBoxColor = "1 1 1" + drawFaceNormals = FALSE + drawNodeNormals = FALSE + faceNormalColor = "1 1 1" + nodeNormalColor = "1 1 1" + faceNormalScaling = 1 + nodeNormalScaling = 1 + faceAlphaValue = 0.60000002 + faceShininessValue = 1 + lineWidth = 1 + pointSize = 1 + useEdgeColoringMode = FALSE + nodeRenderingMode = WEM_NODE_RENDERING_NORMAL + boundingBoxMode = WEM_BOUNDING_BOX_AXIS_ALIGNED + primitiveValueLists = LUT + selectedPrimitiveValueList = LUT + primitiveValueListValid = FALSE + selectedTab = 0 + } +} +module WEMSubdivide { + internal { + frame = "725 453 120 56" + moduleGroupName = "" + windows { + window _default { + geometry = "580 345 341 413" + sizeHint = "341 413" + wasOpen = no + } + } + } + fields { + instanceName = WEMSubdivide1 + isProcessing = FALSE + elapsedTime = 0.0070000002 + id = 0 + autoApply = TRUE + autoUpdate = TRUE + autoClear = FALSE + removePreviousWEMs = TRUE + label = "" + description = "" + show = TRUE + editable = TRUE + colorMode = "General " + drawFaces = TRUE + useFaceAmbientColor = TRUE + faceAmbientColor = "0.266667008399963 0.266667008399963 0.266667008399963" + useFaceDiffuseColor = TRUE + faceDiffuseColor = "0.792156994342804 0.792156994342804 0.792156994342804" + useFaceSpecularColor = TRUE + faceSpecularColor = "0.0666669979691505 0.0666669979691505 0.0666669979691505" + faceAlphaValue = 1 + faceShininessValue = 1 + drawFaceNormals = FALSE + faceNormalsColor = "1 1 1" + faceNormalsScale = 1 + drawEdges = FALSE + edgeColor = "0 0 0" + usePolygonOffset = FALSE + lineWidth = 1 + useEdgeColoringMode = FALSE + drawNodes = FALSE + nodeColor = "1 1 1" + drawNodeNormals = FALSE + nodeNormalsColor = "1 1 1" + nodeNormalsScale = 1 + pointSize = 1 + nodeRenderingMode = Normal + drawBoundingBoxes = FALSE + boundingBoxMode = "Axis Aligned" + boundingBoxColor = "1 1 1" + copyInputWEMs = TRUE + listenToFinishNotifications = TRUE + forwardRepaintNotifications = TRUE + forwardSelectionNotifications = TRUE + triangulationMode = Strip + modifyAttributes = FALSE + maxEdgeLength = 0.15000001 + selectedTab = 0 + outputTabSelected = TRUE + } +} +module WEMSubdivide { + internal { + frame = "581 453 120 56" + moduleGroupName = "" + windows { + window _default { + geometry = "895 469 341 413" + sizeHint = "341 413" + wasOpen = no + } + } + } + fields { + instanceName = WEMSubdivide + isProcessing = FALSE + elapsedTime = 0.0080000004 + id = 0 + autoApply = TRUE + autoUpdate = TRUE + autoClear = FALSE + removePreviousWEMs = TRUE + label = "" + description = "" + show = TRUE + editable = TRUE + colorMode = "General " + drawFaces = TRUE + useFaceAmbientColor = TRUE + faceAmbientColor = "0.266667008399963 0.266667008399963 0.266667008399963" + useFaceDiffuseColor = TRUE + faceDiffuseColor = "0.792156994342804 0.792156994342804 0.792156994342804" + useFaceSpecularColor = TRUE + faceSpecularColor = "0.0666669979691505 0.0666669979691505 0.0666669979691505" + faceAlphaValue = 1 + faceShininessValue = 1 + drawFaceNormals = FALSE + faceNormalsColor = "1 1 1" + faceNormalsScale = 1 + drawEdges = FALSE + edgeColor = "0 0 0" + usePolygonOffset = FALSE + lineWidth = 1 + useEdgeColoringMode = FALSE + drawNodes = FALSE + nodeColor = "1 1 1" + drawNodeNormals = FALSE + nodeNormalsColor = "1 1 1" + nodeNormalsScale = 1 + pointSize = 1 + nodeRenderingMode = Normal + drawBoundingBoxes = FALSE + boundingBoxMode = "Axis Aligned" + boundingBoxColor = "1 1 1" + copyInputWEMs = TRUE + listenToFinishNotifications = TRUE + forwardRepaintNotifications = TRUE + forwardSelectionNotifications = TRUE + triangulationMode = Strip + modifyAttributes = FALSE + maxEdgeLength = 0.15000001 + selectedTab = 0 + outputTabSelected = TRUE + } +} +module SoDepthPeelRenderer { + internal { + frame = "677 37 152 56" + moduleGroupName = "" + windows { + window _default { + geometry = "814 471 299 316" + sizeHint = "299 316" + wasOpen = no + } + } + } + fields { + instanceName = SoDepthPeelRenderer + renderCaching = AUTO + boundingBoxCaching = AUTO + renderCulling = AUTO + pickCulling = AUTO + useFBO = TRUE + useDepthPeeling = TRUE + useStencilBuffer = FALSE + layers = 4 + simulatedAlpha = 1 + opaqueBackgroundPass = TRUE + sceneDepthCompare = FALSE + debugLayers = FALSE + changeLayerColor = FALSE + layer1Color = "1 1 1" + layer2Color = "1 1 1" + layer3Color = "1 1 1" + layer4Color = "1 1 1" + layer5Color = "1 1 1" + layer6Color = "1 1 1" + layer7Color = "1 1 1" + layer8Color = "1 1 1" + } +} +module Comment { + internal { + frame = "453 541 88 56" + moduleGroupName = "" + windows { + window _default { + geometry = "567 152 256 442" + sizeHint = "256 208" + wasOpen = no + } + } + } + fields { + instanceName = Comment + comment = " +In this example, there are two subdivided surfaces of which the nodes' distances are measured. Because of the relative high node density, this holds as the surface distance. + +Note that the distances are signed. As can be seen in the SoLUTEditor, negative distances are mapped to red colors, and positive distances are mapped to green colors. A zero distance is mapped to yellow. + +This is reflected by the coloring of the larger surface in this example, which is the first input WEM of the featured module." + } +} +module SoWEMRenderer { + internal { + frame = "565 125 136 56" + moduleGroupName = "" + windows { + window _default { + geometry = "868 388 337 404" + sizeHint = "337 404" + wasOpen = no + } + } + } + fields { + instanceName = SoWEMRenderer2 + renderCaching = AUTO + boundingBoxCaching = AUTO + renderCulling = AUTO + pickCulling = AUTO + autoApply = TRUE + autoUpdate = TRUE + autoClear = TRUE + useHighlightSelected = FALSE + usePolygonOffset = TRUE + useShapeHints = TRUE + allowHits = TRUE + parameterOverwriteMode = OVERWRITE_MODE_ALL + overwriteColorMode = FALSE + overwriteFaceParameters = FALSE + overwriteEdgeParameters = FALSE + overwriteNodeParameters = FALSE + overwriteBoundingBoxParameters = FALSE + colorMode = WEM_COLOR_LUT_VALUES + drawFaces = TRUE + faceDiffuseColor = "0.792156994342804 0.792156994342804 0.792156994342804" + useFaceAmbientColor = TRUE + faceAmbientColor = "0.266667008399963 0.266667008399963 0.266667008399963" + useFaceSpecularColor = TRUE + faceSpecularColor = "0.0666669979691505 0.0666669979691505 0.0666669979691505" + drawEdges = TRUE + edgeColor = "0 0 0" + drawNodes = FALSE + nodeColor = "1 1 1" + drawBoundingBoxes = FALSE + boundingBoxColor = "1 1 1" + drawFaceNormals = FALSE + drawNodeNormals = FALSE + faceNormalColor = "1 1 1" + nodeNormalColor = "1 1 1" + faceNormalScaling = 1 + nodeNormalScaling = 1 + faceAlphaValue = 1 + faceShininessValue = 1 + lineWidth = 1 + pointSize = 4 + useEdgeColoringMode = TRUE + nodeRenderingMode = WEM_NODE_RENDERING_NORMAL + boundingBoxMode = WEM_BOUNDING_BOX_AXIS_ALIGNED + primitiveValueLists = LUT,textureS,textureT + selectedPrimitiveValueList = LUT + primitiveValueListValid = TRUE + selectedTab = 0 + } +} +module SoLUTEditor { + internal { + frame = "733 285 104 56" + moduleGroupName = "" + windows { + window _default { + geometry = "937 444 528 450" + sizeHint = "528 450" + wasOpen = no + } + } + } + fields { + instanceName = SoLUTEditor + currentColor = "1 1 1" + currentOpacity = 1 + currentPosition = -0.47765899 + currentIndex = 0 + rangeMin = -0.47765899 + rangeMax = 1.15326 + viewMin = -0.47765899 + viewMax = 1.15326 + window = 1 + level = 0.5 + allowNewPoints = TRUE + colorIsValid = TRUE + opacityIsValid = TRUE + updateLutWhileDragging = TRUE + relativeLut = FALSE + rangeInfo = [-0.48,1.15] + viewRangeInfo = [-0.48,1.15] + colorInterpolation = InterpolateRGB + colorPoints = "[ -0.477659 1 0 0, -0.150096 0.988235 0.329412 0, -0.039759 0.901961 0.984314 0, 0.0154095 0.984314 1 0, 0.0809221 1 0.933333 0, 0.191259 0.180392 1 0, 1.15326 0.14902 1 0 ]" + alphaPoints = "[ -0.477659 1, -0.150096 1, -0.039759 1, 0.0154095 1, 0.0809221 1, 0.191259 1, 1.15326 1 ]" + alphaFactor = 1 + newRangeMin = -0.83200628 + newRangeMax = 0.36895853 + newRangeMode = ClipFormerLUT + colorEditorHeight = 24 + showColorEditor = TRUE + showAlphaEditor = TRUE + markerRadius = 4 + selectedMarkerRadius = 6 + snapMarkerRadius = 10 + alphaLineWidth = 2 + backgroundColor = "0.800000011920929 0.800000011920929 0.800000011920929" + borderColor = "0 0 0" + alphaLineColor = "0 0 0" + histogramColor = "0.400000005960464 0.400000005960464 0.400000005960464" + drawColoredMarkers = TRUE + markerColor = "1 1 1" + selectedMarkerColor = "1 0.5 0.5" + selectedTriangleSize = 8 + triangleSize = 6 + useAntiAliasing = TRUE + } +} +module SoBackground { + internal { + frame = "553 37 112 56" + moduleGroupName = "" + } + fields { + instanceName = SoBackground + rotate = TRUE + flip = FALSE + on = TRUE + depthBuffer = TRUE + } +} +module SoExaminerViewer { + internal { + frame = "621 -51 136 56" + moduleGroupName = "" + windows { + window _viewer { + geometry = "24 136 479 488" + sizeHint = "400 400" + wasOpen = no + } + window _automatic { + geometry = "721 409 484 440" + sizeHint = "484 440" + wasOpen = no + } + window _default { + geometry = "706 451 515 356" + sizeHint = "515 356" + wasOpen = no + } + } + } + fields { + instanceName = SoExaminerViewer + renderCaching = AUTO + boundingBoxCaching = AUTO + renderCulling = AUTO + pickCulling = AUTO + border = FALSE + background = "0 0 0" + transparency = BLEND + antialiasing = FALSE + antialiasingNumPasses = 1 + grabKeyFocus = TRUE + snapshotFormat = SNAPSHOT_RGB + outputAviFile = "" + autoRedrawWhenRecording = TRUE + frameRate = 7 + frameRateAvi = 15 + status = ready + outputSnapshotFile = none + outputSnapshotFileWritten = none + autoIncreaseFile = TRUE + autoUpdateML = FALSE + showSnapshotWithShell = FALSE + snapCount = 0 + inputDevicesList = "" + headlight = TRUE + decoration = TRUE + popupMenuEnabled = FALSE + viewing = TRUE + autoClipping = TRUE + drawStyle = VIEW_AS_IS + interactiveDrawStyle = VIEW_AS_IS + viewAllFlag = FALSE + initialCameraOrientation = CAMERA_KEEP_AS_IS + applyCameraOrientation = CAMERA_KEEP_AS_IS + cameraType = CAMERA_PERSPECTIVE + autoApplyUserSettingOrientation = FALSE + userSettingOrientation = "0 0 1 0" + automaticViewAll = FALSE + storeCurrentState = TRUE + saveCamera = TRUE + cursor = TRUE + isCameraStored = TRUE + perspective = TRUE + stereoViewing = FALSE + stereoOffset = 3 + height = 0.78539801 + position = "1.83696806430817 -2.82437872886658 -0.01137375831604" + orientation = "0.47944387793541 -0.545186221599579 0.687681376934052 2.77806353569031" + nearDistance = 1.878475 + farDistance = 4.4677987 + focalDistance = 3.3069699 + forceRedrawOnInteraction = FALSE + button1events = TO_VIEWER + button2events = TO_VIEWER + button3events = TO_VIEWER + keyEvents = TO_VIEWER + animationEnabled = FALSE + feedback = FALSE + feedbackSize = 32 + mouseInteraction = "" + rotationAxis = "0 1 0" + rotationAngle = 360 + rotationSteps = 80 + rotationCurrentStep = 0 + recordRotation = TRUE + } +} +module SoWEMRenderer { + internal { + frame = "705 125 128 56" + moduleGroupName = "" + windows { + window _default { + geometry = "889 414 337 404" + sizeHint = "337 404" + wasOpen = no + } + } + } + fields { + instanceName = SoWEMRenderer + renderCaching = AUTO + boundingBoxCaching = AUTO + renderCulling = AUTO + pickCulling = AUTO + autoApply = TRUE + autoUpdate = TRUE + autoClear = TRUE + useHighlightSelected = FALSE + usePolygonOffset = TRUE + useShapeHints = TRUE + allowHits = TRUE + parameterOverwriteMode = OVERWRITE_MODE_ALL + overwriteColorMode = FALSE + overwriteFaceParameters = FALSE + overwriteEdgeParameters = FALSE + overwriteNodeParameters = FALSE + overwriteBoundingBoxParameters = FALSE + colorMode = WEM_COLOR_GENERAL + drawFaces = TRUE + faceDiffuseColor = "0.792156994342804 0.792156994342804 0.792156994342804" + useFaceAmbientColor = TRUE + faceAmbientColor = "0.266667008399963 0.266667008399963 0.266667008399963" + useFaceSpecularColor = TRUE + faceSpecularColor = "0.0666669979691505 0.0666669979691505 0.0666669979691505" + drawEdges = FALSE + edgeColor = "0 0 0" + drawNodes = FALSE + nodeColor = "1 1 1" + drawBoundingBoxes = FALSE + boundingBoxColor = "1 1 1" + drawFaceNormals = FALSE + drawNodeNormals = FALSE + faceNormalColor = "1 1 1" + nodeNormalColor = "1 1 1" + faceNormalScaling = 1 + nodeNormalScaling = 1 + faceAlphaValue = 0.60000002 + faceShininessValue = 1 + lineWidth = 1 + pointSize = 1 + useEdgeColoringMode = FALSE + nodeRenderingMode = WEM_NODE_RENDERING_NORMAL + boundingBoxMode = WEM_BOUNDING_BOX_AXIS_ALIGNED + primitiveValueLists = LUT,textureS,textureT + selectedPrimitiveValueList = LUT + primitiveValueListValid = FALSE + selectedTab = 0 + } +} +module WEMInitialize { + internal { + frame = "801 541 112 56" + moduleGroupName = "" + windows { + window _default { + geometry = "473 353 341 377" + sizeHint = "341 377" + wasOpen = no + } + } + } + fields { + instanceName = WEMInitialize1 + isProcessing = FALSE + elapsedTime = 0.0020000001 + id = 0 + autoApply = TRUE + autoUpdate = TRUE + autoClear = FALSE + removePreviousWEMs = TRUE + label = "" + description = "" + show = TRUE + editable = TRUE + colorMode = "General " + drawFaces = TRUE + useFaceAmbientColor = TRUE + faceAmbientColor = "0.266667008399963 0.266667008399963 0.266667008399963" + useFaceDiffuseColor = TRUE + faceDiffuseColor = "0.792156994342804 0.792156994342804 0.792156994342804" + useFaceSpecularColor = TRUE + faceSpecularColor = "0.0666669979691505 0.0666669979691505 0.0666669979691505" + faceAlphaValue = 1 + faceShininessValue = 1 + drawFaceNormals = FALSE + faceNormalsColor = "1 1 1" + faceNormalsScale = 1 + drawEdges = FALSE + edgeColor = "0 0 0" + usePolygonOffset = FALSE + lineWidth = 1 + useEdgeColoringMode = FALSE + drawNodes = FALSE + nodeColor = "1 1 1" + drawNodeNormals = FALSE + nodeNormalsColor = "1 1 1" + nodeNormalsScale = 1 + pointSize = 1 + nodeRenderingMode = Normal + drawBoundingBoxes = FALSE + boundingBoxMode = "Axis Aligned" + boundingBoxColor = "1 1 1" + initialPosition = "0 0 0" + initialDeformation = "1 1 1" + initModel = Dodecahedron + mirrorFaces = FALSE + generateEdges = TRUE + selectedTab = 0 + } +} +module WEMInitialize { + internal { + frame = "589 549 104 56" + moduleGroupName = "" + windows { + window _default { + geometry = "310 674 341 377" + sizeHint = "341 377" + wasOpen = no + } + } + } + fields { + instanceName = WEMInitialize + isProcessing = FALSE + elapsedTime = 0.003 + id = 0 + autoApply = TRUE + autoUpdate = TRUE + autoClear = FALSE + removePreviousWEMs = TRUE + label = "" + description = "" + show = TRUE + editable = TRUE + colorMode = "General " + drawFaces = TRUE + useFaceAmbientColor = TRUE + faceAmbientColor = "0.266667008399963 0.266667008399963 0.266667008399963" + useFaceDiffuseColor = TRUE + faceDiffuseColor = "0.792156994342804 0.792156994342804 0.792156994342804" + useFaceSpecularColor = TRUE + faceSpecularColor = "0.0666669979691505 0.0666669979691505 0.0666669979691505" + faceAlphaValue = 1 + faceShininessValue = 1 + drawFaceNormals = FALSE + faceNormalsColor = "1 1 1" + faceNormalsScale = 1 + drawEdges = FALSE + edgeColor = "0 0 0" + usePolygonOffset = FALSE + lineWidth = 1 + useEdgeColoringMode = FALSE + drawNodes = FALSE + nodeColor = "1 1 1" + drawNodeNormals = FALSE + nodeNormalsColor = "1 1 1" + nodeNormalsScale = 1 + pointSize = 1 + nodeRenderingMode = Normal + drawBoundingBoxes = FALSE + boundingBoxMode = "Axis Aligned" + boundingBoxColor = "1 1 1" + initialPosition = "0.5 0.1 0.1" + initialDeformation = "1.4 0.9 0.9" + initModel = Dodecahedron + mirrorFaces = FALSE + generateEdges = TRUE + selectedTab = 0 + } +} +module WEMSurfaceDistance { + internal { + frame = "565 285 152 56" + moduleGroupName = "" + windows { + window _default { + geometry = "883 375 341 471" + sizeHint = "341 471" + wasOpen = no + } + } + } + fields { + instanceName = WEMSurfaceDistance + isProcessing = FALSE + elapsedTime = 0.204 + id = 0 + autoApply = TRUE + autoUpdate = TRUE + autoClear = FALSE + removePreviousWEMs = TRUE + label = "" + description = "" + show = TRUE + editable = TRUE + colorMode = "General " + drawFaces = TRUE + useFaceAmbientColor = TRUE + faceAmbientColor = "0.266667008399963 0.266667008399963 0.266667008399963" + useFaceDiffuseColor = TRUE + faceDiffuseColor = "0.792156994342804 0.792156994342804 0.792156994342804" + useFaceSpecularColor = TRUE + faceSpecularColor = "0.0666669979691505 0.0666669979691505 0.0666669979691505" + faceAlphaValue = 1 + faceShininessValue = 1 + drawFaceNormals = FALSE + faceNormalsColor = "1 1 1" + faceNormalsScale = 1 + drawEdges = FALSE + edgeColor = "0 0 0" + usePolygonOffset = FALSE + lineWidth = 1 + useEdgeColoringMode = FALSE + drawNodes = FALSE + nodeColor = "1 1 1" + drawNodeNormals = FALSE + nodeNormalsColor = "1 1 1" + nodeNormalsScale = 1 + pointSize = 1 + nodeRenderingMode = Normal + drawBoundingBoxes = FALSE + boundingBoxMode = "Axis Aligned" + boundingBoxColor = "1 1 1" + copyInputWEMs = TRUE + listenToFinishNotifications = TRUE + forwardRepaintNotifications = TRUE + forwardSelectionNotifications = TRUE + progress = 0 + triangulationMode = Strip + modifyAttributes = FALSE + relativeError = 0 + numEntries = 200 + shouldComputeSignedDistances = TRUE + addEdgesToNearestNodes = FALSE + shouldNormalizeDist = FALSE + useLUTPrimitiveValueList = TRUE + customPrimitiveValueList = "Surface Distance" + selectedTab = 0 + outputTabSelected = TRUE + } +} +connections { + WEMDistances.WEM0 = WEMSubdivide.outWEM + WEMDistances.WEM1 = WEMSubdivide1.outWEM + SoWEMRenderer1.inWEM = WEMInitialize1.outWEM + WEMSubdivide1.inWEM = WEMInitialize1.outWEM + WEMSubdivide1.maxEdgeLength = WEMSubdivide.maxEdgeLength + WEMSubdivide.inWEM = WEMInitialize.outWEM + SoDepthPeelRenderer.children = "SoWEMRenderer2.self SoWEMRenderer.self" + SoWEMRenderer2.inWEM = WEMSurfaceDistance.outWEM + SoWEMRenderer2.inLUT = SoLUTEditor.outLUT + SoLUTEditor.newRangeMin = WEMSurfaceDistance.minimumDistance + SoLUTEditor.newRangeMax = WEMSurfaceDistance.maximumDistance + SoExaminerViewer.children = "SoBackground.self SoDepthPeelRenderer.self SoWEMRenderer1.self" + SoWEMRenderer.inWEM = WEMSubdivide1.outWEM + WEMSurfaceDistance.inWEM = WEMSubdivide.outWEM + WEMSurfaceDistance.inWEM2 = WEMSubdivide1.outWEM +} +networkModel = "" This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rha...@us...> - 2011-09-26 14:24:15
|
Revision: 384 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=384&view=rev Author: rhameeteman Date: 2011-09-26 14:24:04 +0000 (Mon, 26 Sep 2011) Log Message: ----------- KH. * Added the posibility to calculate the distances between the COSs (with the same index) of two input Lists * Added a mode field specifying how to find the matching CSO, default is still the old behavior show the distance between the first 2 CSO of input0 and only the minimal distance. Modified Paths: -------------- trunk/Community/General/Modules/ML/MLCSOCommunityModules/MLCSOCommunityModules.def trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.h Modified: trunk/Community/General/Modules/ML/MLCSOCommunityModules/MLCSOCommunityModules.def =================================================================== --- trunk/Community/General/Modules/ML/MLCSOCommunityModules/MLCSOCommunityModules.def 2011-09-26 13:41:31 UTC (rev 383) +++ trunk/Community/General/Modules/ML/MLCSOCommunityModules/MLCSOCommunityModules.def 2011-09-26 14:24:04 UTC (rev 384) @@ -13,7 +13,7 @@ documentation = "$(LOCAL)/CSODistance/CSODistance.html" Window { - Category { + Category Totals { Field minimumDistance { edit = NO minLength = 10 } Separator { direction = Horizontal } Field minimumDistancePoint1 { minLength = 10 } @@ -27,12 +27,25 @@ Separator { direction = Horizontal } + RadioButtonGroup mode {} + Horizontal { + alignX = Left + Label {title = "Curve statistic:" } + ButtonBar curveStatistic { show = One } + } Horizontal { alignX = Right CheckBox = autoApply Button = apply } } + Category Distances { + expandY = Yes + ListView distances { + expandY = Yes + columnSeparator = "," + } + } } }// MLModule CSODistance Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp 2011-09-26 13:41:31 UTC (rev 383) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.cpp 2011-09-26 14:24:04 UTC (rev 384) @@ -15,23 +15,42 @@ handleNotificationOff(); - _csoList = NULL; + _csoList0 = NULL; + _csoList1 = NULL; + _tableHeader = "Id1,Id2,min,max,mean,stdDev"; FieldContainer* fieldC = getFieldContainer(); ML_CHECK(fieldC); - (_inputCSOFld = fieldC->addBase("inCSOList"))->setBaseValue(NULL); + (_input0CSOFld = fieldC->addBase("inCSOList"))->setBaseValue(NULL); + (_input1CSOFld = fieldC->addBase("inCSOList1"))->setBaseValue(NULL); ////////////////////////////////////////////////////////////////////////// + char* distanceModes[LASTMODE]; + distanceModes[ FIRST2 ] = "First 2 CSOs"; + distanceModes[ INPLANE ] = "Match in plane CSOs"; + distanceModes[ TWOINPUTS ] = "Match index of two CSOLists"; + _modeFld = fieldC->addEnum("mode",distanceModes,LASTMODE); + _modeFld->setEnumValue( FIRST2 ); + + ////////////////////////////////////////////////////////////////////////// + (_minimumDistanceFld = fieldC->addFloat("minimumDistance"))->setFloatValue(0); (_minimumDistancePoint1Fld = fieldC->addVec3f("minimumDistancePoint1"))->setVec3fValue(vec3(0.0,0.0,0.0)); (_minimumDistancePoint2Fld = fieldC->addVec3f("minimumDistancePoint2"))->setVec3fValue(vec3(0.0,0.0,0.0)); + _distancesFld = addString("distances",_tableHeader ); ////////////////////////////////////////////////////////////////////////// + _tolleranceFld = addDouble("tollerance", 0.0001 ); + + ////////////////////////////////////////////////////////////////////////// + _applyFld = fieldC->addNotify("apply"); (_autoApplyFld = fieldC->addBool("autoApply"))->setBoolValue(true); + _statusFld = fieldC->addString("status"); + _statusFld->setStringValue("Ready"); ////////////////////////////////////////////////////////////////////////// @@ -42,12 +61,21 @@ (_listenToSelectionChangedNotificationsFld = fieldC->addBool("listenToSelectionChangedNotifications")) ->setBoolValue(false); + char* statisticsNames[LASTSTATISTIC]; + statisticsNames[ MIN ] = "Minimum"; + statisticsNames[ MAX ] = "Maximum"; + statisticsNames[ MEAN ] = "Mean"; + statisticsNames[ STDEV ] = "StDev"; + _curveStatistic = addEnum("curveStatistic",statisticsNames,LASTSTATISTIC ); + _isInNotificationCB = false; ML_CHECK_NEW(_outputXMarkerList,XMarkerList()); (_outputXMarkerListFld = getFieldContainer()->addBase("outputXMarkerList"))->setBaseValue(NULL); + _outputCurveList = new CurveList; + (_outputCurveListFld = getFieldContainer()->addBase("outputCurveList"))->setBaseValue( _outputCurveList ); handleNotificationOn(); } @@ -58,11 +86,19 @@ { ML_TRACE_IN("CSODistance::~CSODistance()"); - if (_csoList != NULL){ - _csoList->removeNotificationObserver(_csoListNotificationCB, this); + if (_csoList0 != NULL){ + _csoList0->removeNotificationObserver(_csoListNotificationCB, this); } ML_DELETE(_outputXMarkerList); + + // Delete all created CurveData objects + while ( !_outputCurveList->getCurveList().empty() ) { + ML_DELETE( _outputCurveList->getCurveList().back() ); + _outputCurveList->getCurveList().pop_back(); + } + ML_DELETE( _outputCurveList ); + } ////////////////////////////////////////////////////////////////////////// @@ -84,26 +120,46 @@ { ML_TRACE_IN("void CSODistance::handleNotification(Field* field)"); - if (field == _inputCSOFld){ + if (field == _input0CSOFld){ - if (!_isInNotificationCB) { CSOList::removeNotificationObserverFromAllCSOLists(_csoListNotificationCB, this);} + if (!_isInNotificationCB && _csoList0 ) { _csoList0->removeNotificationObserver(_csoListNotificationCB, this);} - if (BASE_IS_A((static_cast<Base*>(_inputCSOFld->getBaseValue())), CSOList)){ + if (BASE_IS_A((static_cast<Base*>(_input0CSOFld->getBaseValue())), CSOList)){ - _csoList = static_cast<CSOList*>(_inputCSOFld->getBaseValue()); + _csoList0 = static_cast<CSOList*>(_input0CSOFld->getBaseValue()); - if (_csoList != NULL){ + if (_csoList0 != NULL){ - if (!_isInNotificationCB) { _csoList->addNotificationObserver(_csoListNotificationCB, this); } + if (!_isInNotificationCB) { _csoList0->addNotificationObserver(_csoListNotificationCB, this); } } } else { - _csoList = NULL; + _csoList0 = NULL; } if (_autoApplyFld->getBoolValue()) { _process(); } } else - if (field == _applyFld) { + if (field == _input1CSOFld){ + + if (!_isInNotificationCB && _csoList1 ) { _csoList1->removeNotificationObserver(_csoListNotificationCB, this);} + + if (BASE_IS_A((static_cast<Base*>(_input1CSOFld->getBaseValue())), CSOList)){ + + _csoList1 = static_cast<CSOList*>(_input1CSOFld->getBaseValue()); + + if (_csoList1 != NULL){ + + if (!_isInNotificationCB) { _csoList1->addNotificationObserver(_csoListNotificationCB, this); } + } + } else { + + _csoList1 = NULL; + } + + if (_autoApplyFld->getBoolValue()) { _process(); } + } else + if ( field == _applyFld || ( _autoApplyFld->getBoolValue() && + ( field == _tolleranceFld || field == _curveStatistic )) ){ _process(); } @@ -119,56 +175,248 @@ _outputXMarkerList->clearList(); - if (_csoList != NULL) { + // Delete all created CurveData objects + while ( !_outputCurveList->getCurveList().empty() ) { + ML_DELETE( _outputCurveList->getCurveList().back() ); + _outputCurveList->getCurveList().pop_back(); + } - if ((_csoList->numCSO() >= 2) && (_csoList->getCSOAt(0)->getIsFinished()) && (_csoList->getCSOAt(1)->getIsFinished())) { - MinimalDistancePointClouds* pointSetsMinDist = NULL; - ML_CHECK_NEW(pointSetsMinDist, MinimalDistancePointClouds); + if (_csoList0 != NULL) { - std::vector<vec3>pointSet1; - std::vector<vec3>pointSet2; - - _csoList->getCSOAt(0)->fillPathPointCoordinatesFlattened(pointSet1); - _csoList->getCSOAt(1)->fillPathPointCoordinatesFlattened(pointSet2); + int nCSOs = _csoList0->numCSO(); - pointSetsMinDist->setPointSets(pointSet1, pointSet2); - pointSetsMinDist->setNumEntries(200); + double minDistance = 0.0; + double maxDistance = 0.0; + double avgDistance = 0.0; + double stdDevDistance = 0.0; - vec3 nPoint1, nPoint2; - pointSetsMinDist->computeDistance(nPoint1,nPoint2); + std::stringstream distances; + distances << _tableHeader << std::endl; - _minimumDistancePoint1Fld->setVec3fValue(nPoint1); - _minimumDistancePoint2Fld->setVec3fValue(nPoint2); - double distance = sqrt((nPoint1[0]-nPoint2[0])*(nPoint1[0]-nPoint2[0]) + - (nPoint1[1]-nPoint2[1])*(nPoint1[1]-nPoint2[1]) + - (nPoint1[2]-nPoint2[2])*(nPoint1[2]-nPoint2[2])); + switch ( _modeFld->getEnumValue() ){ + case FIRST2 : + { + if ((nCSOs >= 2) && (_csoList0->getCSOAt(0)->getIsFinished()) && (_csoList0->getCSOAt(1)->getIsFinished())) { + std::vector<vec3>pointSet1; + std::vector<vec3>pointSet2; + + _csoList0->getCSOAt(0)->fillPathPointCoordinatesFlattened(pointSet1); + _csoList0->getCSOAt(1)->fillPathPointCoordinatesFlattened(pointSet2); - _minimumDistanceFld->setFloatValue(distance); + Vector3 minPoint1,minPoint2,maxPoint1,maxPoint2; - _outputXMarkerList->appendItem(XMarker(vec6(nPoint1[0],nPoint1[1],nPoint1[2],0.5f,0.0f,0.0f), - vec3(nPoint2[0]-nPoint1[0],nPoint2[1]-nPoint1[1],0.0f), - 0,"")); - - ML_DELETE(pointSetsMinDist); + MinimalDistancePointClouds* pointSetsMinDist = NULL; + ML_CHECK_NEW(pointSetsMinDist, MinimalDistancePointClouds); + + pointSetsMinDist->setPointSets(pointSet1, pointSet2); + pointSetsMinDist->setNumEntries(200); + pointSetsMinDist->computeDistance(minPoint1,minPoint2); - } else { - _minimumDistancePoint1Fld->setVec3fValue(vec3(0.0,0.0,0.0)); - _minimumDistancePoint2Fld->setVec3fValue(vec3(0.0,0.0,0.0)); - _minimumDistanceFld->setFloatValue(0.0f); + minDistance = sqrt((minPoint1[0]-minPoint2[0])*(minPoint1[0]-minPoint2[0]) + + (minPoint1[1]-minPoint2[1])*(minPoint1[1]-minPoint2[1]) + + (minPoint1[2]-minPoint2[2])*(minPoint1[2]-minPoint2[2])); + + + + _minimumDistanceFld->setFloatValue( static_cast<float>(minDistance)); + + _outputXMarkerList->appendItem(XMarker( vec6(minPoint1[0],minPoint1[1],minPoint1[2],0.5f,0.0f,0.0f), + vec3(minPoint2[0]-minPoint1[0],minPoint2[1]-minPoint1[1],minPoint2[2]-minPoint1[2]), + 0,"")); + distances << _csoList0->getCSOAt(0)->getId() << "," + << _csoList0->getCSOAt(1)->getId() << "," + << minDistance << "," + << maxDistance << "," + << avgDistance << "," + << stdDevDistance + << std::endl; + } else { + _minimumDistancePoint1Fld->setVec3fValue(vec3(0.0,0.0,0.0)); + _minimumDistancePoint2Fld->setVec3fValue(vec3(0.0,0.0,0.0)); + _minimumDistanceFld->setFloatValue(0.0f); + _distancesFld->setStringValue( _tableHeader ); + } + break; + } + case INPLANE: + { + CurveData *outputCurve = new CurveData; + double *yValues = new double[ nCSOs ]; + + double minDist = ML_DOUBLE_MAX; + vec3 point1; + vec3 point2; + for ( int iCSO = 0; iCSO<nCSOs; ++iCSO ){ + CSO* currentCSO = _csoList0->getCSOAt( iCSO ); + CSO* matchingCSO = _findMatchingCSO(iCSO); + if (!matchingCSO) {continue;} + + std::vector<vec3>pointSet1; + std::vector<vec3>pointSet2; + currentCSO->fillPathPointCoordinatesFlattened(pointSet1); + matchingCSO->fillPathPointCoordinatesFlattened(pointSet2); + + Vector3 minPoint1,minPoint2,maxPoint1,maxPoint2; + + _getDistances( pointSet1, pointSet2, + minDistance,maxDistance,avgDistance,stdDevDistance, + minPoint1,minPoint2,maxPoint1,maxPoint2); + + distances << currentCSO->getId() << "," + << matchingCSO->getId() << "," + << minDistance << "," + << maxDistance << "," + << avgDistance << "," + << stdDevDistance + << std::endl; + + if ( minDistance < minDist ){ + minDist = minDistance; + point1 = minPoint1; + point2 = minPoint2; + } + + _outputXMarkerList->appendItem(XMarker( vec6(minPoint1[0],minPoint1[1],minPoint1[2],0.5f,0.0f,0.0f), + vec3(minPoint2[0]-minPoint1[0],minPoint2[1]-minPoint1[1],minPoint2[2]-minPoint1[2]), + currentCSO->getId(),"")); + + switch ( _curveStatistic->getEnumValue() ){ + case MIN: + yValues[ iCSO ] = minDistance; + break; + case MAX: + yValues[ iCSO ] = maxDistance; + break; + case MEAN: + yValues[ iCSO ] = avgDistance; + break; + case STDEV: + yValues[ iCSO ] = stdDevDistance; + break; + default: + break; + } + } // iCSO + outputCurve->setY( nCSOs, yValues); + delete[] yValues; + _outputCurveList->getCurveList().push_back( outputCurve ); + _distancesFld->setStringValue( distances.str() ); + _minimumDistancePoint1Fld->setVec3fValue(point1); + _minimumDistancePoint2Fld->setVec3fValue(point2); + _minimumDistanceFld->setFloatValue( static_cast<float>(minDistance) ); + break; + } + default: + break; } + } else { _minimumDistancePoint1Fld->setVec3fValue(vec3(0.0,0.0,0.0)); _minimumDistancePoint2Fld->setVec3fValue(vec3(0.0,0.0,0.0)); _minimumDistanceFld->setFloatValue(0.0f); + _distancesFld->setStringValue( _tableHeader ); } _outputXMarkerListFld->setBaseValue(_outputXMarkerList); + _outputCurveListFld->touch(); } ////////////////////////////////////////////////////////////////////////// +void CSODistance::_getDistances( std::vector<Vector3> &set1, + std::vector<Vector3> &set2, + double &minDistance, + double &maxDistance, + double &averageDistance, + double &stdDevDistance, + Vector3 &minPoint1, + Vector3 &minPoint2, + Vector3 &maxPoint1, + Vector3 &maxPoint2) +{ + + + minDistance = ML_DOUBLE_MAX; + maxDistance = 0.0; + double sumDist = 0.0; + double sqrDist = 0.0; + for(int i = 0; i < int(set1.size()); i++) + { + Vector3 pos1 = set1[i]; + Vector3 pos2; + double currentDistance = ML_DOUBLE_MAX; + for(int j = 0; j < int( set2.size() ); j++) + { + Vector3 pos = set2[j]; + double dist = (pos1 - pos).length(); + if ( dist < currentDistance ){ + currentDistance = dist; + pos2 = pos; + } + } + + if ( minDistance > currentDistance ){ + minDistance = currentDistance; + minPoint1 = pos1; + minPoint2 = pos2; + } + if (maxDistance < currentDistance ){ + maxDistance = currentDistance; + maxPoint1 = pos1; + maxPoint2 = pos2; + } + sumDist += currentDistance; + sqrDist += currentDistance*currentDistance; + } + double nPoints = ( set1.size() ? static_cast<double>(set1.size()) : 1.0); + averageDistance = sumDist/nPoints; + stdDevDistance = sqrDist/nPoints - averageDistance*averageDistance; +} + +////////////////////////////////////////////////////////////////////////// + +CSO* CSODistance::_findMatchingCSO(int findCSO) +{ + CSO* matchingCSO = NULL; + + if ( _modeFld->getEnumValue() == TWOINPUTS && _csoList0 != NULL && _csoList1 != NULL) { + if (findCSO < static_cast<int>( _csoList1->numCSO()) ){ + matchingCSO = _csoList1->getCSOAt( findCSO ); + } + } else { + + const int nCSOs = _csoList0->numCSO(); + const CSO* currentCSO = _csoList0->getCSOAt( findCSO ); + const double tollerance = _tolleranceFld->getDoubleValue(); + vec3 currentNormal = currentCSO->getPlaneNormal(); + currentNormal.normalize(); + const vec3 currentPoint = currentCSO->getFirstSeedPoint()->worldPosition; + + double minError = ML_DOUBLE_MAX; + for ( int iCSO = 0; iCSO<nCSOs; ++iCSO ){ + CSO* cso = _csoList0->getCSOAt( iCSO ); + if ( cso == currentCSO ) { continue; } + vec3 normal = cso->getPlaneNormal(); + normal.normalize(); + const vec3 matchingPoint = cso->getFirstSeedPoint()->worldPosition; + const double angleError = 1- abs( currentNormal.dot( normal )); + const double distanceError = abs(currentNormal.dot( matchingPoint - currentPoint )); + const double currentError = angleError + distanceError; + if ( currentError < minError && angleError < tollerance && distanceError < 10*tollerance ) { + minError = currentError; + matchingCSO = cso; + } + } + } + + return matchingCSO; +} + + +////////////////////////////////////////////////////////////////////////// + void CSODistance::_csoListNotificationCB(void* userData, int notificationFlag) { ML_TRACE_IN("void CSODistance::_csoListNotificationCB()"); Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.h =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.h 2011-09-26 13:41:31 UTC (rev 383) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSODistance/CSODistance.h 2011-09-26 14:24:04 UTC (rev 384) @@ -8,6 +8,7 @@ #include "../MinimalDistancePointClouds/MinimalDistancePointClouds.h" #include <mlXMarkerList.h> +#include <mlDiagramData.h> ML_START_NAMESPACE @@ -23,6 +24,8 @@ //! Standard constructor. CSODistance(); + enum {FIRST2=0, INPLANE, TWOINPUTS, LASTMODE}; + protected: //! Standard destructor. @@ -39,8 +42,14 @@ /* FIELDS */ //! CSO input field. - BaseField* _inputCSOFld; + BaseField* _input0CSOFld; + //! CSO input field. + BaseField* _input1CSOFld; + + //! Mode + EnumField* _modeFld; + //! Shall the module update on every event? BoolField* _listenToRepaintNotificationsFld; //! Shall the module listen to finishing events? @@ -48,33 +57,55 @@ //! Shall the module listen to selection change notifications? BoolField* _listenToSelectionChangedNotificationsFld; + //! Only calculate distances for CSOs in the same plane. + DoubleField* _tolleranceFld; + //! Field for displaying the minimum distance. FloatField* _minimumDistanceFld; //! Field for displaying the position of the first point Vec3fField* _minimumDistancePoint1Fld; //! Field for displaying the position of the second point Vec3fField* _minimumDistancePoint2Fld; + //! Field for holding the distances per cso + StringField* _distancesFld; //! Apply field NotifyField* _applyFld; //! Auto apply field BoolField* _autoApplyFld; + //! Status field + StringField* _statusFld; + //! XMarkerList output field BaseField *_outputXMarkerListFld; + //! CurveList output field; + BaseField* _outputCurveListFld; + + //! Output statistic + EnumField* _curveStatistic; + + enum STATISTICS {MIN,MAX,MEAN,STDEV,LASTSTATISTIC}; /* MEMBER VARIABLES */ //! A pointer to the input CSOList. - CSOList* _csoList; + CSOList* _csoList0; + //! A pointer to the input CSOList. + CSOList* _csoList1; + //! Locking variable... bool _isInNotificationCB; //! Output XMarkerList XMarkerList *_outputXMarkerList; + //! output CurveList + CurveList* _outputCurveList; + std::string _tableHeader; + /* METHODS */ //! Reads out information and displays them. @@ -83,6 +114,19 @@ //! Can be notified from anywhere in the network. static void _csoListNotificationCB(void* userData, int notificationFlag); + CSO* _findMatchingCSO(int csoIndex); + + void _getDistances( std::vector<Vector3> &set1, + std::vector<Vector3> &set2, + double &minDistance, + double &maxDistance, + double &averageDistance, + double &stdDevDistance, + Vector3 &minPoint1, + Vector3 &minPoint2, + Vector3 &maxPoint1, + Vector3 &maxPoint2); + ML_BASEOP_CLASS_HEADER(CSODistance); }; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rha...@us...> - 2011-09-26 13:41:40
|
Revision: 383 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=383&view=rev Author: rhameeteman Date: 2011-09-26 13:41:31 +0000 (Mon, 26 Sep 2011) Log Message: ----------- KH. * Added abs min mean and max Modified Paths: -------------- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.cpp trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.h Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.cpp =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.cpp 2011-09-26 13:40:49 UTC (rev 382) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.cpp 2011-09-26 13:41:31 UTC (rev 383) @@ -111,7 +111,7 @@ f_UseVoxelSize->setBoolValue( true ); f_Statistics = fieldC->addString("statistics"); - f_Statistics->setStringValue( "Id;Voxels;Sum;Average" ); + f_Statistics->setStringValue( "Id;Voxels;Sum;Average;Min;Max;AbsAverage;AbsMin;AbsMax" ); f_TotalSum = fieldC->addDouble( "totalSum" ); f_TotalSum->setDoubleValue( 0.0 ); @@ -324,7 +324,7 @@ f_Statistics->setStringValue( "" ); std::stringstream outputString; - outputString << "Id;Voxels;Sum;Average;Min;Max" << std::endl; + outputString << "Id;Voxels;Sum;Average;Min;Max;AbsAverage;Absmin;AbsMax" << std::endl; m_SumSeries.clear(); m_AverageSeries.clear(); @@ -352,12 +352,15 @@ CSO* currentCSO = m_OutCSOList->getCSOById(currentId); if ( !currentCSO->isClosed() ){ continue; } double sum = 0.0; - double average = 0.0; + double mean = 0.0; + double absMean = 0.0; double minimum = ML_DOUBLE_MAX; + double absMin = ML_DOUBLE_MAX; double maximum = -ML_DOUBLE_MAX; + double absMax = 0.0; unsigned int iD = currentCSO->getId(); size_t voxelCount; - this->GetStatistics( currentCSO, voxelCount, sum, average, minimum, maximum ); + this->GetStatistics( currentCSO, voxelCount, sum, mean, absMean, minimum, absMin, maximum, absMax ); totalSum += sum; double currentArea = 0.0; @@ -366,15 +369,23 @@ } else { currentArea = currentCSO->getLength(); } - totalAverage += average*currentArea; + totalAverage += mean*currentArea; totalArea += currentArea; totalMin = ML_MIN(totalMin,minimum); totalMax = ML_MAX(totalMax,maximum); - outputString << iD << ";" << voxelCount << ";" << sum << ";" << average << ";" << minimum << ";" << maximum << std::endl; + outputString << iD << ";" + << voxelCount << ";" + << sum << ";" + << mean << ";" + << minimum << ";" + << maximum << ";" + << absMean << ";" + << absMin << ";" + << absMax << std::endl; m_SumSeries.push_back( sum ); - m_AverageSeries.push_back( average ); + m_AverageSeries.push_back( mean ); if ( f_AddDescription->getBoolValue() ) { std::string descriptionString = f_DescriptionString->getStringValue(); @@ -382,7 +393,7 @@ ss << sum; descriptionString = ReplaceString(descriptionString, "%sum", ss.str() ); ss.str(""); - ss << average; + ss << mean; descriptionString = ReplaceString(descriptionString, "%average", ss.str() ); ss.str(""); currentCSO->setDescription( descriptionString ); @@ -421,9 +432,12 @@ void CSOImageStatistics::GetStatistics( CSO* cso, size_t &voxelCount, double &sum, - double &average, + double &mean, + double &absMean, double &minimum, - double &maximum ) + double &absMin, + double &maximum, + double &absMax) { if ( cso && getNonDummyUpdatedInImg(0) && cso->isInPlane() ){ @@ -444,7 +458,7 @@ // Set FoV const double size = maPCA.getLargestExtension(); FloatField* fOVField = static_cast< FloatField* >( MLModuleGetField (mpr, "fieldOfView") ); - fOVField->setFloatValue( size ); + fOVField->setFloatValue( static_cast< float>(size) ); // Set output size const float resolution = f_Resolution->getFloatValue(); @@ -508,10 +522,14 @@ SubImgBox csoVoxelBox = SubImgBox( Vector(0), Vector(nx-1,ny-1,nz-1,nc-1,nt-1,nu-1) ); sum = 0.0; - average = 0.0; + double absSum = 0.0; + mean = 0.0; + absMean = 0.0; voxelCount = 0; minimum = ML_DOUBLE_MAX; + absMin = ML_DOUBLE_MAX; maximum = -ML_DOUBLE_MAX; + absMax = 0.0; // Remove data on error to avoid memory leaks. if (inputTile ) { @@ -546,7 +564,7 @@ static_cast< MLint >(contourPoints[iPos][1]), static_cast< MLint >(contourPoints[iPos][2]),0,0,0 ); float x,y,z; - MLImageMapVoxelToWorld(mprOutput, currentPos[0]+0.5,currentPos[1]+0.5,currentPos[2]+0.5,&x,&y,&z); + MLImageMapVoxelToWorld(mprOutput, currentPos[0]+0.5f,currentPos[1]+0.5f,currentPos[2]+0.5f,&x,&y,&z); XMarker currentMarker( vec3(x,y,z) ); currentMarker.type = currentCSOIndex; m_OutMarkerList->push_back( currentMarker ); @@ -555,15 +573,20 @@ const MLint offset = currentPos.dot( strideVector ); double* currentValue = inputTile+offset; sum += *currentValue; + absSum += abs(*currentValue); minimum = ML_MIN(minimum, *currentValue ); + absMin = ML_MIN(minimum, abs(*currentValue) ); maximum = ML_MAX(maximum, *currentValue ); + absMax = ML_MAX(maximum, abs(*currentValue) ); } const double csoArea = ( f_UseAllPointsInsideCSO->getBoolValue() ? cso->getArea():cso->getLength() ); if ( f_UseVoxelSize->getBoolValue() ){ - average = (csoArea == 0 ? 0: sum/csoArea); + mean = (csoArea == 0 ? 0: sum/csoArea); + absMean = (csoArea == 0 ? 0: absSum/csoArea); } else { - average = (voxelCount == 0 ? 0 : sum/voxelCount); + mean = (voxelCount == 0 ? 0 : sum/voxelCount); + absMean = (voxelCount == 0 ? 0 : absSum/voxelCount); } } freeTile( inputTile ); @@ -602,7 +625,11 @@ std::vector< vec3 >::iterator it = coordinateList.begin(); for (;it != coordinateList.end(); ++ it ) { float x1,y1,z1; - MLImageMapWorldToVoxel(image, (*it)[0], (*it)[1],(*it)[2], &x1,&y1,&z1); + MLImageMapWorldToVoxel( image, + static_cast<float>( (*it)[0] ), + static_cast<float>( (*it)[1] ), + static_cast<float>( (*it)[2] ), + &x1,&y1,&z1 ); *it = vec3(x1,y1,z1); } } Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.h =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.h 2011-09-26 13:40:49 UTC (rev 382) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOImageStatistics/mlCSOImageStatistics.h 2011-09-26 13:41:31 UTC (rev 383) @@ -107,9 +107,12 @@ void GetStatistics( CSO *cso, size_t &voxelCount, double &sum, - double &average, + double &mean, + double &absMean, double &minimum, - double &maximum); + double &absMin, + double &maximum, + double &absMax); //! Get a list of all points inside the contour defined by the pathPoints //! The contour should be axis aligned @@ -215,10 +218,10 @@ CurveList *m_OutCurveList; //! The CurveData for the average - std::vector< float > m_AverageSeries; + std::vector< double > m_AverageSeries; //! The CurveData for the sum - std::vector< float > m_SumSeries; + std::vector< double > m_SumSeries; //! Output a MarkerList containing all positions that are used to calculate the statistics //! The type of each marker is set to the corresponding CSO Id This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rha...@us...> - 2011-09-26 13:40:55
|
Revision: 382 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=382&view=rev Author: rhameeteman Date: 2011-09-26 13:40:49 +0000 (Mon, 26 Sep 2011) Log Message: ----------- KH. * fixed small bug with max x value Modified Paths: -------------- trunk/Community/General/Sources/ML/MLCMCurveList/CMCurveFilter/mlCMCurveFilter.cpp trunk/Community/General/Sources/ML/MLCMCurveList/CMCurveFilter/mlCMCurveFilter.h Modified: trunk/Community/General/Sources/ML/MLCMCurveList/CMCurveFilter/mlCMCurveFilter.cpp =================================================================== --- trunk/Community/General/Sources/ML/MLCMCurveList/CMCurveFilter/mlCMCurveFilter.cpp 2011-09-26 13:39:34 UTC (rev 381) +++ trunk/Community/General/Sources/ML/MLCMCurveList/CMCurveFilter/mlCMCurveFilter.cpp 2011-09-26 13:40:49 UTC (rev 382) @@ -129,11 +129,11 @@ if ( f_AutoUpdate->getBoolValue() ){ SetMaxValues(); SetOutputCurve(); - f_OutCurveList->notifyAttachments(); + f_OutCurveList->touch(); } } else { ResetOutput(); - f_OutCurveList->notifyAttachments(); + f_OutCurveList->touch(); } } else @@ -149,8 +149,9 @@ ))){ if ( m_InCurveList != NULL ){ if ( m_InCurveList->getNumCurves() > 0 ){ + SetMaxValues(); SetOutputCurve(); - f_OutCurveList->notifyAttachments(); + f_OutCurveList->touch(); } } } @@ -168,12 +169,12 @@ void CMCurveFilter::SetMaxValues() { - int nCurveSets = 0; - int nCurves = 0; + MLssize_t nCurveSets = 0; + MLssize_t nCurves = 0; if ( m_InCurveList != NULL ){ nCurveSets = m_InCurveList->getNumCurves(); for (int iSet = 0; iSet < nCurveSets; ++iSet ) { - nCurves = mlMax( static_cast<MLssize_t>(nCurves), m_InCurveList->getCurveData( iSet )->getNumSeries() ); + nCurves = mlMax( nCurves, m_InCurveList->getCurveData( iSet )->getNumSeries() ); } } f_NumberOfCurveSets->setIntValue( nCurveSets-1 ); @@ -187,33 +188,34 @@ // Check for valid field values // Curves are numbered from 0 - int nCurveSets = m_InCurveList->getNumCurves(); + size_t nCurveSets = m_InCurveList->getNumCurves(); if ( nCurveSets == 0 ) {return;} - int minSet = mlMax( static_cast<MLint>(0), f_MinCurveSet->getIntValue() ); - int maxSet = mlMax( static_cast<MLint>(minSet), f_MaxCurveSet->getIntValue() ); + size_t minSet = mlMax( static_cast<size_t>(0), static_cast<size_t>(f_MinCurveSet->getIntValue() ) ); + size_t maxSet = mlMax( minSet, static_cast<size_t>( f_MaxCurveSet->getIntValue() ) ); maxSet = mlMin( maxSet, nCurveSets-1 ); - for (int iSet = minSet; iSet <= maxSet; ++iSet ) { + for (size_t iSet = minSet; iSet <= maxSet; ++iSet ) { - int nCurves = m_InCurveList->getCurveData( iSet )->getNumSeries(); + size_t nCurves = m_InCurveList->getCurveData( iSet )->getNumSeries(); if (nCurves == 0 ) {continue;} - int minCurve = mlMax(static_cast<MLint>(0),f_MinCurve->getIntValue() ); - int maxCurve = mlMax(static_cast<MLint>(minCurve), f_MaxCurve->getIntValue() ); + size_t minCurve = mlMax(static_cast<size_t>(0), static_cast<size_t>(f_MinCurve->getIntValue()) ); + size_t maxCurve = mlMax(minCurve, static_cast<size_t>(f_MaxCurve->getIntValue()) ); maxCurve = mlMin(maxCurve, nCurves-1 ); - for (int iCurve = minCurve; iCurve <= maxCurve; ++iCurve ) { + for (size_t iCurve = minCurve; iCurve <= maxCurve; ++iCurve ) { CurveData *curveSet = m_InCurveList->getCurveData( iSet ); CurveData *outputCurve = new CurveData( *curveSet ); outputCurve->clearData(); - std::vector< float > xSeries; - std::vector< float > ySeries; + std::vector< double > xSeries; + std::vector< double > ySeries; // Copy/Crop curve values - bool crop = f_CropCurve->getBoolValue(); - float minX = f_XStart->getFloatValue(); - float maxX = f_XEnd->getFloatValue(); - minX = mlMin(minX,maxX); - for (int iX = 0; iX < curveSet->getPoints(); ++iX ){ - float xValue = curveSet->getXValue( iX ); + const bool crop = f_CropCurve->getBoolValue(); + const double maxX = ( f_XEnd->getFloatValue() < 0 ? + curveSet->getXValue( curveSet->getPoints()-1 ) - f_XEnd->getFloatValue() : + f_XEnd->getFloatValue() ); + const double minX = (f_XStart->getFloatValue() < maxX ? f_XStart->getFloatValue(): maxX) ; + for (MLssize_t iX = 0; iX < curveSet->getPoints(); ++iX ){ + const double xValue = curveSet->getXValue( iX ); if ( !crop || ( (minX<=xValue) && (xValue <= maxX)) ) { ySeries.push_back( curveSet->getYValue( minCurve, iX) ); xSeries.push_back( xValue ); Modified: trunk/Community/General/Sources/ML/MLCMCurveList/CMCurveFilter/mlCMCurveFilter.h =================================================================== --- trunk/Community/General/Sources/ML/MLCMCurveList/CMCurveFilter/mlCMCurveFilter.h 2011-09-26 13:39:34 UTC (rev 381) +++ trunk/Community/General/Sources/ML/MLCMCurveList/CMCurveFilter/mlCMCurveFilter.h 2011-09-26 13:40:49 UTC (rev 382) @@ -112,6 +112,7 @@ BoolField *f_CropCurve; FloatField *f_XStart; FloatField *f_XEnd; + BoolField *f_XEndMax; }; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rha...@us...> - 2011-09-26 13:39:43
|
Revision: 381 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=381&view=rev Author: rhameeteman Date: 2011-09-26 13:39:34 +0000 (Mon, 26 Sep 2011) Log Message: ----------- KH. * fixed typo Modified Paths: -------------- trunk/Community/General/Modules/Macros/Fields/CompareModules.def Modified: trunk/Community/General/Modules/Macros/Fields/CompareModules.def =================================================================== --- trunk/Community/General/Modules/Macros/Fields/CompareModules.def 2011-09-26 13:39:09 UTC (rev 380) +++ trunk/Community/General/Modules/Macros/Fields/CompareModules.def 2011-09-26 13:39:34 UTC (rev 381) @@ -12,7 +12,7 @@ author = "Reinhard Hameeteman" status = "work-in-progress" comment = "Compare the field values of two modules" - keywords = "compara parameters interface fields values" + keywords = "compare parameters interface fields values" seeAlso = "" externalDefinition = "$(LOCAL)/CompareModules.script" documentation = "$(LOCAL)/html/CompareModules.html" This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <rha...@us...> - 2011-09-26 13:39:16
|
Revision: 380 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=380&view=rev Author: rhameeteman Date: 2011-09-26 13:39:09 +0000 (Mon, 26 Sep 2011) Log Message: ----------- KH. * Set code editor style to monospacedTextView Modified Paths: -------------- trunk/Community/General/Modules/Macros/Command/PythonExec.script Modified: trunk/Community/General/Modules/Macros/Command/PythonExec.script =================================================================== --- trunk/Community/General/Modules/Macros/Command/PythonExec.script 2011-09-09 08:04:06 UTC (rev 379) +++ trunk/Community/General/Modules/Macros/Command/PythonExec.script 2011-09-26 13:39:09 UTC (rev 380) @@ -78,12 +78,17 @@ frameShape = NoFrame frameShadow = Plain TextView command { - autoApply = Yes - title = "" + autoApply = Yes + title = "" droppedObjectCommand = FieldDroped - syntaxHighlighting = Python - showLineNumbers = Yes - hscroller = On + syntaxHighlighting = Python + showLineNumbers = Yes + hscroller = On + wrap = off + tabStopWidth = 20 + console = yes + style = monospacedTextView + textFormat = Plain tooltip = "Drop any field on this window and it will be added as nw.field(<fieldName>).value Trigger fields are added as nw.field(<fieldName>).touch() This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |