Newt: Fullscreen and Undecorated not working on Windows

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Newt: Fullscreen and Undecorated not working on Windows

Marc@56K
Hi,

I'm using jogl-v2.0-rc2 on Windows7 x64 with a 32Bit JDK and I want to create a fullscreen Newt-Window:

public class NewtFullscreenBug implements GLEventListener, WindowListener {
    /**
     * @param args
     */
    public static void main(String[] args) {
        GLProfile.initSingleton(true);
        new NewtFullscreenBug();
    }

    public NewtFullscreenBug() {
        GLWindow window = GLWindow.create(getGLCapabilities());
        window.setAutoSwapBufferMode(false);
        window.setSize(800, 600);
        window.addGLEventListener(this);
        window.addWindowListener(this);        
       
        window.setUndecorated(true); //not working
        window.setFullscreen(true); //not working
               
        window.setVisible(true);

        while (true)
            window.display();
    }

    @Override
    public void display(GLAutoDrawable arg0) {

    }

    @Override
    public void dispose(GLAutoDrawable arg0) {}

    public GLCapabilities getGLCapabilities() {
        GLProfile glp = GLProfile.get("GL2GL3");
        return new GLCapabilities(glp);
    }
...

setFullscreen and setUndecorated have no effect to the window. It still has a border an is not maximized to fullscreen.

p.s. I'm wondering why so many features of the Newt-Window which already worked on JOGL 2.0 Beta 10 are now so buggy on windows. Was the Newt-Window completely redeveloped after this JOGL-version or what is the reason for this fact?
Reply | Threaded
Open this post in threaded view
|

Re: Newt: Fullscreen and Undecorated not working on Windows

void-pointer
This post was updated on .
I am having this problem also, and observed the same results when I repeated the test on Windows 7, 64-bit, using jogl-2.0-b23-20110303. I looked through the WindowImpl.java and WindowsWindow.c classes but I do not know much about operating system windowing APIs, so I will list what happened so far.

The following causes the system to hang/freeze while I frantically try to kill the process. Also, there is also no icon for the window and it is no longer accessible.

<code>
...
GLWindow window = GLWindow.create(new GLCapabilities(GLProfile.getDefault()));
window.setAutoSwapBufferMode(false);
window.setSize(800, 600);
window.addGLEventListener(this);
window.setVisible(true);
window.setFullscreen(true);
...
</code>

If the full-screen and decoration routines are also resulting in problems, then one would expect that the issue arises from something that both FullScreenActionImpl and DecorationActionImpl (both in WindowImpl) have in common. Now, this is just an educated guess since I do not know much about system-dependent windowing, but perhaps this is caused by either setVisibleImpl or reconfigureWindowImpl. This eventually boils down to the Java_jogamp_newt_windows_WindowsWindow_setVisible0 and Java_jogamp_newt_windows_WindowsWindow_reconfigureWindow0 functions in WindowsWindow.c. Beyond that, if I am right up to this point at all, I am not too sure as to what could be causing the problem - perhaps Mr. Bien would have a better idea. Marc@56k mentioned that this worked correctly in previous builds, so perhaps that would help also.

If you would like me to perform any other tests or think that I should change something that I did, I would be happy to comply. Thank you for your time and I hope this issue gets fixed soon.
Reply | Threaded
Open this post in threaded view
|

Re: Newt: Fullscreen and Undecorated not working on Windows

gouessej
Administrator
In reply to this post by Marc@56K
Is it reproducible on Linux?
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: Newt: Fullscreen and Undecorated not working on Windows

Rami Santina
Administrator
Hi,

Did you run the unit test regarding Fullscreen/ScreenMode change, TestScreenMode01NEWT mainly.

Can you please run it and post the result here.



Cheers
Rami
Reply | Threaded
Open this post in threaded view
|

Re: Newt: Fullscreen and Undecorated not working on Windows

Sven Gothel
Administrator
In reply to this post by Marc@56K
On Saturday, March 12, 2011 19:14:53 Marc@56K [via jogamp] wrote:
>
> Hi,
>
> I'm using jogl-v2.0-rc2 on Windows7 x64 with a 32Bit JDK and I want to
> create a fullscreen Newt-Window:
>

same on linux, ie bug in this case, changing undecorated and fullscreen before visibility.

will fix that - thx a lot

~Sven


> public class NewtFullscreenBug implements GLEventListener, WindowListener {
>     /**
>      * @param args
>      */
>     public static void main(String[] args) {
>         GLProfile.initSingleton(true);
>         new NewtFullscreenBug();
>     }
>
>     public NewtFullscreenBug() {
>         GLWindow window = GLWindow.create(getGLCapabilities());
>         window.setAutoSwapBufferMode(false);
>         window.setSize(800, 600);
>         window.addGLEventListener(this);
>         window.addWindowListener(this);        
>        
>         window.setUndecorated(true); //not working
>         window.setFullscreen(true); //not working
>                
>         window.setVisible(true);
>
>         while (true)
>             window.display();
>     }
>
>     @Override
>     public void display(GLAutoDrawable arg0) {
>
>     }
>
>     @Override
>     public void dispose(GLAutoDrawable arg0) {}
>
>     public GLCapabilities getGLCapabilities() {
>         GLProfile glp = GLProfile.get("GL2GL3");
>         return new GLCapabilities(glp);
>     }
> ...
>
> setFullscreen and setUndecorated have no effect to the window. It still has
> a border an is not maximized to fullscreen.
>
> p.s. I'm wondering why so many features of the Newt-Window which already
> worked on JOGL 2.0 Beta 10 are now so buggy on windows. Was the Newt-Window
> completely redeveloped after this JOGL-version or what is the reason for
> this fact?
>
>
> _______________________________________________
> If you reply to this email, your message will be added to the discussion below:
> http://forum.jogamp.org/Newt-Fullscreen-and-Undecorated-not-working-on-Windows-tp2671034p2671034.html
> To start a new topic under jogl, email [hidden email]
> To unsubscribe from jogl, visit
health & wealth
mailto:
[hidden email] ; http://jausoft.com
land : +49 (471) 4707742 ; cell: +49 (151) 28145941
Timezone CET: PST+9, EST+6, UTC+1