/////////////////////////////////////////////// // Solid /////////////////////////////////////////////// public final void SolidBegin() throws ParseException { String name; jj_consume_token(5); name = NameToken(); ShapeNode shape = createShapeNode(); shape.setName(name); addShapeNode(shape); setCurrentShapeNode(shape); setSolidFaceCount(0); }
public ShapeNode createShapeNode() { ShapeNode shape = new ShapeNode(); IndexedFaceSetNode idxFaceSetNode = new IndexedFaceSetNode(); shape.addChildNode(idxFaceSetNode); idxFaceSetNode.addChildNode(new CoordinateNode()); idxFaceSetNode.addChildNode(new ColorNode()); idxFaceSetNode.addChildNode(new NormalNode()); idxFaceSetNode.setColorPerVertex(false); idxFaceSetNode.setNormalPerVertex(true); return shape; }