From: Sven G. <sgo...@ja...> - 2000-09-01 00:14:48
|
Virgil Wall wrote: > > > Really ? > > I thought that even 50ms precision should be enough > > -> about 20 fps (more or less :-) ! > > The visual quality of using the more precise clock is pretty apparent in > some situations. The human eye is pretty good at catching "glitches" in > anticipated motion. Pretty much any commercial game uses more accurate > timing. > > > > > Well - anyway, if you really have to be that precisous, > > i wonder, how you handle the _very_ unprecise Thread.sleep() call ? > > Because you are guaranteed to be woke up in the right time ... > > Because I time the sleep too. What matters is how much time elapsed since > the last update, Thread.sleep/Thead.yield and all. The only reason to > sleep/yield at all is to prevent thread starvation. So naturally, you have > to take a time stamp, sleep a little, take another timestamp and repeat. > well, it must be interesting ... may be some kind of stereo capabilities will need this quality also. > > > > > (For the curious, the Magician Java opengl crap has a percision timer > > > call... it's pretty each to do, but one might argue that it has nothing > to > > > do with opengl) > > > > > > > Ok ... so why don't you offer your native function > > to GL4Java ? > > Because I'd have to make it work on windows, unix and mac:) (windows and > unix are no problem,btw) > Also, if I'm going to go to all of this trouble, then I'd probably offer > more than just a few timing calls. For instance, I use native calls to > change the screen resolution and make the fullscreen window a top level > window (so it would be possible to do full screen things at some resolution > other than what the user's desktop is set to). > Sounds fine, if all platforms can handle it - I guess so ! A nice extension to the GLContext class ?! So please - just send your code if it is done, piece for piece. Or will you hold things proprietary ? :o) > > > > If the implementation uses the Unix like time functions, > > I guess we can add it for ALL OS/platforms ! > > I love to add it into the next release, if you are fast :-) enough .. > > Currently I am working for: > > - Linux*, Solaris-, SGI/Irix*, HP-UX- > > - MacOS- > > - Win32* > > ports of GL4Java ! > > (* well done, - some platform specific problems, but under work) > > > > Well, please do not make OS depended stuff - if possible. > > Your application should run on all of our GL4Java platforms, right ? > > Nope :) to be honest, I could care less if anyone on HPUX can play this game > or not. If I'm going to care about HPUX then I'm also going to care about > AIX... which isn't in your list. Ooops ... AIX should work also :-) AIX was my official 1st Unix port of GL4Java, but now, i do not have access to this machine, to produce binaries ... All Unix machines with X11R6 (and hopefully gcc), should work ! Just need some time and machine access ... > By the time I'm done, I'm also probably > going to be using DirectInput on windows (so I can poll the keyboard > directly and use a force feedback joystick). I might also use > directsound.... So, a native timing function is the least of my concern. > Puhh ... Well, this looks very native .. may be not interesting. But all the parts, like timing funcs etc. :-), are portable .. > > So just try to minimize special native things, > > I hear you.... and I do just as any person might (its much easier to > manage). > > > and offer them (the native atoms) to the gl4java project - no problem ! > > Virgil Sorry for being that non diplomatics and shrill, just want to force you to show me something :o) Yours, Sven -- mailto:sgo...@ja... www : http://www.jausoft.com ; pgp: http://www.jausoft.com/gpg/ voice : +49-521-2399440, +49-170-2115963; fax: +49-521-2399442 |