public void setMesh (Mesh mesh) { this.setMesh(mesh, null); }
public void setMesh (Mesh mesh) { this.setMesh(mesh, null); }
@Override public void load (ParticleValue value) { super.load(value); MeshSpawnShapeValue spawnShapeValue = (MeshSpawnShapeValue)value; setMesh(spawnShapeValue.mesh, spawnShapeValue.model); }
@Override public void load (ParticleValue value) { super.load(value); MeshSpawnShapeValue spawnShapeValue = (MeshSpawnShapeValue)value; setMesh(spawnShapeValue.mesh, spawnShapeValue.model); }
@Override public void load (AssetManager manager, ResourceData data) { SaveData saveData = data.getSaveData(); AssetDescriptor descriptor = saveData.loadAsset(); if (descriptor != null) { Model model = (Model)manager.get(descriptor); setMesh(model.meshes.get((Integer)saveData.load("index")), model); } }
@Override public void load (AssetManager manager, ResourceData data) { SaveData saveData = data.getSaveData(); AssetDescriptor descriptor = saveData.loadAsset(); if (descriptor != null) { Model model = (Model)manager.get(descriptor); setMesh(model.meshes.get((Integer)saveData.load("index")), model); } }
@Override public void setMesh (Mesh mesh, Model model) { super.setMesh(mesh, model); vertexSize = mesh.getVertexSize() / 4; positionOffset = mesh.getVertexAttribute(Usage.Position).offset / 4; int indicesCount = mesh.getNumIndices(); if (indicesCount > 0) { indices = new short[indicesCount]; mesh.getIndices(indices); triangleCount = indices.length / 3; } else indices = null; vertexCount = mesh.getNumVertices(); vertices = new float[vertexCount * vertexSize]; mesh.getVertices(vertices); }
@Override public void setMesh (Mesh mesh, Model model) { super.setMesh(mesh, model); vertexSize = mesh.getVertexSize() / 4; positionOffset = mesh.getVertexAttribute(Usage.Position).offset / 4; int indicesCount = mesh.getNumIndices(); if (indicesCount > 0) { indices = new short[indicesCount]; mesh.getIndices(indices); triangleCount = indices.length / 3; } else indices = null; vertexCount = mesh.getNumVertices(); vertices = new float[vertexCount * vertexSize]; mesh.getVertices(vertices); }
public void setMesh (Mesh mesh) { this.setMesh(mesh, null); }
@Override public void load (ParticleValue value) { super.load(value); MeshSpawnShapeValue spawnShapeValue = (MeshSpawnShapeValue)value; setMesh(spawnShapeValue.mesh, spawnShapeValue.model); }
@Override public void load (AssetManager manager, ResourceData data) { SaveData saveData = data.getSaveData(); AssetDescriptor descriptor = saveData.loadAsset(); if (descriptor != null) { Model model = (Model)manager.get(descriptor); setMesh(model.meshes.get((Integer)saveData.load("index")), model); } }
@Override public void setMesh (Mesh mesh, Model model) { super.setMesh(mesh, model); vertexSize = mesh.getVertexSize() / 4; positionOffset = mesh.getVertexAttribute(Usage.Position).offset / 4; int indicesCount = mesh.getNumIndices(); if (indicesCount > 0) { indices = new short[indicesCount]; mesh.getIndices(indices); triangleCount = indices.length / 3; } else indices = null; vertexCount = mesh.getNumVertices(); vertices = new float[vertexCount * vertexSize]; mesh.getVertices(vertices); }