本文整理汇总了C++中ML_TRACE_IN函数的典型用法代码示例。如果您正苦于以下问题:C++ ML_TRACE_IN函数的具体用法?C++ ML_TRACE_IN怎么用?C++ ML_TRACE_IN使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了ML_TRACE_IN函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: ML_TRACE_IN
//----------------------------------------------------------------------------------
//! Handle field changes of the field field.
//----------------------------------------------------------------------------------
void FuzzyConnectedness::handleNotification (Field *field)
{
ML_TRACE_IN("FuzzyConnectedness::handleNotification ()");
// Calculation will only be performed if either the start
// button is pressed or the auto update mechanism is used.
if ((field ==_startButtonFld) || ((field != _startButtonFld) && _autoUpdateFld->isOn()))
{
_state = ML_RESULT_OK;
//If either input image is open the calculation will be cancelled.
if(!getUpdatedInImg(0) || !getUpdatedInImg(1))
{
_state = ML_DISCONNECTED_GRAPH;
clearData();
getOutImg(0)->setOutOfDate();
getOutImg(1)->setOutOfDate();
getOutField(0)->notifyAttachments();
getOutField(1)->notifyAttachments();
}
else
{
// Same extent of image data and seed point image are required
if ( getUpdatedInImg(0)->getImgExt() != getUpdatedInImg(1)->getImgExt() )
{
_state=ML_BAD_DIMENSION;
}
// Calculation will be started here
else{
_state = calculate(getUpdatedInImg(0),getUpdatedInImg(1));
}
}
// Let the connected modules know that the output has changed.
getOutField(0)->notifyAttachments();
getOutField(1)->notifyAttachments();
}
}
示例2: ML_TRACE_IN
//! Modify item at position \a index. If \a fromCurrentItem is true, the
//! item is copied from _currentItem, otherwise the item property corresponding
//! to the property field \a field is modified.
//! Return true if item has been modified.
bool ColoredMarkerListContainer::modifyItem(MLssize_t index, Field *field, bool fromCurrentItem)
{
ML_TRACE_IN("bool ColoredMarkerListContainer::modifyItem(MLssize_t index, Field *field, bool fromCurrentItem)");
ML_TRY{
bool modified = true;
ColoredMarker *marker=NULL;
// Valid list and item?
if (_listPtr && (index >= 0) && (index < mlrange_cast<MLssize_t>(_listPtr->getSize())) )
{
// Modify from property field?
if (!fromCurrentItem)
{
// Pointer to list item
marker = &(*_listPtr)[mlrange_cast<size_t>(index)];
// Position fields
if ((field == _fldPos3D) || (field == _fldPosC) || (field == _fldPosT) || (field == _fldPosU))
{
marker->pos = Vector6(_fldPos3D->getVector3Value(),0,0,0);
marker->c() = _fldPosC->getFloatValue();
marker->t() = _fldPosT->getFloatValue();
marker->u() = _fldPosU->getFloatValue();
}
else if (field == _fldColor || (field == _fldAlpha))
{
// ImageVector field
marker->rgba() = Vector4(_fldColor->getVector3Value(),_fldAlpha->getFloatValue());
}
else if (field == _fldType)
{
// Type field
marker->type = _fldType->getIntValue();
}
else
{
// Not an ColoredMarker-specific field, pass call to base class
modified = ListContainerTemplate<ColoredMarkerList>::modifyItem(index, field, fromCurrentItem);
}
}
else
{
// Modify from _currentItem, handled in base class
modified = ListContainerTemplate<ColoredMarkerList>::modifyItem(index, field, fromCurrentItem);
}
} else
{
modified = false;
}
return modified;
}
ML_CATCH_RETHROW;
}
示例3: ML_TRACE_IN
//----------------------------------------------------------------------------------
//! Handle notifications of CSOList
//----------------------------------------------------------------------------------
void CSOPointsToXMarkers::CSOListNotifyObserverCB(void* userData, int /*notificationFlag*/)
{
ML_TRACE_IN("CSOPointsToXMarkers::_csoListNotifyObserverCB");
CSOPointsToXMarkers * thisPointer = static_cast<CSOPointsToXMarkers*>(userData);
thisPointer->convertCSOToXMarkerList();
}
示例4: ML_TRACE_IN
void ListModifyProperties::activateAttachments() {
ML_TRACE_IN("void ListModifyProperties::activateAttachments()");
Engine::activateAttachments();
_autoUpdateModeFld->touch();
}
示例5: WEMInspector
//----------------------------------------------------------------------------------
//! Constructor
//----------------------------------------------------------------------------------
WEMVolume::WEMVolume (std::string type)
: WEMInspector(type)
{
ML_TRACE_IN("WEMVolume::WEMVolume()")
FieldContainer *fields = getFieldContainer();
ML_CHECK(fields);
// Suppress calls of handleNotification on field changes.
handleNotificationOff();
// Add min, max volume, and corresponding index fields
_minVolumeFld = fields->addFloat("minVolume");
_minVolumeFld->setFloatValue(0.0f);
_maxVolumeFld = fields->addFloat("maxVolume");
_maxVolumeFld->setFloatValue(0.0f);
_minVolumeIndexFld = fields->addInt("minVolumePatchIndex");
_minVolumeIndexFld->setIntValue(0);
_maxVolumeIndexFld = fields->addInt("maxVolumePatchIndex");
_maxVolumeIndexFld->setIntValue(0);
// Add output curve field
_outputVolumeCurveFld = fields->addBase("outputVolumeCurve");
_outputVolumeCurveFld->setBaseValue(&_outputVolumeCurve);
// Reactivate calls of handleNotification on field changes.
handleNotificationOn();
}
示例6: ML_TRACE_IN
//----------------------------------------------------------------------------------
//! Handle field changes of the field \c field.
//----------------------------------------------------------------------------------
void WEMVolume::handleNotification (Field *field)
{
ML_TRACE_IN("WEMVolume::handleNotification()")
// call parent class and handle apply/autoApply and in/outputs
WEMInspector::handleNotification(field);
}
示例7: ML_TRACE_IN
void CSODistance::_csoListNotificationCB(void* userData, int notificationFlag)
{
ML_TRACE_IN("void CSODistance::_csoListNotificationCB()");
CSODistance* thisp = static_cast<CSODistance*>(userData);
thisp->_isInNotificationCB = true;
bool autoApply = thisp->_autoApplyFld->getBoolValue();
if ((notificationFlag & CSOList::NOTIFICATION_CSO_SELECTION) ||
(notificationFlag & CSOList::NOTIFICATION_GROUP_SELECTION))
{
if (thisp->_listenToSelectionChangedNotificationsFld->getBoolValue()){
if (autoApply) { thisp->_process(); }
}
}
if ((notificationFlag & CSOList::NOTIFICATION_CSO_FINISHED) ||
(notificationFlag & CSOList::NOTIFICATION_GROUP_FINISHED))
{
if (thisp->_listenToFinishingNotificationsFld->getBoolValue()){
if (autoApply) { thisp->_process(); }
}
}
if (notificationFlag & CSOList::NOTIFICATION_REPAINT){
if (thisp->_listenToRepaintNotificationsFld->getBoolValue()){
if (autoApply) { thisp->_process(); }
}
}
if (notificationFlag & CSOList::NOTIFICATION_INTERACTION_INIT){
// do nothing
}
thisp->_isInNotificationCB = false;
}
示例8: BaseOp
//----------------------------------------------------------------------------------
//! Constructor
//----------------------------------------------------------------------------------
StringToCurve::StringToCurve () : BaseOp(0, 0)
{
ML_TRACE_IN("StringToCurve::StringToCurve ()")
handleNotificationOff();
FieldContainer *fieldC = getFieldContainer();
m_OutCurveList = new CurveList;
f_OutCurveList = fieldC->addBase( "outCurveList" );
f_OutCurveList->setBaseValue( m_OutCurveList );
f_CurveString = fieldC->addString("curveString");
f_CurveString->setStringValue("");
f_IndexString = fieldC->addString("indexString");
f_IndexString->setStringValue("");
f_ValueSeparator = fieldC->addString("valueSeparator");
f_ValueSeparator->setStringValue(" ");
f_CurveSeparator = fieldC->addString( "curveSeparator" );
f_CurveSeparator->setStringValue(";");
handleNotificationOn();
}
示例9: ML_TRACE_IN
//----------------------------------------------------------------------------------
//! Handle field changes of the field field.
//----------------------------------------------------------------------------------
void StringToCurve::handleNotification (Field * /*field*/)
{
ML_TRACE_IN("StringToCurve::handleNotification ()");
UpdateCurve();
f_OutCurveList->notifyAttachments();
}
示例10: WEMProcessor
//----------------------------------------------------------------------------------
//! Constructor
//----------------------------------------------------------------------------------
WEMCMSelectPatches::WEMCMSelectPatches (std::string type)
: WEMProcessor(type, false)
{
ML_TRACE_IN("WEMCMSelectPatches::WEMCMSelectPatches()")
FieldContainer *fields = getFieldContainer();
ML_CHECK(fields);
// Suppress calls of hanbdleNotification on field changes.
handleNotificationOff();
// WEM Patch start and end index field
_patchStartIndexFld = fields->addInt("patchStartIndex");
_patchStartIndexFld->setIntValue(0);
_patchEndIndexFld = fields->addInt("patchEndIndex");
_patchEndIndexFld->setIntValue(0);
// Bool field to enable to select only one patch based on start index value
_onePatchFld = fields->addBool("onePatch");
_onePatchFld->setBoolValue(false);
// Set auto apply fields
_autoApplyFld->setBoolValue(true);
_notifyFld = fields->addNotify("notify");
// Reactivate calls of handleNotification on field changes.
handleNotificationOn();
}
示例11: MLBaseListExtensionsInit
ML_START_NAMESPACE
// Initialization of the run type system
int MLBaseListExtensionsInit()
{
ML_TRACE_IN("MLBaseListExtensionsInit()")
IndexPair ::initClass();
IndexPairList ::initClass();
IndexPairListContainer ::initClass();
ColoredMarker ::initClass();
ColoredMarkerList ::initClass();
ColoredMarkerListContainer ::initClass();
XMarkerToColoredMarker ::initClass();
ColoredMarkerToXMarker ::initClass();
ListInfo ::initClass();
ListFilter ::initClass();
ListModifyProperties ::initClass();
MarkerListImport ::initClass();
return 1;
}
示例12: BaseOp
//----------------------------------------------------------------------------------
//! Constructor
//----------------------------------------------------------------------------------
CalcCodedSegmentation::CalcCodedSegmentation (void) : BaseOp(1, 1)
{
ML_TRACE_IN("CalcCodedSegmentation::CalcCodedSegmentation()")
FieldContainer *fields = getFieldContainer();
// Suppress calls of handleNotification on field changes.
handleNotificationOff();
MAX_SIZE = SHRT_MAX; //32767
_fld_Add = fields->addNotify("Add");
(_fld_NameToAdd = fields->addString("NameToAdd"))->setStringValue("");
(_fld_addMinValue = fields->addInt("addMinValue"))->setIntValue(1);
(_fld_addMaxValue = fields->addInt("addMaxValue"))->setIntValue(ML_INT_MAX);
(_fld_addAllExceptNull = fields->addBool("addAllExceptNull"))->setBoolValue(false);
_fld_Reset = fields->addNotify("Reset");
_fld_Purge = fields->addNotify("Purge");
_fld_Finish = fields->addNotify("Finish");
(_fld_ImageValues = fields->addString("ImageValues"))->setStringValue("");
(_fld_ObjectValues = fields->addString("ObjectValues"))->setStringValue("");
//All pointer values need to be set NULL here, before reset, otherwise, default random values of pointe can be interpreted as real values and a non existing pointer is tried to delete ... uuhhhh
_virtualVolume = NULL;
replaceValues = NULL;
objectValues = NULL;
valuesForObjects = NULL;
objectNames = NULL;
reset();
// Reactivate calls of handleNotification on field changes.
handleNotificationOn();
}
示例13: WEMInspector
//----------------------------------------------------------------------------------
//! Constructor
//----------------------------------------------------------------------------------
WEMNodesToFile::WEMNodesToFile (std::string type)
: WEMInspector(type)
{
ML_TRACE_IN("WEMNodesToFile::WEMNodesToFile()")
FieldContainer *fields = getFieldContainer();
ML_CHECK(fields);
// Suppress calls of handleNotification on field changes.
handleNotificationOff();
// Add filename field
_filenameFld = fields->addString("filename");
_filenameFld->setStringValue("");
// Add transformix option field
_transformixCompatibleFld = fields->addBool("transformixCompatible");
_transformixCompatibleFld->setBoolValue(false);
// Add save button
_saveFld = fields->addNotify("save");
// Reactivate calls of handleNotification on field changes.
handleNotificationOn();
}
示例14: ML_TRACE_IN
//----------------------------------------------------------------------------------
//! Code below is performed after module and network initialization.
//----------------------------------------------------------------------------------
void WEMCenterOfMass::activateAttachments()
{
ML_TRACE_IN("WEMCenterOfMass::activateAttachments()")
// call parent class
WEMInspector::activateAttachments();
}
示例15: ML_TRACE_IN
void MainAxisPCA::getInverseMatrix(float **aMatrix, float **invMatrix)
{
ML_TRACE_IN("void MainAxisPCA::getInverseMatrix(float **aMatrix, float **invMatrix) ");
// Compute inverse matrix (only for 3x3 matrices)
// calculate determinant D and multiply the result with 1/D
float det = aMatrix[1][1] * aMatrix[2][2] * aMatrix[3][3]
+ aMatrix[1][2] * aMatrix[2][3] * aMatrix[3][1]
+ aMatrix[1][3] * aMatrix[2][1] * aMatrix[3][2]
- aMatrix[1][3] * aMatrix[2][2] * aMatrix[3][1]
- aMatrix[1][1] * aMatrix[2][3] * aMatrix[3][2]
- aMatrix[1][2] * aMatrix[2][1] * aMatrix[3][3];
if (det != 0){ det = 1.0f/det; }
// Compute adjacent matrix, transpose it and multiply with D
invMatrix[1][1] = det * (aMatrix[2][2] * aMatrix[3][3] - aMatrix[2][3] * aMatrix[3][2]);
invMatrix[2][1] = -det * (aMatrix[2][1] * aMatrix[3][3] - aMatrix[2][3] * aMatrix[3][1]);
invMatrix[3][1] = det * (aMatrix[2][1] * aMatrix[3][2] - aMatrix[2][2] * aMatrix[3][1]);
invMatrix[1][2] = -det * (aMatrix[1][2] * aMatrix[3][3] - aMatrix[1][3] * aMatrix[3][2]);
invMatrix[2][2] = det * (aMatrix[1][1] * aMatrix[3][3] - aMatrix[1][3] * aMatrix[3][1]);
invMatrix[3][2] = -det * (aMatrix[1][1] * aMatrix[3][2] - aMatrix[1][2] * aMatrix[3][1]);
invMatrix[1][3] = det * (aMatrix[1][2] * aMatrix[2][3] - aMatrix[1][3] * aMatrix[2][2]);
invMatrix[2][3] = -det * (aMatrix[1][1] * aMatrix[2][3] - aMatrix[1][3] * aMatrix[2][1]);
invMatrix[3][3] = det * (aMatrix[1][1] * aMatrix[2][2] - aMatrix[1][2] * aMatrix[2][1]);
}