| |
|
| java.lang.Object java.awt.GraphicsConfigTemplate javax.media.j3d.GraphicsConfigTemplate3D
GraphicsConfigTemplate3D | public class GraphicsConfigTemplate3D extends GraphicsConfigTemplate (Code) | | This class is used to obtain a valid GraphicsConfiguration that can be used by Java 3D.
A user instantiates one of these objects and then sets all
non-default attributes as desired. The getBestConfiguration()
method in the GraphicsDevice class is then called with this
GraphicsConfigTemplate and the "best" GraphicsConfiguration is returned. The "best"
GraphicsConfiguration means that this GraphicsConfiguration is supported and it
meets or exceeds what was requested in the GraphicsConfigTemplate.
Null is returned if no such "best" GraphicsConfiguration is found.
See Also: GraphicsConfigTemplate See Also: GraphicsDevice See Also: GraphicsConfiguration |
Constructor Summary | |
public | GraphicsConfigTemplate3D() Constructs a GraphicsConfigTemplate3D object with default parameters. |
doubleBuffer | int doubleBuffer(Code) | | |
sceneAntialiasing | int sceneAntialiasing(Code) | | |
stencilSize | int stencilSize(Code) | | |
threadWaiting | static volatile boolean threadWaiting(Code) | | |
GraphicsConfigTemplate3D | public GraphicsConfigTemplate3D()(Code) | | Constructs a GraphicsConfigTemplate3D object with default parameters.
The default values are as follows:
depthSize : 16
doubleBuffer : REQUIRED
sceneAntialiasing : UNNECESSARY
stereo : UNNECESSARY
redSize : 2
greenSize : 2
blueSize : 2
stencilSize : 0
|
getBestConfiguration | public GraphicsConfiguration getBestConfiguration(GraphicsConfiguration[] gc)(Code) | | Implement the abstract function of getBestConfiguration() in GraphicsConfigTemplate.
Usually this function is not directly called by the user. It is
implicitly called by getBestConfiguration() in GraphicsDevice.
The method getBestConfiguration() in GraphicsDevice will return whatever this function returns.
This function will return the "best" GraphicsConfiguration. The "best" GraphicsConfiguration
means that this GraphicsConfiguration is supported and it meets or exceeds what was requested in the
GraphicsConfigTemplate. If no such "best" GraphicsConfiguration is found, null is returned.
Parameters: gc - the array of GraphicsConfigurations to choose from the best GraphicsConfiguration See Also: GraphicsDevice |
getBlueSize | public int getBlueSize()(Code) | | Retrieves the number of blue bits requested by this template.
the current value of the blueSize attribute. |
getDepthSize | public int getDepthSize()(Code) | | Retrieves the size of the depth buffer.
the current value of the depthSize attribute |
getDoubleBuffer | public int getDoubleBuffer()(Code) | | Retrieves the double buffering value.
the current value of the doubleBuffer attribute |
getGraphicsConfigFeatures | static void getGraphicsConfigFeatures(Canvas3D c)(Code) | | Set the stereo/doubleBuffer/sceneAntialiasingAccum
and hasSceneAntialiasingMultiSamples flags in Canvas3D
|
getGreenSize | public int getGreenSize()(Code) | | Retrieves the number of green bits requested by this template.
the current value of the greenSize attribute. |
getRedSize | public int getRedSize()(Code) | | Retrieves the number of red bits requested by this template.
the current value of the redSize attribute. |
getSceneAntialiasing | public int getSceneAntialiasing()(Code) | | Retrieves the scene antialiasing value.
the current value of the scene antialiasing attribute. |
getStencilSize | public int getStencilSize()(Code) | | Retrieves the size of the stencil buffer.
the current value of the stencilSize attribute since: Java 3D 1.4 |
getStereo | public int getStereo()(Code) | | Retrieves the stereo value.
the current value of the stereo attribute. |
isGraphicsConfigSupported | public boolean isGraphicsConfigSupported(GraphicsConfiguration gc)(Code) | | Returns a boolean indicating whether or not the given
GraphicsConfiguration can be used to create a drawing
surface that can be rendered to.
Parameters: gc - the GraphicsConfiguration object to test true if this GraphicsConfiguration objectcan be used to create surfaces that can be rendered to,false if the GraphicsConfiguration can not be usedto create a drawing surface usable by this API. |
runMonitor | static void runMonitor(int action)(Code) | | |
setBlueSize | public void setBlueSize(int value)(Code) | | Sets the number of blue bits required. This is the minimum requirement.
If no GraphicsConfiguration is found that meets or
exceeds this minimum requirement, null will be returned in
getBestConfiguration().
Parameters: value - the value to set this field to |
setDepthSize | public void setDepthSize(int value)(Code) | | Sets the depth buffer size requirement. This is the minimum requirement.
If no GraphicsConfiguration is found that meets or
exceeds this minimum requirement, null will be returned in
getBestConfiguration().
Parameters: value - the value to set this field to |
setDoubleBuffer | public void setDoubleBuffer(int value)(Code) | | Sets the double buffering requirement. It should be
GraphicsConfigTemplate.REQUIRED, GraphicsConfigTemplate.PREFERRED,
or GraphicsConfigTemplate.UNNECESSARY.
If an invalid value is passed in, it is ignored.
If the value of double buffering is
GraphicsConfigTemplate.REQUIRED, and no GraphicsConfiguration is found
that meets this requirement, null will be returned in getBestConfiguration().
Parameters: value - the value to set this field to |
setGreenSize | public void setGreenSize(int value)(Code) | | Sets the number of green bits required. This is the minimum requirement.
If no GraphicsConfiguration is found that meets or
exceeds this minimum requirement, null will be returned in
getBestConfiguration().
Parameters: value - the value to set this field to |
setQueryProps | static void setQueryProps(Canvas3D c)(Code) | | Set the queryProperties() map in Canvas3D
|
setRedSize | public void setRedSize(int value)(Code) | | Sets the number of red bits required. This is the minimum requirement.
If no GraphicsConfiguration is found that meets or
exceeds this minimum requirement, null will be returned in
getBestConfiguration().
Parameters: value - the value to set this field to |
setSceneAntialiasing | public void setSceneAntialiasing(int value)(Code) | | Sets the scene antialiasing requirement. It should be
GraphicsConfigTemplate.REQUIRED, GraphicsConfigTemplate.PREFERRED,
or GraphicsConfigTemplate.UNNECESSARY. If an invalid value
is passed in, it is ignored. If the value of scene antialiasing is
GraphicsConfigTemplate.REQUIRED, and no GraphicsConfiguration is found
that meets this requirement, null will be returned in getBestConfiguration().
Parameters: value - the value to set this field to |
setStencilSize | public void setStencilSize(int value)(Code) | | Sets the stencil buffer size requirement.
This is the minimum requirement.
If no GraphicsConfiguration is found that meets or
exceeds this minimum requirement, null will be returned in
getBestConfiguration().
Parameters: value - the value to set this field to since: Java 3D 1.4 |
setStereo | public void setStereo(int value)(Code) | | Sets the stereo requirement. It should be
GraphicsConfigTemplate.REQUIRED, GraphicsConfigTemplate.PREFERRED,
or GraphicsConfigTemplate.UNNECESSARY. If an invalid value
is passed in, it is ignored. If the value of stereo requirement is
GraphicsConfigTemplate.REQUIRED, and no GraphicsConfiguration is found
that meets this requirement, null will be returned in getBestConfiguration().
Parameters: value - the value to set this field to |
toString | public String toString()(Code) | | Returns a string representation of this object.
a string representation of this object. |
|
|
|