Examples of updateBound()


Examples of com.bulletphysics.extras.gimpact.GImpactMeshShape.updateBound()

        Bunny.NUM_TRIANGLES, Bunny.getIndexBuffer(), 4 * 3,
        Bunny.NUM_VERTICES, Bunny.getVertexBuffer(), 4 * 3);

    GImpactMeshShape trimesh = new GImpactMeshShape(indexVertexArrays);
    trimesh.setLocalScaling(new Vector3f(4f, 4f, 4f));
    trimesh.updateBound();
    trimeshShape = trimesh;

    // register algorithm
    GImpactCollisionAlgorithm.registerAlgorithm(dispatcher);
  }
View Full Code Here

Examples of com.jme3.scene.Mesh.updateBound()

            ib.put(i++);
          }
        }
    m.setBuffer(Type.Position, 3, vb);
    m.setBuffer(Type.Index, 3, ib);
    m.updateBound();
   
    Geometry g = new Geometry("Debug_NavMesh_"+this.toString(),m);
    g.updateModelBound();
    return g;
  }
View Full Code Here

Examples of com.jme3.scene.Mesh.updateBound()

        if(i <= 0){
          log.warning("Navmesh without any bordercells:"+this);
        }
    m.setBuffer(Type.Position, 3, vb);
    m.setBuffer(Type.Index, 3, ib);
    m.updateBound();
   
    Geometry g = new Geometry("Debug_NavBorderMesh_"+this.toString(),m);
    g.updateModelBound();
    return g;
  }
View Full Code Here

Examples of com.jme3.scene.Mesh.updateBound()

        m.setBuffer(Type.Position, 3, pb);
        m.setBuffer(Type.Normal, 3, nb);
        m.setBuffer(Type.TexCoord, 2, tb);
        m.setBuffer(Type.Index, 3, ib);
        m.setStatic();
        m.updateBound();
        return m;
    }
   
    public void write(JmeExporter ex) throws IOException {
        OutputCapsule oc = ex.getCapsule(this);
View Full Code Here

Examples of com.jme3.scene.Mesh.updateBound()

        Geometry geom = new Geometry();
        Mesh mesh = new Mesh();
        GeometryBatchFactory.mergeGeometries(geometries, mesh);
        applyAtlasCoords(geometries, mesh, atlas);
        mesh.updateCounts();
        mesh.updateBound();
        geom.setMesh(mesh);

        Material mat = new Material(mgr, "Common/MatDefs/Light/Lighting.j3md");
        mat.getAdditionalRenderState().setAlphaTest(true);
        Texture diffuseMap = atlas.getAtlasTexture("DiffuseMap");
View Full Code Here

Examples of com.jme3.scene.Mesh.updateBound()

                    continue;

                vb.compact(currentVertex);
            }

            out.updateBound();
            out.updateCounts();
            out.setStatic();
            //out.setInterleaved();
            Geometry outGeom = new Geometry("Geom"+entry.getKey(), out);
            outGeom.setLocalTransform(inGeom.getWorldTransform());
View Full Code Here

Examples of com.jme3.scene.Mesh.updateBound()

        if (ib instanceof IntBuffer)
            m.setBuffer(Type.Index, 3, (IntBuffer)ib);
        else if (ib instanceof ShortBuffer)
            m.setBuffer(Type.Index, 3, (ShortBuffer)ib);
        m.setStatic();
        m.updateBound();
        return m;
    }

    public FloatBuffer writeTexCoordArray(FloatBuffer store, Vector2f offset, Vector2f scale, float offsetAmount, int totalSize) {
        if (store != null) {
View Full Code Here

Examples of com.jme3.scene.Mesh.updateBound()

    // Assign the indexes and vertices to the mesh.
    m.setBuffer(Type.Position, 3, BufferUtils.createFloatBuffer(vertices));
    m.setBuffer(Type.Normal, 3, BufferUtils.createFloatBuffer(normals));
    m.setBuffer(Type.TexCoord, 2, BufferUtils.createFloatBuffer(texCoord));
    m.setBuffer(Type.Index, 1, BufferUtils.createIntBuffer(indexes));
    m.updateBound();

    return m;
  }
}
View Full Code Here

Examples of com.jme3.scene.Mesh.updateBound()

        Mesh m = new Mesh();
        m.setBuffer(Type.Position, 3, BufferUtils.createFloatBuffer(vertices));
        m.setBuffer(Type.TexCoord, 2, BufferUtils.createFloatBuffer(texCoords));
        m.setBuffer(Type.Normal, 3, BufferUtils.createFloatBuffer(normals));
        m.setBuffer(Type.Index, 1, BufferUtils.createIntBuffer(indexes));
        m.updateBound();

        return new Geometry("Terrain", m);
    }

    public Geometry cubicalMarchingSquares(AbstractHeightMap heightMap, float scale,
View Full Code Here

Examples of com.jme3.scene.Mesh.updateBound()

        m.setBuffer(Type.Position, 3, BufferUtils.createFloatBuffer(vertices));
        m.setBuffer(Type.TexCoord, 2, BufferUtils.createFloatBuffer(texCoords));
        m.setBuffer(Type.Normal, 3, BufferUtils.createFloatBuffer(normals));
        m.setBuffer(Type.Index, 1, BufferUtils.createIntBuffer(indexes));
        m.updateCounts();
        m.updateBound();

        return new Geometry("Terrain", m);
    }

    private float getIsoLevel(float x, float y, float z, float scale,
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.