|
| ModelManager (std::shared_ptr< STK::ShaderProgramManager > shaderManager, std::shared_ptr< STK::TextureManager > textureManager) |
|
bool | AddModelJSON (const std::string &string) |
|
void | Initialize (const std::string &modelDir, bool recursive) |
|
void | AddModel (const std::string &id, const std::shared_ptr< ManagedGraphicsModel > &model) |
|
bool | ModelExists (const std::string &id) const |
|
bool | ModelIsLoaded (const std::string &id) const |
|
void | RemoveModel (const std::string &id) |
|
bool | ExportModel (const std::string &id, const std::string &fileName, const std::string rootDir) |
|
bool | SetModelTransform (const std::string &id, double rx, double ry, double rz, double tx, double ty, double tz, double scale) |
|
bool | UpdateModelMaterials (const std::string &id, float diff_r, float diff_g, float diff_b, float diff_a, float amb_r, float amb_g, float amb_b, float amb_a, float spec_r, float spec_g, float spec_b, float spec_a, float shininess, const std::string &node_regexp="") |
|
bool | UpdateModelTextureExt (const std::string &id, const std::string &new_ext, const std::string &file_regexp="") |
|
bool | getModelTextures (const std::string &id, std::vector< std::string > &texturePaths) |
|
std::shared_ptr< STK::GraphicsModel > | GetModel (const std::string &name, const std::string &fallbackName="") const |
|
std::shared_ptr< ManagedGraphicsModel > | GetManagedModel (const std::string &name, const std::string &fallbackName="") const |
|
std::shared_ptr< STK::ShaderProgramManager > | getShaderManager () const |
|
std::shared_ptr< STK::TextureManager > | getTextureManager () const |
|
std::shared_ptr< STK::ShaderProgramManager > | shaderManager () |
|
std::shared_ptr< STK::TextureManager > | textureManager () |
|
bool | getModelBoundingSphere (const std::string &id, float &x, float &y, float &z, float &radius) |
|
bool | getModelBoundingBox (const std::string &id, float &xMin, float &yMin, float &zMin, float &xMax, float &yMax, float &zMax) |
|
void | incMemsize (int64_t memsize) |
| Increase size of tracked memory usage.
|
|
void | decMemsize (int64_t memsize) |
| Decrease size of tracked memory usage.
|
|
int64_t | getMemsize () const |
| Get current memory usage.
|
|
void | setMaxMemsize (int64_t max_memsize) |
| Set max memory usage. If set to 0, no cleanup is done.
|
|
int64_t | getMaxMemsize () const |
| Get max memory usage.
|
|
int64_t | cleanup (double target_f=0.75, int64_t minAge=500) |
|
int64_t | getTimestamp () const |
|
int | numPendingRequests () const |
|
void | incPendingReqs () |
|
void | decPendingReqs () |
|
int | numLoadedModels () const |
|
void | resetLoadedModels () |
|
void | incLoadedModels () |
|
|
static std::shared_ptr< ManagedGraphicsModel > | CreateModel (const std::shared_ptr< ModelManager > &modelManager, const std::string &key, const std::string &assetID, const std::string &path, const std::shared_ptr< STK::AssetDataProvider > &dataProvider) |
| Static factory methods. Creates a managed model and adds it ot the manager.
|
|
static void | CreateModel (const std::shared_ptr< ModelManager > &modelManager, const std::string &id, std::shared_ptr< STK::GraphicsModel > model) |
|
static void | CreateModel (const std::shared_ptr< ModelManager > &modelManager, const std::string &id, const std::string &file, const std::string &material, double rx, double ry, double rz, double tx, double ty, double tz, double scale) |
|
ModelManager - Manager for 3D models