Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (477)
Games in Android Showcase (107)
games submitted by our members
Games in WIP (536)
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  
  Potiential bug with full screen mode  (Read 3415 times)
0 Members and 1 Guest are viewing this topic.
Offline zparticle

Senior Member




Thick As A Brick


« Posted 2003-01-01 19:25:29 »

I am seeing a strange side effect of running in full screen mode in 1.4.0. Thought perhaps someone here could enlighten me as to the problem.

If I run my program several (10s of) times eventually the scolling goes from totally smooth to extreemly jerky and the frame rate drops dramatically. Sometime the program even starts to refuse to run telling me it "can't get the video mode".

If I change the resolution of the windows desktop to another resolution and then back to my normal resolution (not the res of the program) sometimes the problems goes away. Until another several runs. If I reboot the machine then the problems goes away, again until another several runs.

Is it possible that the image handling in Java 1.4 is somehow locking video memory and no releasing it? That is how the program reacts, as if it can no longer accelerate images due to incefficient VRAM.

Offline Abuse

JGO Coder


Medals: 11


falling into the abyss of reality


« Reply #1 - Posted 2003-01-02 02:52:27 »

Quote
I am seeing a strange side effect of running in full screen mode in 1.4.0. Thought perhaps someone here could enlighten me as to the problem.

If I run my program several (10s of) times eventually the scolling goes from totally smooth to extreemly jerky and the frame rate drops dramatically. Sometime the program even starts to refuse to run telling me it "can't get the video mode".

If I change the resolution of the windows desktop to another resolution and then back to my normal resolution (not the res of the program) sometimes the problems goes away. Until another several runs. If I reboot the machine then the problems goes away, again until another several runs.

Is it possible that the image handling in Java 1.4 is somehow locking video memory and no releasing it? That is how the program reacts, as if it can no longer accelerate images due to incefficient VRAM.


I think it has already been established, that buffer strategy+fullscreen in jdk1.4.1_01 is broken in many places.

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

Senior Member




Thick As A Brick


« Reply #2 - Posted 2003-01-02 13:06:52 »

Okay, but is this specific issue known to be a problem? I'm trying to determine if it is something I'm doing wrong or something I need to wait for a fix to resolve.

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

Senior Member




Thick As A Brick


« Reply #3 - Posted 2003-01-02 13:46:05 »

Can't find anything specific to this in the bug database. However looking at the javadocs for BufferStrategy I'm wondering if perhaps I should be doing the following:

1  
2  
3  
4  
5  
6  
7  
// when the program goes to exit

BufferCapabilitites bc = myStrategy.getCapabilities();

// make sure the buffers are released if the strategy is a page flipping strategy
if(bc.isPageFlipping())
    ((Component.FlipBufferStrategy)myStrategy).destroyBuffers();


Any thoughts?

Offline Abuse

JGO Coder


Medals: 11


falling into the abyss of reality


« Reply #4 - Posted 2003-01-02 16:39:21 »

if destruction of the buffers is not done automatically - then that is a bug in itself. However, I think it is. (as I have never come across this problem)

It sounds to me like a bug outside of Java. What gfx card are you using, whats the driver version, and what version of directX have you got installed?

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

Senior Member




Thick As A Brick


« Reply #5 - Posted 2003-01-02 18:01:51 »

Video Card: GeForce4 Ti 4600
Drivers: The dlls all say version 6.13.10.3082 but the drivers tab says 3.0.8.2
OS: Win2k 5.0.2195 SP3
Direct X: not sure how to tell I think I have 8.something

Offline SpuTTer

Senior Member


Medals: 1


Lazy Middle Class Intellectual


« Reply #6 - Posted 2003-01-02 21:03:19 »

Try start->run->dxinfo

Sacramento Volleyball
"Whitty phrase goes here."
Offline Abuse

JGO Coder


Medals: 11


falling into the abyss of reality


« Reply #7 - Posted 2003-01-02 23:39:14 »

Quote
Video Card: GeForce4 Ti 4600
Drivers: The dlls all say version 6.13.10.3082 but the drivers tab says 3.0.8.2
OS: Win2k 5.0.2195 SP3
Direct X: not sure how to tell I think I have 8.something


well, as far as im aware 3082 is the most uptodate available from nvidia. Spose it might be related specifically to the gf4, though I somehow doubt it.

You could also install dx9, though I very much doubt thats the cause of your problem.

Can you post the program that causes this problem, or is it repeated running of *any* java app that uses fullscreen exclusive?

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

Senior Member




Thick As A Brick


« Reply #8 - Posted 2003-01-03 03:11:02 »

It appears to be any program that is: full screen and allocates a fair number of accelorated images.

I use 3 buffers in the strategy. Start from a fresh reboot and then run the program say 20 to 30 times. The scrolling demo I put up in the shared code area has this same issue. So I suppose I should try that on another machine and see if the problem occurs.

Offline Abuse

JGO Coder


Medals: 11


falling into the abyss of reality


« Reply #9 - Posted 2003-01-03 18:38:35 »

scrolling demo? you got a link to that? Roll Eyes

Make Elite IV:Dangerous happen! Pledge your backing at KICKSTARTER here! https://dl.dropbox.com/u/54785909/EliteIVsmaller.png
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline zparticle

Senior Member




Thick As A Brick


« Reply #10 - Posted 2003-01-04 04:55:45 »

http://www.java-gaming.org/cgi-bin/JGOForums/YaBB.cgi?board=share;action=display;num=1036252001;start=


