Newt canvas working in Jzy3d

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

Newt canvas working in Jzy3d

Martin
Hi,
I just would like to provide positive feedback concerning Newt canvas that has been easy to add to Jzy3d (with little help from Julien, thanks). Mouse and keyboard controllers work fine as well, so now you can call:
new Chart("newt")
to have a newt canvas to display your chart.

https://github.com/jzy3d/jzy3d-api/blob/master/src/api/org/jzy3d/plot3d/rendering/canvas/CanvasNewt.java

Only on the trunk, available for download for next version (1.0)

I just noticed the following System.err.println when closing the newt canvas... looks like a forgotten debug.
X11Util.Display: Shutdown (close open / pending Displays: false, open (no close attempt): 2/2, pending (not closed, marked uncloseable): 0)
X11Util: Open X11 Display Connections: 2
X11Util: Open[0]: NamedX11Display[:0, 0x9c5a458, refCount 1, unCloseable false]
X11Util: Open[1]: NamedX11Display[:0, 0x9ca0c08, refCount 1, unCloseable false]
Reply | Threaded
Open this post in threaded view
|

Re: Newt canvas working in Jzy3d

Sven Gothel
Administrator
On 10/04/2012 09:53 PM, Martin [via jogamp] wrote:
> Hi,
> I just would like to provide positive feedback concerning Newt canvas that has
> been easy to add to Jzy3d (with little help from Julien, thanks). Mouse and
> keyboard controllers work fine as well, so now you can call:
> new Chart("newt")
> to have a newt canvas to display your chart.

Sweet, thank you!

>
> https://github.com/jzy3d/jzy3d-api/blob/master/src/api/org/jzy3d/plot3d/rendering/canvas/CanvasNewt.java
>
> Only on the trunk, available for download for next version (1.0)
>
> I just noticed the following System.err.println when closing the newt
> canvas... looks like a forgotten debug.
> X11Util.Display: Shutdown (close open / pending Displays: false, open (no
> close attempt): 2/2, pending (not closed, marked uncloseable): 0)
> X11Util: Open X11 Display Connections: 2
> X11Util: Open[0]: NamedX11Display[:0, 0x9c5a458, refCount 1, unCloseable false]
> X11Util: Open[1]: NamedX11Display[:0, 0x9ca0c08, refCount 1, unCloseable false]
Nope :)
This is a reminder for _you_ to close resources you have opened.

"open (no close attempt): 2/2" states that there are 2 X11 Display connections
open (probably one NEWT Window (GLWindow) with it's 2 X11 Display connections
for event polling and rendering.

If you would call glWindow.dispose() all would be fine.

If you close it but use the ATI proprietary driver,
you will see something similar but different:
"open (no close attempt): 0/0, pending (not closed, marked uncloseable): 2/2"

Meaning close has been issued by the user,
but JOGL has marked them uncloseable.
This is a workaround for an ATI driver bug.

~Sven



signature.asc (907 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Newt canvas working in Jzy3d

Martin
Sven Gothel wrote
This is a reminder for _you_ to close resources you have opened.
Thanks for attention :)
A warning message suggesting the action to do (e.g. "call GLWindow.dispose() to avoid this warning") would be great for unexperienced users of newt.

Sven Gothel wrote
If you would call glWindow.dispose() all would be fine.
Can't find a dispose() method on GLWindow neither GLPBuffer, but a destroy() method. Is that equivalent?


Sven Gothel wrote
If you close it but use the ATI proprietary driver,
you will see something similar but different:
"open (no close attempt): 0/0, pending (not closed, marked uncloseable): 2/2"

Meaning close has been issued by the user,
but JOGL has marked them uncloseable.
This is a workaround for an ATI driver bug.
Nice to know you warn without failing :)