Skip to main content

Black rectangles on screen

10 replies [Last post]
jancarel
Offline
Joined: 2004-03-11

I'm upgrading to 1.6 and am noticing repainting glitches on some machines > some areas on the screen turn black and might or might not repaint correctly when forcing a repaint through resizing.

Phenomenon is erratic with random times in between; to be honest I'm not even sure it came with 1.6

Seen this on a few XP pro machines, one of which is my laptop with an ATI mobility graphics card.

Any ideas to get rid of this, possible causes, hints?

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
jancarel
Offline
Joined: 2004-03-11

Hello Dmitri,

I had an hour to debug this problem at home on my Dell laptop.

I was unable to upgrade the driver from the ATI web site as the software said I should upgrade this from the Dell web site.

I installed the latest video driver upgrade from the Dell web site, set the trace level as you recommended.

On startup the following was seen:

[i][W] GetFlagValues: DDraw screen locking is disabled (W2K, XP+)
InitDirectX
CreateDevice: lpGUID=0x90cfa0 hMon=0x10001
DDSetupDevice
DDraw::CreateDDPrimarySurface: back-buffers=0[/i]

After opening a few internal frames, the black rectangle problem was seen. Unfortunately no console output.

I will be going back to setting the Dsun.java2d.noddraw flag to true which had fixed the problem.

FYI this graphics card is the ATI Radeon Mobility 300 on my Dell laptop, though I have seen the phenomenon on other machines with different graphics configurations. I have set the Dsun.java2d.noddraw flag to true on these machines too.

I am sure the phenomenon is due to buggy driver-direct draw interaction.

Thank you again for your help.

JanCarel

jancarel
Offline
Joined: 2004-03-11

> Could you try running your app with
> 1. -Dswing.bufferPerWindow=false
> 2. -Dsun.java2d.noddraw=true
>
> See if any of these flags help.
Hi Dmitri

I started out with the [i]-Dsun.java2d.noddraw=true[/i] switch and this seems to have gotten rid of the problem. If I set this to false, the phenomenon will come back once in a while.

Thank you for your suggestions.

Dmitri Trembovetski

Hi,

thanks for following up. Glad that you at least
have a workaround.

Is your video driver up to date? The mobility chips
are typically a bit behind in drivers versions,
unfortunately.

Could you please try one more thing?
Without the noddraw flag, set the following env.
variable: 'set J2D_TRACE_LEVEL=3', and then
run the application (from the same cmd).
See if you have any output on the console when it
starts misbehaving.

Thanks,
Dmitri
Java2D Team

On Mon, Feb 05, 2007 at 02:01:37AM -0800, java2d@javadesktop.org wrote:
> > Could you try running your app with
> > 1. -Dswing.bufferPerWindow=false
> > 2. -Dsun.java2d.noddraw=true
> >
> > See if any of these flags help.
> Hi Dmitri
>
> I started out with the [i]-Dsun.java2d.noddraw=true[/i] switch and this seems to have gotten rid of the problem. If I set this to false, the phenomenon will come back once in a while.
>
> Thank you for your suggestions.
> [Message sent by forum member 'jancarel' (jancarel)]
>
> http://forums.java.net/jive/thread.jspa?messageID=201784
>
> ===========================================================================
> To unsubscribe, send email to listserv@java.sun.com and include in the body
> of the message "signoff JAVA2D-INTEREST". For general help, send email to
> listserv@java.sun.com and include in the body of the message "help".

===========================================================================
To unsubscribe, send email to listserv@java.sun.com and include in the body
of the message "signoff JAVA2D-INTEREST". For general help, send email to
listserv@java.sun.com and include in the body of the message "help".

jancarel
Offline
Joined: 2004-03-11

Hi Dmitri,

Will follow up, you'll have to allow me some time though as I have some other machines which are doing this too and the problem is erratic.

I deploy java apps in my company on different hardware and I just want them to run without problems. If we need to do this without hardware acceleration, no problem. The java apps are really fast on the newest jdk's!

Be assured I appreciate your work; there is so much hardware around and sometimes we can't even make HP printers to print from plain vanilla Windows apps.

jancarel
Offline
Joined: 2004-03-11

Hello Dmitri

> Could you try running your app with
> 1. -Dswing.bufferPerWindow=false
> 2. -Dsun.java2d.noddraw=true
>
> See if any of these flags help.

