title: UnsupportedNodeException: Request for a node that is not part of the specified profile and components for this stream: viewpoint
body: <p>I've been stuck on the same problem for some time and I don't know why I get the following Run-time error when I run my project.</p>
  
  <pre><code>Exception in thread "main" org.web3d.vrml.lang.UnsupportedNodeException: Request for a node that is not part of the specified profile and components for this stream: viewpoint
      at org.web3d.vrml.renderer.DefaultNodeFactory.createVRMLNode(DefaultNodeFactory.java:730)
      at org.web3d.vrml.renderer.ogl.OGLMainSceneBuilder.startNode(OGLMainSceneBuilder.java:147)
      at org.web3d.vrml.renderer.ogl.OGLVRMLSceneBuilder.startNode(OGLVRMLSceneBuilder.java:514)
      at org.web3d.x3d.jaxp.X3DSAVAdapter.startElement(X3DSAVAdapter.java:830)
      at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:509)
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:1364)
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2787)
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:606)
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510)
      at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:848)
      at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:777)
      at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)
      at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213)
      at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:643)
      at org.web3d.parser.GeneralisedReader.parse(GeneralisedReader.java:261)
      at org.xj3d.impl.core.loading.DefaultWorldLoader.loadNow(DefaultWorldLoader.java:156)
      at org.xj3d.impl.core.loading.DefaultWorldLoader.loadNow(DefaultWorldLoader.java:203)
      at org.web3d.vrml.scripting.browser.X3DCommonBrowser.createX3DFromURL(X3DCommonBrowser.java:264)
      at org.web3d.vrml.scripting.external.sai.SAIBrowser.createX3DFromURL(SAIBrowser.java:843)
      at xj3dtest.Xj3DTest.&lt;init&gt;(Xj3DTest.java:50)
      at xj3dtest.Xj3DTest.main(Xj3DTest.java:56)
  </code></pre>
  
  <p>My <code>Java</code> code for this is</p>
  
  <pre><code>package xj3dtest;
  
  import java.awt.BorderLayout;
  import java.awt.Container;
  import static java.lang.Boolean.TRUE;
  import javax.swing.JFrame;
  import org.web3d.x3d.sai.Browser;
  import org.web3d.x3d.sai.BrowserFactory;
  import org.web3d.x3d.sai.X3DComponent;
  import org.web3d.x3d.sai.X3DScene;
  import java.util.HashMap;
  
  public class Xj3DTest extends JFrame {
  
      public Xj3DTest(String title) {
  
          super(title);
  
          setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
  
          // Setup browser parameters
          HashMap requestedParameters=new HashMap();
          requestedParameters.put("Antialiased",TRUE);
          requestedParameters.put("TextureQuality","medium");
          requestedParameters.put("PrimitiveQuality","medium");
          requestedParameters.put("Xj3D_InterfaceType","SWING");
          requestedParameters.put("Xj3D_NavbarShown",TRUE);
          requestedParameters.put("Xj3D_NavbarPosition","TOP");
          requestedParameters.put("Xj3D_LocationShown",TRUE);
          requestedParameters.put("Xj3D_LocationPosition","TOP");
          requestedParameters.put("Xj3D_LocationReadOnly",TRUE);
          requestedParameters.put("Xj3D_ShowConsole",TRUE);
          requestedParameters.put("Xj3D_OpenButtonShown",TRUE);
          requestedParameters.put("Xj3D_ReloadButtonShown",TRUE);
          requestedParameters.put("Xj3D_StatusBarShown",TRUE);
          requestedParameters.put("Xj3D_FPSShown",TRUE);
          requestedParameters.put("Xj3D_ContentDirectory","CurrentDirectory");
          requestedParameters.put("Xj3D_AntialiasingQuality","low");
          requestedParameters.put("Xj3D_Culling_Mode", "frustum");
  
          System.setProperty("x3d.sai.factory.class", "org.xj3d.ui.awt.browser.ogl.X3DOGLBrowserFactoryImpl");
          X3DComponent x3dComponent = BrowserFactory.createX3DComponent(requestedParameters);
  
          Browser browser = x3dComponent.getBrowser();
  
          Container cp = getContentPane();
          cp.setLayout(new BorderLayout());
          cp.add((javax.swing.JPanel)x3dComponent, BorderLayout.CENTER);
  
          X3DScene scene = browser.createX3DFromURL(new String[] {"test.x3d"});
  
          browser.replaceWorld(scene);
      }
  
      public static void main(String[] args) {
          Xj3DTest frame = new Xj3DTest("Xj3D test");
          frame.setSize(640, 480);
          frame.setLocationRelativeTo(null);
          frame.setVisible(true);
      }
  }
  </code></pre>
  
  <p>The <code>X3D</code> files that I need to pass through it so it displays contain a <code>viewpoint</code> and <code>imageTexture url</code> tags which are tested to cause the problem. When I delete those tags from within the <code>X3D</code> files, it does work but doesn't have the desired output as it seemed to be zoomed in and have no texture the the <code>X3D</code> file. </p>
  
  <p>The <code>Jars</code> that I'm using are <code>gluegen-rt, gluegen-rt-natives-linux-amd64, gluegen-rt-natives-windows-amd64, gluegen-rt-natives-linux-i586, j3d-core-1.3.1, jhall, joal, joal-natives-linux-amd64, joal-natives-windows-amd64, joal-natives-linux-i586, joal-all, joal-all-natives-linux-amd64, joal-all-natives-windows-amd64, joal-all-natives-linux-i586, xj3d.browser_2.1.0-nps, xj3d.cadfilter_2.1.0_nps, xj3d.2.1-3rdparty-nps, xj3d.2.1-nps, xj3d-core, xj3d-runtime, xj3d-script-base</code>. The way that I've set the VM Options is by using <code>-Xmx450M -Djava.library.path="C:\Users\matt\Documents\NetBeansProjects\jar"</code> and I have added the library that contains all the <code>Jars</code> to the project.</p>
  
  <p><strong>EDIT</strong>
  <em>It's still not working</em></p>
  
  <p><strong>EDIT#2</strong></p>
  
  <p>The two tags that are causing the problem are</p>
  
  <p><code>&lt;viewpoint centerOfRotation="7 1 0" position='10 0 40' orientation='0 0 0 1'&gt;&lt;/viewpoint&gt;</code></p>
  
  <p><code>&lt;imageTexture url='"http://somewebsite.com/images/test.jpg"&gt;&lt;/imageTexture&gt;</code>
  Bare in mind that the above website isn't the website where the image is stored but it follows the same format.</p>
  
  <p><strong>EDIT #3</strong></p>
  
  <p>The code in the <code>X3D</code> file is now
  <code>&lt;viewpoint centerOfRotation="7 1 0" position='10 0 40' orientation='0 0 0 1'&gt;&lt;/viewpoint&gt;</code></p>
  
  <p><code>&lt;imageTexture url="http://somewebsite.com/images/test.jpg"&gt;&lt;/imageTexture&gt;</code></p>
  
  <p>And I'm still getting the viewpoint error and I don't know how to fix it</p>