本文整理汇总了Python中director.consoleapp.ConsoleApp.getTestingInteractiveEnabled方法的典型用法代码示例。如果您正苦于以下问题:Python ConsoleApp.getTestingInteractiveEnabled方法的具体用法?Python ConsoleApp.getTestingInteractiveEnabled怎么用?Python ConsoleApp.getTestingInteractiveEnabled使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类director.consoleapp.ConsoleApp
的用法示例。
在下文中一共展示了ConsoleApp.getTestingInteractiveEnabled方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: ConsoleApp
# 需要导入模块: from director.consoleapp import ConsoleApp [as 别名]
# 或者: from director.consoleapp.ConsoleApp import getTestingInteractiveEnabled [as 别名]
from director import roboturdf
app = ConsoleApp()
# create a view
view = app.createView()
segmentation._defaultSegmentationView = view
robotStateModel, robotStateJointController = roboturdf.loadRobotModel('robot state model', view, parent='sensors', color=roboturdf.getRobotGrayColor(), visible=True)
segmentationroutines.SegmentationContext.initWithRobot(robotStateModel)
# Move robot to near to table:
robotStateJointController.q [5] = math.radians(120)
robotStateJointController.q[0] = -1.5
robotStateJointController.q[1] = 2
robotStateJointController.q[2] = 0.95
robotStateJointController.push()
# load poly data
dataDir = app.getTestingDataDirectory()
polyData = ioUtils.readPolyData(os.path.join(dataDir, 'tabletop/table-and-bin-scene.vtp'))
vis.showPolyData(polyData, 'pointcloud snapshot')
#segmentation.segmentTableScene(polyData, [-1.58661389, 2.91242337, 0.79958105] )
segmentation.segmentTableSceneClusters(polyData, [-1.58661389, 2.91242337, 0.79958105], clusterInXY=True )
if app.getTestingInteractiveEnabled():
view.show()
app.showObjectModel()
app.start()