本文整理汇总了Python中EditUtil.EditUtil.getSliceLogic方法的典型用法代码示例。如果您正苦于以下问题:Python EditUtil.getSliceLogic方法的具体用法?Python EditUtil.getSliceLogic怎么用?Python EditUtil.getSliceLogic使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类EditUtil.EditUtil
的用法示例。
在下文中一共展示了EditUtil.getSliceLogic方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: onApply
# 需要导入模块: from EditUtil import EditUtil [as 别名]
# 或者: from EditUtil.EditUtil import getSliceLogic [as 别名]
def onApply(self):
logic = WatershedFromMarkerEffectLogic( EditUtil.getSliceLogic() )
logic.undoRedo = self.undoRedo
logic.sigma = float( self.sigmaSpinBox.value )
logic.doit()
示例2: changeLabel
# 需要导入模块: from EditUtil import EditUtil [as 别名]
# 或者: from EditUtil.EditUtil import getSliceLogic [as 别名]
def changeLabel(self):
#
# change the label values based on the parameter node
#
if not self.sliceLogic:
self.sliceLogic = EditUtil.getSliceLogic()
parameterNode = EditUtil.getParameterNode()
parameterNode = EditUtil.getParameterNode()
inputColor = int(parameterNode.GetParameter("ChangeLabelEffect,inputColor"))
outputColor = int(parameterNode.GetParameter("ChangeLabelEffect,outputColor"))
change = slicer.vtkImageLabelChange()
if vtk.VTK_MAJOR_VERSION <= 5:
change.SetInput( self.getScopedLabelInput() )
else:
change.SetInputData( self.getScopedLabelInput() )
change.SetOutput( self.getScopedLabelOutput() )
change.SetInputLabel( inputColor )
change.SetOutputLabel( outputColor )
# TODO
#$this setProgressFilter $change "Change Label"
change.Update()
self.applyScopedLabel()
change.SetOutput( None )
示例3: __init__
# 需要导入模块: from EditUtil import EditUtil [as 别名]
# 或者: from EditUtil.EditUtil import getSliceLogic [as 别名]
def __init__(self, parent=0):
super(FastMarchingEffectOptions,self).__init__(parent)
# self.attributes should be tuple of options:
# 'MouseTool' - grabs the cursor
# 'Nonmodal' - can be applied while another is active
# 'Disabled' - not available
# self.attributes = ('MouseTool')
self.displayName = 'FastMarchingEffect Effect'
self.logic = FastMarchingEffectLogic(EditUtil.getSliceLogic())