Beispiel #1
0
 def newLayer(self):
     layer = canvaslayers.ComboCanvasLayer()
     canvas = self.gfxwindow.oofcanvas
     # The names of the layers here must correspond to the
     # targetnames used in skeletoninfo.py.
     layer.addSublayer(
         "Element",
         canvaslayers.SimpleWireframeCellLayer(canvas, True,
                                               "ElementSkelInfo"))
     if config.dimension() == 3:
         layer.addSublayer(
             "Face",
             canvaslayers.SimpleWireframeCellLayer(canvas, True,
                                                   "FaceSkelInfo"))
     layer.addSublayer(
         "Segment",
         canvaslayers.SimpleWireframeCellLayer(canvas, False,
                                               "SegmentSkelInfo"))
     layer.addSublayer(
         "Node", canvaslayers.SimplePointCellLayer(canvas, "NodeSkelInfo"))
     assert not self.tbcallbacks
     self.tbcallbacks = [
         switchboard.requestCallbackMain((self.gfxwindow, "query Skeleton"),
                                         self.queryCB),
         switchboard.requestCallbackMain((self.gfxwindow, "peek Skeleton"),
                                         self.peekCB)
     ]
     return layer
Beispiel #2
0
 def newLayer(self):
     layer = canvaslayers.ComboCanvasLayer()
     canvas = self.gfxwindow.oofcanvas
     # The names of the layers here must correspond to the
     # targetnames used in meshinfo.py.  "Face" and "Segment"
     # aren't use there currently (4/2012) but may be added later,
     # so they're included here (but not tested!).
     layer.addSublayer(
         "Element",
         canvaslayers.SimpleWireframeCellLayer(canvas, True,
                                               "ElementMeshInfo"))
     # layer.addSublayer(
     #     "Face",
     #     canvaslayers.SimpleWireframeCellLayer(canvas, True,
     #                                           "FaceMeshInfo"))
     # layer.addSublayer(
     #     "Segment",
     #     canvaslayers.SimpleWireframeCellLayer(canvas, False,
     #                                           "SegmentMeshInfo"))
     layer.addSublayer(
         "Node", canvaslayers.SimplePointCellLayer(canvas, "NodeMeshInfo"))
     self.tbcallbacks = [
         switchboard.requestCallbackMain((self.gfxwindow, "query Mesh"),
                                         self.queryCB),
         switchboard.requestCallbackMain((self.gfxwindow, "peek Mesh"),
                                         self.peekCB),
         switchboard.requestCallbackMain("mesh data changed",
                                         self.meshDataChangedCB)
     ]
     return layer
 def newLayer(self):
     self.setupSignals()
     # The second arg to the SimpleWireframeCellLayer constructor
     # tells it not to extract edges from the cells (because the
     # cells will already be edges).
     return canvaslayers.SimpleWireframeCellLayer(
         self.gfxwindow.oofcanvas, False, "SkeletonSelectedSegment")
Beispiel #4
0
 def newLayer(self):
     return canvaslayers.SimpleWireframeCellLayer(self.gfxwindow.oofcanvas,
                                                  True, "SkeletonIllegal")