Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (499)
Games in Android Showcase (118)
games submitted by our members
Games in WIP (568)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Greying  (Read 2179 times)
0 Members and 1 Guest are viewing this topic.
Offline kevglass

JGO Kernel


Medals: 172
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Posted 2004-02-20 13:23:59 »

Its been a while, but I'm looking at some doing some 2D stuff again. Could someone try this out:

http://www.cokeandcode.com/commander/commander.jnlp

The panel at the top is an accelerated rendering surface. Cursor keys will move the elements around. The FPS is attempted to be fixed to 50.

* Do you get 50 FPS? (on what hardware)
* When the bits and pieces move do you get a greying of the white box?
* Does it run on your platform?

Can anyone explain to me whats causing the greying out of the white box as it moves around?

Cheers in advance for any help,

Kev

Offline princec

JGO Kernel


Medals: 391
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #1 - Posted 2004-02-20 13:30:57 »

Dead on 50Hz, scary 100% CPU and at 90% kernel time (!), P4m2GHz, Nvidia GF4 mobile thing, JRE1.5.0beta1
Didn't see any greying but it might be coz the TFT screen doesn't show it up.

Cas Smiley

Offline Mojomonkey

Senior Member




ooh ooh eee eeee


« Reply #2 - Posted 2004-02-20 13:33:26 »

50 FPS on the dot. Geforce 3, P4 2.4 Win 2k.

I did not see any greying of the box, it stayed white for me.

Don't send a man to do a monkey's work.
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline kevglass

JGO Kernel


Medals: 172
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #3 - Posted 2004-02-20 13:34:37 »

Greying is only visible when moving the block around with the cursors.

Yeah, the 100% CPU is the sleep routine I think (gagetimer). If anything else should attempt to get some processor time it'll yield() to it.. at least, thats the theory.

I'm running on a lapper to, greying is fairly evident.

Cheers for trying it Cas,

Kev

Offline kevglass

JGO Kernel


Medals: 172
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #4 - Posted 2004-02-20 13:40:06 »

Just tried it on a desktop box and the greying isn't present, unfortunately I seem to have rather alot of "tearing" as the box moves around.

Any idea whats causing this?

Kev

Offline cfmdobbie

Senior Member


Medals: 1


Who, me?


« Reply #5 - Posted 2004-02-20 13:51:57 »

If you're getting tearing, I'm guessing it's not double buffered?

Worked fine for me, 50fps exactly.  Win98SE, 700MHz Athlon, GeForce4 MX 420.  Although it hard-crashed my machine on exit, for which I'm willing to blame Firebird's connection to the WebStart process. Grin

Oh, and the cursor keys move the box in the wrong direction!

Hellomynameis Charlie Dobbie.
Offline kevglass

JGO Kernel


Medals: 172
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #6 - Posted 2004-02-20 13:55:22 »

Quote

If you're getting tearing, I'm guessing it's not double buffered?


See, thats what confused me.. it uses a BufferStrategy which I figured was handling that for me. But still with the tearing.. maybe I need to go read the wiki or something, huh?

Quote

Oh, and the cursor keys move the box in the wrong direction!


Smiley Only if you think of it as moving the box, its a map, so your moving your viewpoint.

Kev

Offline Orangy Tang

JGO Kernel


Medals: 56
Projects: 11


Monkey for a head


« Reply #7 - Posted 2004-02-20 14:22:18 »

Quote
See, thats what confused me.. it uses a BufferStrategy which I figured was handling that for me. But still with the tearing.. maybe I need to go read the wiki or something, huh?

BufferStragegy handles the double/triple/whatever buffers for you, and their swapping to the screen, but it does not always swap at the end of a monitors vertical trace.

IIRC, proper v-sync'ed buffer swapping only happens on windows, in fullscreen mode. Else you get tearing Sad

[ TriangularPixels.com - Play Growth Spurt, Rescue Squad and Snowman Village ] [ Rebirth - game resource library ]
Offline Abuse

JGO Knight


Medals: 12


falling into the abyss of reality


« Reply #8 - Posted 2004-02-20 14:24:57 »

Tearing is a result of not vsyncing on the monitor refresh.

As you are not running fullscreen, you can't vsync anyway, so don't worry about it.

* Do you get 50 FPS? (on what hardware)

the fps counter says 50.... that doesn't mean thats how fast its running ofcourse Wink

1.33gig Athlon GF2gts

* When the bits and pieces move do you get a greying of the white box?

no

* Does it run on your platform?

yeah, WinXP Java 1.5.0beta1

Make Elite IV:Dangerous happen! Pledge your backing at KICKSTARTER here! https://dl.dropbox.com/u/54785909/EliteIVsmaller.png
Offline swpalmer

JGO Coder


Exp: 12 years


Where's the Kaboom?


