def __init__(self, parent): wx.Frame.__init__(self, parent, -1, "pythonOCC-%s 3d viewer ('wx' backend)" % VERSION, style=wx.DEFAULT_FRAME_STYLE, size=size) self.canva = wxViewer3d(self) self.menuBar = wx.MenuBar() self._menus = {} self._menu_methods = {}
def __init__(self, parent): wx.MDIChildFrame.__init__(self, parent, -1, "", style=wx.DEFAULT_FRAME_STYLE, size=(640, 480)) self.canva = wxViewer3d(self)
def __init__(self, parent, title, x, y): wx.Frame.__init__(self, parent=parent, id=-1, title=title, pos=(x, y), style=wx.DEFAULT_FRAME_STYLE, size=(400, 300)) self.canva = wxViewer3d(self)
def __init__(self, parent): wx.Frame.__init__(self, parent, -1, "wxDisplay3d sample", style=wx.DEFAULT_FRAME_STYLE, size=(640, 480)) self.canva = wxViewer3d(self) self.canva.InitDriver()
def view(*shapeList): frame = wx.Frame(None, -1, "OCC frame", size=(600, 700)) v = wxViewer3d(frame) v.InitDriver() canvas = v._display frame.Show() wx.SafeYield() canvas.Init3dViewer() viewer = canvas._3dDisplay for shape in shapeList: viewer.DisplayShape(shape) app.MainLoop()
def __init__(self, parent): wx.Frame.__init__(self, parent, -1, "pythonOCC-%s 3d viewer ('wx' backend)"%VERSION, style=wx.DEFAULT_FRAME_STYLE,size = (640,480)) panel1 = wx.Panel(self, -1,pos=(1000,0),size=(600,700)) self.canva = wxViewer3d(panel1) self.canva.SetSizeWH(600,600) self.menuBar = wx.MenuBar() self._menus = {} self._menu_methods = {} panel2 = Page(wx.Panel(self, -1,pos=(0,0),size=(1000,530))) panel2.SetSizeWH(1000,530) wx.Button(panel1, 1, "ISO", pos=(10, 620), size=(50,25)) self.Bind(wx.EVT_BUTTON, self.viewPoint) wx.Button(panel1, 2, "Front", pos=(10+50, 620), size=(50,25)) self.Bind(wx.EVT_BUTTON, self.viewPoint) wx.Button(panel1, 3, "Side", pos=(10+100, 620), size=(50,25)) self.Bind(wx.EVT_BUTTON, self.viewPoint) wx.Button(panel1, 4, "Up", pos=(10+150, 620), size=(50,25)) self.Bind(wx.EVT_BUTTON, self.viewPoint)
def __init__(self, parent): wx.Frame.__init__(self, parent, -1, "wxDisplay3d sample", style=wx.DEFAULT_FRAME_STYLE,size = (640,480)) self.canva = wxViewer3d(self) print 'self.canva',self.canva
def __init__(self, parent): wx.MDIChildFrame.__init__(self, parent, -1, "", style=wx.DEFAULT_FRAME_STYLE,size = (640,480)) self.canva = wxViewer3d(self)
def __init__(self, parent,title,x,y): wx.Frame.__init__(self, parent=parent, id=-1, title=title, pos=(x,y),style=wx.DEFAULT_FRAME_STYLE,size = (400,300)) self.canva = wxViewer3d(self);