Offline trembovetski

Senior Member




If only I knew what I'm talking about!


« Reply #11 - Posted 2003-01-05 07:37:24 »

I agree with Abuse, the DirectX should handle the cleaning up stuff for the application (j2se in this case). Unfortunately, in some cases it really doesn't (especially on Windows9x/ME). Haven't seen this on Win2K, though.

Try a test: make sure your app releases all (accelerated) images on exit (you can even release allocated vram yourself by calling flush() method on your Volatile and accelerated images), and see if it improves the situation.
Offline Abuse

JGO Coder


Medals: 11


falling into the abyss of reality


« Reply #12 - Posted 2003-01-06 19:36:00 »

hey zparticle, I had some very disturbing problems last night  Cheesy

though, this was while developing an app. that doesn't even use Fullscreen exclusive! Shocked

all this app. does, is call graphicsDevice.getDisplayModes()  Shocked

after about 30-40 runs (of the application, not the method), I got something like 'Internal Exception - unable to get DisplayModes'

then, Winamp (which was playing in the background) bombed out, java promptly crashed, and ate a sack full of resources (JCreator had insufficient resource to compile Shocked)

Last night I also noticed some weird goings on under the bonnet of java.

drawing an automatic image (with bitmask transparency) onto a fullscreen exclusive mode window running in 400x300x8.
By alt tabbing away, then alt tabbing back, I managed to get an 'Internal Exception - not implemented yet'!!

Quote

java.lang.InternalError: not implemented yet
     at sun.awt.windows.Win32OffScreenSurfaceData.getRaster(Win32OffScreenSurfaceData.java:278)
     at sun.java2d.loops.OpaqueCopyAnyToArgb.Blit(CustomComponent.java:67)
     at sun.java2d.loops.GraphicsPrimitive.convertFrom(GraphicsPrimitive.java:451)
     at sun.java2d.loops.MaskBlit$General.MaskBlit(MaskBlit.java:169)
     at sun.java2d.loops.Blit$GeneralMaskBlit.Blit(Blit.java:170)
     at sun.java2d.pipe.DrawImage.blitSurfaceData(DrawImage.java:658)
     at sun.java2d.pipe.DrawImage.renderSurfaceData(DrawImage.java:386)
     at sun.java2d.pipe.DrawImage.clipAndRenderSurfaceData(DrawImage.java:364)
     at sun.java2d.pipe.DrawImage.copyImage(DrawImage.java:66)
     at sun.java2d.pipe.DrawImage.copyImage(DrawImage.java:50)
     at sun.java2d.pipe.DrawImage.copyImage(DrawImage.java:749)
     at sun.java2d.SunGraphics2D.drawImage(SunGraphics2D.java:2803)
     at sun.java2d.SunGraphics2D.drawImage(SunGraphics2D.java:2793)
     at Particle.render(Particle.java:182)
     at ParticleAnim.render(ParticleAnim.java:115)
     at ParticleAnim.run(ParticleAnim.java:231)
     at java.lang.Thread.run(Thread.java:536)


Suffice to say, the FullScreen/BufferStrategy/VolatileImage are all quite severely broken.

just for a laugh, shall we create a new Thread, and post all the different low level exceptions that we can get FullScreen/BufferStrategy/VolatileImage to throw Grin

I've already got a collection of 5 distinctly different 1s Cheesy

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

Senior Newbie




Java games rock!


« Reply #13 - Posted 2003-01-06 20:27:19 »

since FullScreen/BufferStrategy/VolatileImage is broken, what other safe way is there to get fullscreen with a backbuffer, all in VRam...?
Offline Abuse

JGO Coder


Medals: 11


falling into the abyss of reality


« Reply #14 - Posted 2003-01-06 20:35:33 »

Quote
since FullScreen/BufferStrategy/VolatileImage is broken, what other safe way is there to get fullscreen with a backbuffer, all in VRam...?


use a different api.

LWJGL has support for fullscreen  Grin

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

Senior Newbie




Java games rock!


« Reply #15 - Posted 2003-01-07 05:42:23 »

anyone else know any other ways of doing this? other than LWJGL ??
Offline Silicon_Munky

Senior Newbie




Java games rock!


« Reply #16 - Posted 2003-01-07 07:42:02 »

i thought driver 4.1.0.9 was the latest from NVidea
Offline Abuse

JGO Coder


Medals: 11


falling into the abyss of reality


« Reply #17 - Posted 2003-01-07 16:52:28 »

Quote
i thought driver 4.1.0.9 was the latest from NVidea


I stand corrected,
though I still doubt that is the cause...
(but im downloading it as I type, just incase Wink)

Make Elite IV:Dangerous happen! Pledge your backing at KICKSTARTER here! https://dl.dropbox.com/u/54785909/EliteIVsmaller.png
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.

Riven (20 views)
2014-07-29 18:09:19

Riven (13 views)
2014-07-29 18:08:52

Dwinin (12 views)
2014-07-29 10:59:34

E.R. Fleming (31 views)
2014-07-29 03:07:13

E.R. Fleming (12 views)
2014-07-29 03:06:25

pw (42 views)
2014-07-24 01:59:36

Riven (42 views)
2014-07-23 21:16:32

Riven (28 views)
2014-07-23 21:07:15

Riven (29 views)
2014-07-23 20:56:16

ctomni231 (60 views)
2014-07-18 06:55:21
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
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!