« Reply #9 - Posted 2004-02-20 14:37:02 »

Mac OS X 10.3.2 JRE 1.4.2_03  powerbook G4 1GHz  ATI Radeon 9000

Max 25fps low of 16fps  Sad

no greying.

I sure wish the OS X guys would get accelerated images going...

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline kevglass

JGO Kernel


Medals: 172
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #10 - Posted 2004-02-20 14:45:44 »

So then, this is annoying. I want to write a very simple (at least visually) game. RTS style with those little circles representing players and the white bits being walls.

However, if I can even get the map scrolling around without fsking people's eyes up what hope is there? I was hoping aim the game at low end machines (the type offices are full of - onboard Intel graphics). Was hoping to stay windowed aswell (makes it easy to pretend your working Smiley)

Any ideas folks?

Kev

Offline Abuse

JGO Knight


Medals: 12


falling into the abyss of reality


« Reply #11 - Posted 2004-02-20 15:08:52 »

Tearing is only realy visible when you have high contrast areas (such as white on black in your test app.)
It won't be a problem in a proper game.

Make Elite IV:Dangerous happen! Pledge your backing at KICKSTARTER here! https://dl.dropbox.com/u/54785909/EliteIVsmaller.png
Offline kevglass

JGO Kernel


Medals: 172
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #12 - Posted 2004-02-20 15:12:19 »

Thats the thing, it was gonna be somewhat a diagramatic representation of the world. So blocks of white on black (or green on black) are fairly likely..

Kev

Offline Abuse

JGO Knight


Medals: 12


falling into the abyss of reality


« Reply #13 - Posted 2004-02-20 15:48:11 »

