Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 [2]

Author Topic: Question about 40d# merge and Mac/Linux port  (Read 2204 times)

Sowelu

  • Bay Watcher
  • I am offishially a penguin.
    • View Profile
Re: Question about 40d# merge and Mac/Linux port
« Reply #15 on: May 04, 2010, 09:02:15 am »

That's correct Dabi, but consider that FPS is really an inverse of "delay per frame".

When your fortress is young, and you don't have many dwarves, maybe rendering will take 20ms, and pathfinding will take 10ms.  Reduce the rendering time down to 5ms, and you've doubled the speed!  But when your fortress is old, the pathfinding increases to maybe 100ms...  Reduce the rendering time down to 5ms, and it has a much smaller relative impact on framerate.
Logged
Some things were made for one thing, for me / that one thing is the sea~
His servers are going to be powered by goat blood and moonlight.
Oh, a biomass/24 hour solar facility. How green!

jfs

  • Bay Watcher
    • View Profile
Re: Question about 40d# merge and Mac/Linux port
« Reply #16 on: May 04, 2010, 10:42:13 am »

One of the things that never made it into a playable DF, which Baughn reportedly got working shortly before 0.31.01 was released, was multithreaded rendering: The graphics rendering decoupled from the game's logic processing, meaning that graphics and game logic shouldn't mutually slow each other down in some bad cases. It'll also free up more CPU time for the game logic on multi-core systems.
I'm hoping that makes it in.
Logged

Corona688

  • Bay Watcher
    • View Profile
Re: Question about 40d# merge and Mac/Linux port
« Reply #17 on: May 05, 2010, 03:38:45 pm »

That's going to be a particularly tricky one if it's not done just right.  The context that sets the video mode should be the one to do the rendering, which would make the DF virtual world the thread and the graphics code the parent!  And since I/O is tied to the graphics context, keystrokes need to be handled there too.  If it's done backwards or some bits in different threads, systems and drivers vary on how willing they are to tolerate that.
Logged
You never know when you might need a berserk dwarf to set loose somewhere.
Pages: 1 [2]