Login  Register

Re: handling high resolution Mac displays

Posted by Sven Gothel on Jun 14, 2012; 12:43am
URL: https://forum.jogamp.org/handling-high-resolution-Mac-displays-tp4025208p4025216.html

On 06/13/2012 10:20 PM, Andy Skinner [via jogamp] wrote:
> Is anyone working on getting JOGL to work with the new high resolution
> displays on the Mac?

Even though I work w/ a high resolution big display [2560x1440],
it's not Apple but an affordable Samsung monitor.
Sorry, couldn't help putting in more diversity here :)

>
> https://developer.apple.com/library/mac/#documentation/GraphicsAnimation/Conceptual/HighResolutionOSX/CapturingScreenContents/CapturingScreenContents.html
>
> Looks like you have to opt in and change some things that handle pixel
> coordinates.  If you don't, you render at a lower resolution and duplicate
> pixels to the high res display.
>

I see what you mean ..
so just b/c they bound the high-resolution display
to a low performance GPU they use a low resolution backing frame buffer ?
Maybe I don't get it really.

+++

The JOGL/OSX impl. uses pixel coordinates for the low level
NSView, NSOpenGL* things - so does NEWT's OSX impl.

Our offscreen rendering code (CALayer/NSOpenGLLayer)
used for Browser/Applet OSX >= 10.6.8 as well
as for OSX >= 10.6.8 && OpenJDK >= 7
passes the pixel size of the desired framebuffer
down to our impl. - hence it should be 1 : 1 pixel.

The onscreen rendering code (NSView/NSOpenGLContext)
simple attaches NSView and NSOpenGLContext,
hence it uses the information provided by NSView.
I assume this should be the pixel size as well.

+++

If we would use another metric, i.e. millimeters,
I could understand the issue - but we don't, we use pixels.

In JOGL, especially NEWT and it's Screen/Monitor information (DPI, ..),
one would take care of monitor aspect ratio and scaling
as described here:

http://jogamp.org/git/?p=jogl.git;a=blob;f=src/test/com/jogamp/opengl/test/junit/jogl/glsl/TestRulerNEWT01.java;hb=HEAD#l110

If you use AWT, you would need to use AWT's
mechanism to query the Screen/Monitor information (DPI, ..),
which I don't know.

+++

So I hope the system is just doing what we ask it to do,
but I am not quite sure - see above.

Would be nice if somebody with such a machine (you?)
runs some tests. Our simple JOGL tests in debug mode
as described in our Wiki FAQ Bugreport should be sufficient.

http://forum.jogamp.org/Problem-with-GLProfile-and-jogl2-rc2-td3447491.html#a3447546

Thank you, Sven

> thanks
> andy
>


signature.asc (910 bytes) Download Attachment