hmm, well if you have an accurate timer (that doesn't drift), u could hack together a user feedback calibration system.

Where by, you continually blit a sequence of differently colored rectangles to the screen, and ask for the user to press +/- until the tearing stops.
(you use the +/- adjustment to alter your timing offset)

It is abit of a hack, but, if your careful and your timer is good enough, there is no reason why you can't artificially keep yourself in sync with the vblank signal :O

Or, alternatively, you could write some native code that tied itself to the vblank signal. Got no idea how you would go about doing that... but im (fairly) sure it isn't impossible.

Make Elite IV:Dangerous happen! Pledge your backing at KICKSTARTER here! https://dl.dropbox.com/u/54785909/EliteIVsmaller.png
Offline oNyx

JGO Coder


Medals: 2


pixels! :x


« Reply #14 - Posted 2004-02-20 18:25:33 »

* Do you get 50 FPS? (on what hardware)

Rock solid 50fps. K7 500/128mb/gf2mx/1.4.2_03

It would even run on something like a K6-2 300/128mb/banshee with 50fps Smiley

* When the bits and pieces move do you get a greying of the white box?

No. You use a TFT display don't you?

You have rise/fall latencies. That's the time a pixel needs to turn completly white (from black) and vice versa. If it's moving you have pixels wich turns white and pixels wich turns black (but no real black/white), therefore it appears to be gray.

Usually the effect isn't that visible because the contrast isn't that high (eg instead of a 0-100% rise you have something like 45-60%).

* Does it run on your platform?

Apparently Smiley

弾幕 ☆ @mahonnaiseblog
Offline blahblahblahh

JGO Coder


Medals: 1


http://t-machine.org


« Reply #15 - Posted 2004-02-20 19:19:14 »

Quote
Its been a while, but I'm looking at some doing some 2D stuff again. Could someone try this out:

http://www.cokeandcode.com/commander/commander.jnlp



It won't run at all on linux. Webstart complains that your JAR is unsigned and is attempting to get full access. It only gives me the options of "Abort" and "Details".

Because JWS sucks almightily, it doesn't support copy/paste in the details box so I can't copy paste the exact details and/or exception.

I've never had this problem before, and I've not updated my java for many months (1.4.2)

malloc will be first against the wall when the revolution comes...
Offline princec

JGO Kernel


Medals: 391
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #16 - Posted 2004-02-20 21:59:49 »

Shame... and it works so well on Windows Smiley

LWJGL! LWJGL! LWJGL! That's why we created it. Solve those performance blues. Get that smoov and slick feel. Grease that weasel.

Cas Smiley

Offline trembovetski

Senior Member




If only I knew what I'm talking about!


« Reply #17 - Posted 2004-02-21 01:10:15 »

There you go:
Quote

An error occurred while launching/running the application.

Title: Squad Commander
Vendor: Kev Glass - New Dawn Software
Category: Security Error

Unsigned application requesting unrestricted access to system
Unsigned resource: http://www.cokeandcode.com/commander/commander.jar


And it's on WinXP. I wish JWS asked me if I want to run the app instead of just showing that error dialog.
Offline kevglass

JGO Kernel


Medals: 172
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #18 - Posted 2004-02-21 06:41:59 »

Sorry about that guys, I must have forgotten to sign as I uploaded the new version. Resigned, reuploaded.

LWJGL - doesn't this mean I automagically using GL tho? With onboard graphics card (old machines) that'd mean I get software GL wouldn't it? Is that going to be faster than DX in this case? Oh, and does LWJGL have any problems using super early versions of GL? Not ruled the idea out, just need to check.

Kev

Offline princec

JGO Kernel


Medals: 391
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #19 - Posted 2004-02-21 06:59:11 »

Actually we don't allow software GL rendering - the whole point is that you're guaranteed hardware acceleration. So maybe not a great solution in that respect but you will get cracking performance on 65% of Windows machines and 95% of Macs and any Linux machines whose users have patience and skill.

Early GL is fine. AF runs entirely on 1.1 and has even been seen running on a Voodoo 3 and a G200. The problem is always the drivers rather than anything else.

Cas Smiley

Offline Abuse

JGO Knight


Medals: 12


falling into the abyss of reality


« Reply #20 - Posted 2004-02-21 07:04:25 »

Does it run with the voodoo2/Banshee's mini-GL driver?

(I dunno why im askin' this, I could just walk in the next room and try it Tongue)

Make Elite IV:Dangerous happen! Pledge your backing at KICKSTARTER here! https://dl.dropbox.com/u/54785909/EliteIVsmaller.png
Offline princec

JGO Kernel


Medals: 391
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #21 - Posted 2004-02-21 07:10:54 »

Should do... the window init code is based on Q2 init code.

Cas Smiley

Offline Mark Thornton

Senior Member





« Reply #22 - Posted 2004-02-21 07:15:18 »

Solid 50fps, no problems apart from WebStart. I ahd to cut and paste the URL into webstart. Just clicking on the url in IE6 results in an invalid argument error. The underlying exception is that it couldn't open a file!
Anyone know what is going on? I very much like WebStart in principle, but the implementation seems problematic.

Later ... installing 1.5.0 beta takes away the ability to paste the URL into WebStart, but doesn't fix the problem with loading the jnlp file via IE. Grrr. Oh, and 1.5 gave me my first bluescreen crash in ages ... fixed by updating my ATI drivers.
Offline oNyx

JGO Coder


Medals: 2


pixels! :x


« Reply #23 - Posted 2004-02-21 07:20:32 »

Quote
[...]
Early GL is fine. AF runs entirely on 1.1 and has even been seen running on a Voodoo 3 and a G200.[...]


It even worked on a Banshee Smiley

And that's something like a Voodoo 2.5, therefore it would even work on a Voodoo2 (afaik). There weren't many differences between those chipsets. V2 had two texturing units... and the Banshee had only one but had a higher clock (and an integrated 2d unit).

弾幕 ☆ @mahonnaiseblog
Offline blahblahblahh

JGO Coder


Medals: 1


http://t-machine.org


« Reply #24 - Posted 2004-02-21 08:02:05 »

Quote


OK, works now. And I don't get any "greying". But...this is a good LCD (Dell can be pretty crummy at support and drivers etc, and some of the components are crud, but they source exceptionally good LCD's for their laptops). This series may even have "better" screens precisely because they put Geforce's into them...?

I get: 49, 52, and 53 FPS

Geforce2Go - 1Ghz P3-M, linux 1.4.2

malloc will be first against the wall when the revolution comes...
Offline jbanes

JGO Coder


Projects: 1


"Java Games? Incredible! Mr. Incredible, that is!"


« Reply #25 - Posted 2004-02-22 20:40:21 »

Hey Kev,

If I may interject here, there's a better way of handling this type of game. Frames per second renderers are primarly for "twitch" type of game. For games that may only have an event occur when the user gives input, or the AI updates a location every 1/10 of a second, you're better off using passive rendering. Only call for a render while the user is moving, or the AI updates. You'll still need a timed loop to handle things like AI and player movement (the repeat buffer is very jerky), but shearing should become almost impossible to notice.

BTW, if you're getting greying, make sure you tell the Frame to ignore repaint requests.

Java Game Console Project
Last Journal Entry: 12/17/04
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

Pippogeek (40 views)
2014-09-24 16:13:29

Pippogeek (31 views)
2014-09-24 16:12:22

Pippogeek (21 views)
2014-09-24 16:12:06

Grunnt (47 views)
2014-09-23 14:38:19

radar3301 (29 views)
2014-09-21 23:33:17

BurntPizza (65 views)
2014-09-21 02:42:18

BurntPizza (37 views)
2014-09-21 01:30:30

moogie (44 views)
2014-09-21 00:26:15

UprightPath (53 views)
2014-09-20 20:14:06

BurntPizza (55 views)
2014-09-19 03:14:18
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!