Horde3D

Next-Generation Graphics Engine
It is currently 29.03.2024, 13:34

All times are UTC + 1 hour




Post new topic Reply to topic  [ 75 posts ]  Go to page Previous  1, 2, 3, 4, 5  Next
Author Message
 Post subject: Re: Python wrapper
PostPosted: 03.02.2009, 22:03 
Offline

Joined: 14.04.2008, 15:06
Posts: 183
Location: Germany
Is Horde3DUtils.dll in the same folder as Horde3D.dll? Seems like it's missing or can't be loaded.


Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 03.02.2009, 22:51 
Offline

Joined: 05.03.2007, 19:38
Posts: 167
Location: Romania
It was in the same folder but it threw that error. I ditched cmd and went for batch files. That error doesn't show anymore.

The actual error is:
Code:
Traceback (most recent call last):
  File "D:\SDKs\Horde3D\benchmark\System\knight.py", line 234, in <mo
    main()
  File "D:\SDKs\Horde3D\benchmark\System\knight.py", line 230, in mai
    app.mainloop()
  File "D:\SDKs\Horde3D\benchmark\System\app.py", line 218, in mainlo
    self._mainloopUpdate(dt)
  File "D:\SDKs\Horde3D\benchmark\System\knight.py", line 212, in _ma
e
    h3d.advanceEmitterTime(h3d.getNodeFindResult(i), 1.0 / curFPS)
AttributeError: 'module' object has no attribute 'advanceEmitterTime'

_________________
Paul


Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 03.02.2009, 22:57 
Offline

Joined: 26.03.2008, 02:58
Posts: 160
How are you generating the python wrappers?

I moved over to Panda3D for faster development of prototype game. It's pretty nice but i would like to have a better rendering library that is shaders based like horde 3d available.


Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 03.02.2009, 23:04 
Offline

Joined: 14.04.2008, 15:06
Posts: 183
Location: Germany
@SpOOky: ok, just missing functionality no dll issues anymore.

@DDd: I'm writing the new bindings by hand using ctypes by looking at the C/C++ bindings and providing wrappers for all functions.

I've attached the nearly complete bindings for svn r190.


Attachments:
File comment: bindings for community svn r190
Python-ctypes-2.zip [12.25 KiB]
Downloaded 679 times
Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 04.02.2009, 00:57 
Offline

Joined: 05.03.2007, 19:38
Posts: 167
Location: Romania
The sample now works.

It crashes though when i hit F9, because it can't find the method showFrameStats. I assume that's because of missing functionality.

Keep up the good work. This wrapper speeds up my tools development considerably.

_________________
Paul


Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 04.02.2009, 14:08 
Offline

Joined: 14.04.2008, 15:06
Posts: 183
Location: Germany
The pure Python bindings are now nearly complete, refer to README in community svn HEAD.

Anyone interested in the sound extension?


Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 04.02.2009, 17:58 
Offline

Joined: 05.03.2007, 19:38
Posts: 167
Location: Romania
Is the knight sample outputting the same number of particles as its c++ counterpart?

I ask this because it actually runs faster on my laptop(nv8200).

It idles at arround 84fps while the cpp version at 46 (tested at 800x600 no HDR for both, same shaders, same camera angle)
Meanwhile I will run some more benchmarks on my pc(2x8800SLI).

LE: on my pc the python version runs at @1200fps while the cpp one @654fps(same testing conditions)

I know that there is a bug in visual studio 2008, when upgrading an existing project (the /O2 flag is lost and the app isn't optimized)
but I am sure I worked around it.

Can anyone provide an msvc2005 build of the sample, against the latest svn?

_________________
Paul


Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 04.02.2009, 18:29 
Offline

Joined: 14.04.2008, 15:06
Posts: 183
Location: Germany
The scenes should be identical... Here it's also faster: 150FPS C/C++ vs 425FPS Python.
Comparing the code I saw that a finalizeFrame call is missing. But that doesn't affect the FPS. glfw vs pyglet?


Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 04.02.2009, 19:35 
Offline

Joined: 22.11.2007, 17:05
Posts: 707
Location: Boston, MA
Codepoet wrote:
The scenes should be identical... Here it's also faster: 150FPS C/C++ vs 425FPS Python.
Comparing the code I saw that a finalizeFrame call is missing. But that doesn't affect the FPS. glfw vs pyglet?
I seriously doubt that there pyglet has a 2.5x speed advantage over glfw, but I suppose it is possible - glfw tends to use fairly old code paths. More likely, something is being done very badly in the code of the C++ samples. I will give your pyglet code a spin as soon as I get the chance, and see if I can track down the problem in the C++.

The only issue I see so far is that the C++ samples dump the log file at the end of every frame - this is potentially quite slow as it does HTML formatting.

_________________
Tristam MacDonald - [swiftcoding]


Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 04.02.2009, 20:01 
Offline
Engine Developer

Joined: 10.09.2006, 15:52
Posts: 1217
During frame rendering there is usually no log messages (at least in the samples), so there should not be any html writing. I also doubt very much that glfw halfes the framerate, in the end it is just a window with some input handling. We also did not notice a slowdown when switching from SDK to glfw. What version of the engine have you used? Always the head svn revision?


Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 04.02.2009, 20:22 
Offline

Joined: 14.04.2008, 15:06
Posts: 183
Location: Germany
I'm using svn HEAD. I found a difference: The Python sample displays only 24k tris, the C++ sample 35k. I don't know why.


Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 05.02.2009, 17:44 
Offline

Joined: 14.04.2008, 15:06
Posts: 183
Location: Germany
added support for the sound extension. see community svn r196


Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 28.06.2009, 13:09 
Offline

Joined: 14.04.2008, 15:06
Posts: 183
Location: Germany
Push!
Added patch by Leon Oostrijk. Wrapper now works for community svn trunk again.


Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 08.12.2009, 12:43 
Offline

Joined: 15.02.2009, 02:13
Posts: 161
Location: Sydney Australia
Hi,

I've updated the python bindings for beta4, however some parts are probably wrong so don't use it expecting it to be 100% working! Codepoet, could you take a look at the files and tweak any mistakes? On my test setup apparently pyglet is broken on ubuntu 9.10 with ati radeon video cards so I can't test them, plus I haven't got a working 64-bit compiler for windows to compile & test Horde3D on WinXP64-bit... :(

Please find the following attachment Horde3D_beta4_python_bindings_update.zip

I've also updated the sample apps

Thank you
-Alex

EDIT: Updated the samples so that the shadow attributes are set properly, whoops!


Attachments:
Horde3D_beta4_python_bindings_update.zip [30.32 KiB]
Downloaded 655 times

_________________
-Alex
Website
Top
 Profile  
Reply with quote  
 Post subject: Re: Python wrapper
PostPosted: 08.12.2009, 16:54 
Offline

Joined: 05.03.2007, 19:38
Posts: 167
Location: Romania
I also had in the works updating the bindings to beta4. Guess you beat me to it :P

I use x64 builds of Horde3D on Windows. If you want i can give you the binaries. :)

_________________
Paul


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 75 posts ]  Go to page Previous  1, 2, 3, 4, 5  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 41 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group