From: <coe...@us...> - 2010-09-07 07:45:17
|
Revision: 329 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=329&view=rev Author: coertmetz Date: 2010-09-07 07:45:10 +0000 (Tue, 07 Sep 2010) Log Message: ----------- CM: Added export of time point number. Modified Paths: -------------- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOPointsToXMarkers/mlCSOPointsToXMarkers.cpp Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOPointsToXMarkers/mlCSOPointsToXMarkers.cpp =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOPointsToXMarkers/mlCSOPointsToXMarkers.cpp 2010-08-20 11:15:46 UTC (rev 328) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOPointsToXMarkers/mlCSOPointsToXMarkers.cpp 2010-09-07 07:45:10 UTC (rev 329) @@ -176,6 +176,8 @@ if (outputPathPoints) { std::list<vec3> points; + // Get time point + const int timepoint = cso->getTimePointIndex(); // First collect all pathpoints for (unsigned int i=0; i<cso->numPathPointLists(); ++i) { CSOPathPoints* pathList=cso->getPathPointsAt(i); @@ -192,6 +194,7 @@ // Create marker XMarker markerPath(*it); markerPath.type = j; + markerPath.pos[ 4 ] = timepoint; // Compute normal if (outputNormals && inPlane) { // Determine prev and next it @@ -231,12 +234,14 @@ // Add marker to output list _outputXMarkerList.appendItem(markerPath); } - } else{ + } else { for (unsigned int i=0; i<cso->numSeedPoints(); ++i) { CSOSeedPoint * seedpoint = cso->getSeedPointAt(i); + const int timepoint = cso->getTimePointIndex(); vec3 pos = seedpoint->worldPosition; XMarker marker (pos); marker.type = j; + marker.pos[ 4 ] = timepoint; if (inPlane && outputNormals) { // Determine previous and next marker This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <coe...@us...> - 2012-08-31 12:06:04
|
Revision: 416 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=416&view=rev Author: coertmetz Date: 2012-08-31 12:05:53 +0000 (Fri, 31 Aug 2012) Log Message: ----------- CM: Improved notification handling. Modified Paths: -------------- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOPointsToXMarkers/mlCSOPointsToXMarkers.cpp Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOPointsToXMarkers/mlCSOPointsToXMarkers.cpp =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOPointsToXMarkers/mlCSOPointsToXMarkers.cpp 2012-08-31 12:04:49 UTC (rev 415) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOPointsToXMarkers/mlCSOPointsToXMarkers.cpp 2012-08-31 12:05:53 UTC (rev 416) @@ -90,6 +90,7 @@ { if (_inputCSOList != NULL) { _inputCSOList->removeNotificationObserver(CSOListNotifyObserverCB, this); + _inputCSOList=NULL; } } @@ -114,11 +115,13 @@ // Get CSO list if changed if (field==_inputCSOListFld) { - if (_inputCSOList!=NULL) { + CSOList::removeNotificationObserverFromAllCSOLists(CSOListNotifyObserverCB, this); + + //if (_inputCSOList!=NULL) { // Remove old notification observer - _inputCSOList->removeNotificationObserver(CSOListNotifyObserverCB, this); - _inputCSOList=NULL; - } + // _inputCSOList->removeNotificationObserver(CSOListNotifyObserverCB, this); + _inputCSOList=NULL; + //} // Get input CSO list Base *baseValue = _inputCSOListFld->getBaseValue(); @@ -127,9 +130,13 @@ // Add new notification observer _inputCSOList->addNotificationObserver(CSOListNotifyObserverCB, this); } + + convertCSOToXMarkerList(); + } + else if (field==_convertPathPoints || field==_listIndexFld || field==_outputCSONormals) + { + convertCSOToXMarkerList(); } - - convertCSOToXMarkerList(); } //---------------------------------------------------------------------------------- @@ -154,6 +161,9 @@ } else { + // Disable output notifications + _outputXMarkerListFld->setBaseValue(NULL); + // If listIndex = -1, all CSOs in the list are exported; // determine start index and number of CSOs to export. int numOfLoops; @@ -281,8 +291,9 @@ } // Notify attached modules - _outputXMarkerListFld->notifyAttachments(); + //_outputXMarkerListFld->notifyAttachments(); } + _outputXMarkerListFld->setBaseValue(&_outputXMarkerList); } } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <coe...@us...> - 2012-10-16 08:37:43
|
Revision: 427 http://mevislabmodules.svn.sourceforge.net/mevislabmodules/?rev=427&view=rev Author: coertmetz Date: 2012-10-16 08:37:32 +0000 (Tue, 16 Oct 2012) Log Message: ----------- CM: Fixed a bug causing a crash with empty CSO lists. Modified Paths: -------------- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOPointsToXMarkers/mlCSOPointsToXMarkers.cpp Modified: trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOPointsToXMarkers/mlCSOPointsToXMarkers.cpp =================================================================== --- trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOPointsToXMarkers/mlCSOPointsToXMarkers.cpp 2012-09-27 09:33:59 UTC (rev 426) +++ trunk/Community/General/Sources/ML/MLCSOCommunityModules/CSOPointsToXMarkers/mlCSOPointsToXMarkers.cpp 2012-10-16 08:37:32 UTC (rev 427) @@ -195,7 +195,7 @@ for (unsigned int k=0; k<numOfPathPoints; k++) { vec3 posPathPoint = pathList->getPosAt(k); - if (points.back()!=posPathPoint) points.push_back(posPathPoint); + if (points.size() == 0 || points.back()!=posPathPoint) points.push_back(posPathPoint); } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |