The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

import-bot (20211) [Avatar] Offline
[Originally posted by ymkwah]

I have an error message appearing after clicking a .bat file which has been
included in each example directory.

WARNING: Canvas3D constructed with a null GraphicsConfiguration.
Sound bank not set.

Could anyone explain this to me. Thanks.
import-bot (20211) [Avatar] Offline
Re: GraphicsConfiguration
[Originally posted by author]

Earlier versions of Java 3D did not complain when a null graphics config was
used (which is what the 3D UI software does) when creating a new Canvas3D.
They just silently used the default one. Later versions started complaining
when the constructor argument was left null. Good practice would be to use
the preferred config for your system rather than using the default. Below is
the code used by the SimpleUniverse class in the Sun utilities for obtaining
the preferred configuration.


* Finds the preferred <code>GraphicsConfiguration</code> object
* for the system. This object can then be used to create the
* Canvas3D objet for this system.
* @return The best <code>GraphicsConfiguration</code> object for
* the system.
public static GraphicsConfiguration getPreferredConfiguration() {
GraphicsConfigTemplate3D template = new GraphicsConfigTemplate3D();
String stereo;

// Check if the user has set the Java 3D stereo option.
// Getting the system properties causes appletviewer to fail with a
// security exception without a try/catch.

stereo = (String)
new {
public Object run() {
return System.getProperty("j3d.stereo");

// update template based on properties.
if (stereo != null) {
if (stereo.equals("REQUIRED"))
else if (stereo.equals("PREFERRED"))

// Return the GraphicsConfiguration that best fits our needs.
return GraphicsEnvironment.getLocalGraphicsEnvironment().