Re: Java 3D in headless mode
Posted by
philjord on
Aug 18, 2017; 12:44am
URL: https://forum.jogamp.org/Java-3D-in-headless-mode-tp4038145p4038149.html
Avi,
Unfortunately the Headless mode for Java3D doesn't allow you to actually do any Java3D work.
So the change you saw go in was based of a discussion here:
http://forum.jogamp.org/Using-Java-3D-scene-tree-in-a-headless-environment-td4026340.htmlWhere the users wanted to be able to create a full Java3D scenegraph, but not actually run any Java3D rendering work at all.
So there is no requirement for a Canvas3D in that configuration, and because Canvas3D extends java.awt.Canvas and does it's work on an addNotify call you won't be able to do anything with it at all, therefore there is no point in constructing it.
This is part of the reason why GraphicsConfiguration has protected constructors that can only be instantiated through factories, because unless you have a full bodied Graphics Environment you shouldn't try to use a onscreen element like Canvas3D.
If you supply some more thoughts about what you want to do in the "batch" mode with your Java3D scene we might be able to suggest some ideas. But note you won't be able do any 3d rendering with the graphics card, unless by headless you simply mean "no screen attached", which is not quite the same thing.
Thanks,
Phil.