java.lang.Object
com.marginallyclever.ro3.mesh.MeshFactory
MeshFactory
loads a mesh from a file using one of many MeshLoader
classes. It also keeps a pool of
all mesh loaded so that only one instance of each shape is loaded.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
getMaterialPath
(String absolutePath) getPool()
boolean
hasMaterial
(String absolutePath) Makes sure to only load one instance of each source file.void
void
reset()
Remove all meshes from the pool.
-
Constructor Details
-
MeshFactory
public MeshFactory()
-
-
Method Details
-
load
Makes sure to only load one instance of each source file. Loads all the data immediately.- Parameters:
filename
- file from which to load. May be "filename.ext" or "zipfile.zip:filename.ext"- Returns:
- an instance of Mesh. It may contain nothing.
-
reload
-
getAllExtensions
-
canLoad
-
hasMaterial
-
getMaterialPath
-
getAllSourcesForExport
-
getPool
-
reset
public void reset()Remove all meshes from the pool.
-