public class Component3DManager
extends java.lang.Object
Canvas3D instantiations and Java 3D error listeners.
 Note: this class is compatible with Java 3D 1.3 at runtime but requires Java 3D 1.5 to compile.| Modifier and Type | Class and Description | 
|---|---|
| static interface  | Component3DManager.RenderingErrorObserverAn observer that receives error notifications in Java 3D. | 
| static interface  | Component3DManager.RenderingObserverAn observer that receives notifications during the different steps
 of the loop rendering a canvas 3D. | 
| Modifier and Type | Method and Description | 
|---|---|
| int | getDepthSize()Returns the depth bits size of the Z-buffer. | 
| static Component3DManager | getInstance()Returns an instance of this singleton. | 
| javax.media.j3d.Canvas3D | getOffScreenCanvas3D(int width,
                    int height)Returns a new off screen  canva3Dat the given size. | 
| java.awt.image.BufferedImage | getOffScreenImage(javax.media.j3d.View view,
                 int width,
                 int height)Returns an image at the given size of the 3D  view. | 
| javax.media.j3d.Canvas3D | getOnscreenCanvas3D()Returns a new on screen  canva3Dinstance. | 
| javax.media.j3d.Canvas3D | getOnscreenCanvas3D(Component3DManager.RenderingObserver renderingObserver)Returns a new on screen  canva3Dinstance which rendering will be observed
 with the given rendering observer. | 
| javax.media.j3d.Canvas3D | getOnscreenCanvas3D(java.awt.GraphicsConfiguration deviceConfiguration,
                   Component3DManager.RenderingObserver renderingObserver)Returns a new on screen  canva3Dinstance which rendering will be observed
 with the given rendering observer. | 
| Component3DManager.RenderingErrorObserver | getRenderingErrorObserver()Returns the current rendering error listener bound to  VirtualUniverse. | 
| boolean | isOffScreenImageSupported()Returns  trueif offscreen is supported in Java 3D on user system. | 
| void | setRenderingErrorObserver(Component3DManager.RenderingErrorObserver observer)Sets the current rendering error listener bound to  VirtualUniverse. | 
public int getDepthSize()
public static Component3DManager getInstance()
public void setRenderingErrorObserver(Component3DManager.RenderingErrorObserver observer)
VirtualUniverse.public Component3DManager.RenderingErrorObserver getRenderingErrorObserver()
VirtualUniverse.public boolean isOffScreenImageSupported()
true if offscreen is supported in Java 3D on user system.
 Will always return false if com.eteks.sweethome3d.j3d.checkOffScreenSupport
 system is equal to false. By default, com.eteks.sweethome3d.j3d.checkOffScreenSupport
 is equal to true.public javax.media.j3d.Canvas3D getOnscreenCanvas3D()
canva3D instance. The returned canvas 3D will be associated
 with the graphics configuration of the default screen device.javax.media.j3d.IllegalRenderingStateException - if the canvas 3D couldn't be created.public javax.media.j3d.Canvas3D getOnscreenCanvas3D(Component3DManager.RenderingObserver renderingObserver)
canva3D instance which rendering will be observed
 with the given rendering observer. The returned canvas 3D will be associated with the
 graphics configuration of the default screen device.renderingObserver - an observer of the 3D rendering process of the returned canvas.
            Caution: The methods of the observer will be called in 3D rendering loop thread.javax.media.j3d.IllegalRenderingStateException - if the canvas 3D couldn't be created.public javax.media.j3d.Canvas3D getOnscreenCanvas3D(java.awt.GraphicsConfiguration deviceConfiguration,
                                                    Component3DManager.RenderingObserver renderingObserver)
canva3D instance which rendering will be observed
 with the given rendering observer.renderingObserver - an observer of the 3D rendering process of the returned canvas.
            Caution: The methods of the observer will be called in 3D rendering loop thread.javax.media.j3d.IllegalRenderingStateException - if the canvas 3D couldn't be created.public javax.media.j3d.Canvas3D getOffScreenCanvas3D(int width,
                                                     int height)
canva3D at the given size.javax.media.j3d.IllegalRenderingStateException - if the canvas 3D couldn't be created.
    To avoid this exception, call isOffScreenImageSupported() first.public java.awt.image.BufferedImage getOffScreenImage(javax.media.j3d.View view,
                                                      int width,
                                                      int height)
view.
 This image is created with an off screen canvas.javax.media.j3d.IllegalRenderingStateException - if the image couldn't be created.
                        
© Copyright 2024 Space Mushrooms
                            
Distributed under GNU General Public License