ogre+Tkinter

sherif

24-05-2007 09:48:15

HI!
I need that the ogre engine drawes to the Tkinter window
i dont know how to initialize the engine can someone help me
thanks

ive done this so far:

from Tkinter import *

import ogre.renderer.OGRE as ogre
rootg = ogre.Root("plugins.cfg")
rootg.showConfigDialog()
rootg.initialise(False)

root = Tk()
root.title('New_Toplevel_1')
root.geometry('771x413+132+132')

misc=ogre.NameValuePairList()



misc['externalWindowHandle'] = str(root.winfo_id())

renderWindow = rootg.createRenderWindow( "name",root.winfo_width(),root.winfo_height(),0, misc)
renderWindow.active = True



def render():
rootg.renderOneFrame()



root.after(1,render)
root.mainloop()




but its not working nothing happens to the Tkinter window
some ideas?
thanks

sherif

29-05-2007 22:57:00

after seveal weeks ive spend on it i ve done
this
http://sherif.kx.cz/tk.rar
i dont think its realy working
i dont have time to finnish it may be somebody has

please if you get this to work share it :)



btw please update the wiki :?

ps: sorry that the code is a little mesy ive done the moust work at night o.O