Re: [JAVA2D] A few simple Java 2D questions ...

2006-05-30 Thread Jim Graham

No, by "sub-pixel" I mean geometry which places coordinates at
fractional screen coordinates for purposes of expressing the locations
of those vertices more accurately than integers would allow.  If the
display has sub-components that are smaller than a pixel, that could be
taken advantage of during the rendering process as it is with LCD text,
but that has nothing to do with the need that some applications have to
express their geometry with sub-pixel precision.

It may not seem obvious that sub-pixel precision in geometry matters
when you are dealing with discreet pixels, but if you consider that
antialiased rendering can show sub-pixel differences by the opacity of
the pixels on the boundary of a shape, and if you consider that even
with non-antialiased rendering the location of the "jaggies" on a sloped
line will be affected by the sub-pixel location of the endpoints, you
can start to see that allowing expression of coordinates more finely
than an integer pixel location is worthwhile...

   ...jim

[EMAIL PROTECTED] wrote:

Hi Jim,

By 'sub-pixel' are you referring to the sub-pixels in LCD displays, for example?

Does this then not apply to CRT monitors?

Thanks,

D.
[Message sent by forum member 'dodger' (dodger)]

http://forums.java.net/jive/thread.jspa?messageID=116601

===
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA2D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".


===
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA2D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".


Re: [JAVA2D] Repaint flicker when mixing swing & heavyweight

2006-05-30 Thread Chris Campbell

Hi Mark,

You can probably get a more detailed answer if you ask this question
over on the javagaming.org JOGL forum, but...

Is your GLCanvas embedded within the bounds of another JComponent?
In this case, it is common to see flickering issues due to
heavyweight/lightweight mixing.  It's tough to say though without
knowing exactly how the components are laid out in your application.

You mention that your app "necessarily" contains a heavyweight; have
you looked into using GLJPanel instead?  GLJPanel allows for 100%
correct mixing of JOGL and Swing in the same app without worrying
about flickering issues, and in JDK 6 and beyond, it is fully
accelerated when the OGL-based Java 2D pipeline is enabled.

Chris

On May 26, 2006, at 5:39 PM, Mark McKay wrote:

I'm writing an application that uses JOGL, and so necessarily
contains a
heavyweight component that extends Canvas.  However, most of the
application uses Swing, including a component of my own design that
extends JComponent and has a complex repaint routine.  While my
component works properly, when I move the mouse over it when the
Canvas
is visible, it flickers rapidly between it's normal display and a
blank
rectangle of the clear color.

What can I do to stabilize my component so it doesn't flicker?

Mark McKay

==
=
To unsubscribe, send email to [EMAIL PROTECTED] and include in
the body
of the message "signoff JAVA2D-INTEREST".  For general help, send
email to
[EMAIL PROTECTED] and include in the body of the message "help".


===
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA2D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".