Jump to content

  • Log In with Google      Sign In   
  • Create Account

14 years ago on June 15th Gamedev.net was first launched! We want to thank all of you for being part of our community and hope the best years are ahead of us. Happy birthday Gamedev.net!

floatingwoods

Member Since 09 Jun 2008
Offline Last Active May 28 2013 07:37 AM
-----

Posts I've Made

In Topic: Game thread synchronization (display & game logic)

28 May 2013 - 06:33 AM

Hodgman and Matias,

 

Thanks a lot for the very clear and exhaustive explanations. The links you mentionned were also helpful.

To give a little bit more background: I used to get inspired a lot on the gamedev forums, I however am more in the field of simulation. There, it is of importance if something gets rendered wrongly, or if a frame gets skipped without specific reason. Interpolation between two states could work, but might lead to some unrealistic renderings too and confusion, specially when stepping generated videos later on (usually there is one frame per simulation step, which helps debugging certain set-ups). Finally, the simulation (or game logic) uses the openGL functionality, in order to generate virtual images, operate on them (e.g. image processing) and create an output. The time at which the "internal" or FBO rendering occures depends on the simulation loop and how it is programmed. So there I get another heavy restriction regarding multithreading: the rendering thread and "game logic" thread can both generate OpenGL commands, and need to switch contexts every time. In that case, locking (or rather blocking) the other thread is the only option.

Given the many constraints and limitations, I concluded that having an additional thread in charge of rendering would not give me much speed increase, but would complicate drastically the architecture.

My application uses basically one single thread (of course it also uses worker threads for specific tasks) that handles the "game logic" and the visualization. But I wanted to evaluate the benefits of spliting the task into 2 different threads, and maybe even offering the 2 alternatives.

 

Again thanks for the insightful replies!


In Topic: Library for ray-tracing

27 March 2013 - 02:20 PM

Thank you for the suggestions!

 

I'll mention this again, but what about openRL? ( https://www.caustic.com/ )


In Topic: Calling opengl functions from a plugin

25 March 2013 - 02:42 PM

Oops, you are totally right, I made a mistake.

 

Thanks a lot Brother Bob!


In Topic: Trouble with very slow rendering with nvidia under Linux

06 February 2013 - 03:44 PM

Thanks a lot for all the pertinent replies. I'll try to look at all those possible reasons.

 

Cheers!


In Topic: Turn a non reentrant C library into a library supporting several instances of...

04 February 2013 - 03:19 AM

Thanks edd and Paradigm Shifter,

 

The C code has to run on Windows, Mac OSX and Linux. I guess that makes it a bit more complicated for the solution where the library is loaded several times into memory.

I will go with your solution edd, even if a bit troublesome (since I have to touch the original code quite deeply).

 

Thanks at lot!!


PARTNERS