Debug Center

So it’s up and running.

Nothing really fancy yet :

  • You can launch it via ExtXith3DEnvironment.launchDebugCenter(ExtRenderLoop rl) so in most case you would do launchDebugCenter(this), which is convenient
  • It automatically adds " - Xith3D Debug Center Active (press Ctrl + F1 for Help)" to the title of your app (even if it’s changed).
  • Ctrl + S = Stats (i know, bad keyboard shortcut but if you know a better one)
  • Ctrl +T = Scenegraph Tree (this one will get improved soon)
  • Featuring a SwingTM GUI, I’m still thinking a 3D XIth HUD integrated would be better/also good… what do you think ?
  • Features to come : pause/play and step by step (also maybe modifying game speed : I’d need methods for that, Marvin, in RenderLoop so that it act on frameTime and gameTime, actually it’s cheating a bit but it’s only for debug purposes)…

You can test it in the org.xith3d.w3g,Physics class.

Enjoy !

Great :).

Well, actually the launch method is in Xith3DEnvironment. And is ExtRenderLoop really necessary? Isn’t RenderLoop sufficient?

Yes. Ctrl + D (for DebugCenter ;D.

Yes, a HUD implementation would be great.

pause and resume methods are already there. There’s even a step by step method called forceNextIteration(). But it doesn’t handle gameTime and frameTime. I’ll see, if I can change that.

Marvin

No. Try to change to simple RenderLoop, some methods aren’t there in RenderLoop (can’t remember which right now).

No. Currently, Ctrl + S just prints FPS and MPF (millis per frame), well infact it’s a mean of these values collected for one second. Ctrl +D isn’t logical… but anyway if it’s working with Eclipse things will change.

yeah forceNextIteration() without a frameTime parameter is pretty useless…

Yeah. I already saw, that you used Animatable to retrieve the gameTime and frameTime. So ExtRenderLoop is needed. I’ll look, if I can provide a mechanism in RenderLoop to retrieve these values (especially frameTime). For the moment it would be more logic to use ScheduledOperation instead of Animatable, which will do exactly the same, but is more logic (for the naming).

Marvin

So there’s absolutely no difference between SchedOp and Animatable ?

There is. But it’s not a matter of the difference. Animatable extends ScheduledOperation and ScheduledOperation offers all the functionality you need for the job. Animatable just adds the methods needed for animation convenience, which are not needed by DebugCenter. And you will agree, that a DebugCenter is not Animatable (well would be crazy if it was 8)), but won’t make too much sense.

Marvin

I’ve added a nextIteration() method to to RenderLoop class. It fully supports time calculation 8). It returns the frameTime. You can retrieve the current gameTime by invoking getGameTime().

Marvin