I will. Thanks for the input.

Dmitri Trembovetski

Hello,

what application you're seeing this with?
Can you reproduce this with the jdk demos (like SwingSet2)?

Do you have any non-default flags/properties set (like any
of sun.java2d.* properties)?

Thanks,
Dmitri
Java2D Team

On Tue, Jan 16, 2007 at 01:09:51PM -0800, java2d@javadesktop.org wrote:
> I'm upgrading to 1.6 and am noticing repainting glitches on some machines > some areas on the screen turn black and might or might not repaint correctly when forcing a repaint through resizing.
>
> Phenomenon is erratic with random times in between; to be honest I'm not even sure it came with 1.6
>
> Seen this on a few XP pro machines, one of which is my laptop with an ATI mobility graphics card.
>
> Any ideas to get rid of this, possible causes, hints?
> [Message sent by forum member 'jancarel' (jancarel)]
>
> http://forums.java.net/jive/thread.jspa?messageID=195159
>
> ===========================================================================
> To unsubscribe, send email to listserv@java.sun.com and include in the body
> of the message "signoff JAVA2D-INTEREST". For general help, send email to
> listserv@java.sun.com and include in the body of the message "help".

===========================================================================
To unsubscribe, send email to listserv@java.sun.com and include in the body
of the message "signoff JAVA2D-INTEREST". For general help, send email to
listserv@java.sun.com and include in the body of the message "help".

jancarel
Offline
Joined: 2004-03-11

Hi Dmitri,

> what application you're seeing this with?
In house MRP/CRM applications, very standard Swing, JGoodies looks.

> Can you reproduce this with the jdk demos (like
> ke SwingSet2)?
I haven't tried SwingSet, but my NetBeans 5.0 does this once in a while so I don't think it's the app.

> Do you have any non-default flags/properties set
> et (like any
> of sun.java2d.* properties)?
No properties set at all, just xmx and xms command switches.

Dmitri Trembovetski

Hello,

thanks for the info.

Could you try running your app with
1. -Dswing.bufferPerWindow=false
2. -Dsun.java2d.noddraw=true

See if any of these flags help.

Also, here's a desktop java troubleshooting guide:
http://java.sun.com/javase/6/webnotes/trouble/TSG-Desktop/html/toc.html

Thanks,
Dmitri

On Tue, Jan 16, 2007 at 11:46:06PM -0800, java2d@javadesktop.org wrote:
> Hi Dmitri,
>
> > what application you're seeing this with?
> In house MRP/CRM applications, very standard Swing, JGoodies looks.
>
> > Can you reproduce this with the jdk demos (like
> > ke SwingSet2)?
> I haven't tried SwingSet, but my NetBeans 5.0 does this once in a while so I don't think it's the app.
>
> > Do you have any non-default flags/properties set
> > et (like any
> > of sun.java2d.* properties)?
> No properties set at all, just xmx and xms command switches.
> [Message sent by forum member 'jancarel' (jancarel)]
>
> http://forums.java.net/jive/thread.jspa?messageID=195299
>
> ===========================================================================
> To unsubscribe, send email to listserv@java.sun.com and include in the body
> of the message "signoff JAVA2D-INTEREST". For general help, send email to
> listserv@java.sun.com and include in the body of the message "help".

===========================================================================
To unsubscribe, send email to listserv@java.sun.com and include in the body
of the message "signoff JAVA2D-INTEREST". For general help, send email to
listserv@java.sun.com and include in the body of the message "help".

David Eisner

Dmitri Trembovetski wrote:
> Also, here's a desktop java troubleshooting guide:
> http://java.sun.com/javase/6/webnotes/trouble/TSG-Desktop/html/toc.html
>

I didn't know about this. What a great resource! Thanks.

-David

===========================================================================
To unsubscribe, send email to listserv@java.sun.com and include in the body
of the message "signoff JAVA2D-INTEREST". For general help, send email to
listserv@java.sun.com and include in the body of the message "help".

jancarel
Offline
Joined: 2004-03-11

Some additional comment I forgot to include in the original post:

the repainting glitches happen in programs with a MDI interface; that is with a desktop and JInternalFrame's.

I have never seen this in another app we use which is in SDI mode, no internal frames and just running in one panel with a split pane.