Safe Haskell | None |
---|
- delete :: HG3DClass -> IO ()
- setMemoryBudget :: HG3DClass -> Int -> IO ()
- getMemoryBudget :: HG3DClass -> IO Int
- getMemoryUsage :: HG3DClass -> IO Int
- unload :: HG3DClass -> String -> IO ()
- unloadAll :: HG3DClass -> Bool -> IO ()
- reloadAll :: HG3DClass -> Bool -> IO ()
- unloadUnreferencedResources :: HG3DClass -> Bool -> IO ()
- reloadUnreferencedResources :: HG3DClass -> Bool -> IO ()
- remove2 :: HG3DClass -> String -> IO ()
- removeAll :: HG3DClass -> IO ()
- removeUnreferencedResources :: HG3DClass -> Bool -> IO ()
- resourceExists :: HG3DClass -> String -> IO Bool
- getLoadingOrder :: HG3DClass -> IO Float
- getResourceType :: HG3DClass -> IO String
- setVerbose :: HG3DClass -> Bool -> IO ()
- getVerbose :: HG3DClass -> IO Bool
- destroyResourcePool2 :: HG3DClass -> String -> IO ()
- destroyAllResourcePools :: HG3DClass -> IO ()
- delete'_ :: HG3DClassPtr -> IO ()
- setMemoryBudget'_ :: HG3DClassPtr -> CInt -> IO ()
- getMemoryBudget'_ :: HG3DClassPtr -> Ptr CInt -> IO ()
- getMemoryUsage'_ :: HG3DClassPtr -> Ptr CInt -> IO ()
- unload'_ :: HG3DClassPtr -> Ptr CChar -> IO ()
- unloadAll'_ :: HG3DClassPtr -> CInt -> IO ()
- reloadAll'_ :: HG3DClassPtr -> CInt -> IO ()
- unloadUnreferencedResources'_ :: HG3DClassPtr -> CInt -> IO ()
- reloadUnreferencedResources'_ :: HG3DClassPtr -> CInt -> IO ()
- remove2'_ :: HG3DClassPtr -> Ptr CChar -> IO ()
- removeAll'_ :: HG3DClassPtr -> IO ()
- removeUnreferencedResources'_ :: HG3DClassPtr -> CInt -> IO ()
- resourceExists'_ :: HG3DClassPtr -> Ptr CChar -> Ptr CInt -> IO ()
- getLoadingOrder'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()
- getResourceType'_ :: HG3DClassPtr -> Ptr CChar -> IO ()
- setVerbose'_ :: HG3DClassPtr -> CInt -> IO ()
- getVerbose'_ :: HG3DClassPtr -> Ptr CInt -> IO ()
- destroyResourcePool2'_ :: HG3DClassPtr -> Ptr CChar -> IO ()
- destroyAllResourcePools'_ :: HG3DClassPtr -> IO ()
Documentation
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Int | bytes |
-> IO () |
Get the limit on the amount of memory this resource handler may use.
Set a limit on the amount of memory this resource handler may use. If, when asked to load a new resource, the manager believes it will exceed this memory budget, it will temporarily unload a resource to make room for the new one. This unloading is not permanent and the Resource
Gets the current memory usage, in bytes.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> String | name |
-> IO () |
Unloads all resources. Unloaded resources are not removed, they simply free up their memory as much as they can and wait to be reloaded. ResourceGroupManagerResource::isReloadable
Unloads a single resource by name. Unloaded resources are not removed, they simply free up their memory as much as they can and wait to be reloaded. ResourceGroupManager
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Bool | reloadableOnly - If true (the default), only unload the resource that is reloadable. Because some resources isn't reloadable, they will be unloaded but can't load them later. Thus, you might not want to them unloaded. Or, you might unload all of them, and then populate them manually later. |
-> IO () |
Caused all currently loaded resources to be reloaded. All resources currently being held in this manager which are also marked as currently loaded will be unloaded, then loaded again. Resource::isReloadable
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Bool | reloadableOnly - If true (the default), only reload the resource that is reloadable. Because some resources isn't reloadable, they will be unloaded but can't loaded again. Thus, you might not want to them unloaded. Or, you might unload all of them, and then populate them manually later. |
-> IO () |
Unload all resources which are not referenced by any other object.
This method behaves like unloadAll, except that it only unloads resources which are not in use, ie not referenced by other objects. This allows you to free up some memory selectively whilst still keeping the group around (and the resources present, just not using much memory). Some referenced resource may exists weak
pointer to their sub-components (e.g. Entity
unloadUnreferencedResourcesSource
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Bool | reloadableOnly - If true (the default), only unloads resources which can be subsequently automatically reloaded. |
-> IO () |
Caused all currently loaded but not referenced by any other object
resources to be reloaded.
This method behaves like reloadAll, except that it only reloads resources which are not in use, i.e. not referenced by other objects. Some referenced resource may exists weak
pointer to their sub-components (e.g. Entity
reloadUnreferencedResourcesSource
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Bool | reloadableOnly - If true (the default), only reloads resources which can be subsequently automatically reloaded. |
-> IO () |
Remove a single resource by name.
Removes a single resource, meaning it will be removed from the list of valid resources in this manager, also causing it to be unloaded. The word Destroy
is not used here, since if any other pointers are referring to this resource, it will persist until they have finished with it; however to all intents and purposes it no longer exists and will likely get destroyed imminently.
If you do have shared pointers to resources hanging around after the ResourceManager
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> String | name |
-> IO () |
Removes all resources.
The word Destroy
is not used here, since if any other pointers are referring to these resources, they will persist until they have been finished with; however to all intents and purposes the resources no longer exist and will get destroyed imminently.
If you do have shared pointers to resources hanging around after the ResourceManager
Remove all resources which are not referenced by any other object.
This method behaves like removeAll, except that it only removes resources which are not in use, ie not referenced by other objects. This allows you to free up some memory selectively whilst still keeping the group around (and the resources present, just not using much memory). Some referenced resource may exists weak
pointer to their sub-components (e.g. Entity
removeUnreferencedResourcesSource
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Bool | reloadableOnly - If true (the default), only removes resources which can be subsequently automatically reloaded. |
-> IO () |
Returns whether the named resource exists in this manager.
Gets a string identifying the type of resource this manager handles.
Gets the relative loading order of resources of this type. There are dependencies between some kinds of resource in terms of loading order, and this value enumerates that. Higher values load later during bulk loading tasks.
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> Bool | v |
-> IO () |
Gets whether this manager and its resources habitually produce log output
Sets whether this manager and its resources habitually produce log output
:: HG3DClass | classpointer - pointer of Class instance from which this methods is called. |
-> String | name |
-> IO () |
destroy all pools
Destroy a resource pool.
delete'_ :: HG3DClassPtr -> IO ()Source
setMemoryBudget'_ :: HG3DClassPtr -> CInt -> IO ()Source
getMemoryBudget'_ :: HG3DClassPtr -> Ptr CInt -> IO ()Source
getMemoryUsage'_ :: HG3DClassPtr -> Ptr CInt -> IO ()Source
unloadAll'_ :: HG3DClassPtr -> CInt -> IO ()Source
reloadAll'_ :: HG3DClassPtr -> CInt -> IO ()Source
unloadUnreferencedResources'_ :: HG3DClassPtr -> CInt -> IO ()Source
reloadUnreferencedResources'_ :: HG3DClassPtr -> CInt -> IO ()Source
removeAll'_ :: HG3DClassPtr -> IO ()Source
removeUnreferencedResources'_ :: HG3DClassPtr -> CInt -> IO ()Source
resourceExists'_ :: HG3DClassPtr -> Ptr CChar -> Ptr CInt -> IO ()Source
getLoadingOrder'_ :: HG3DClassPtr -> Ptr CFloat -> IO ()Source
getResourceType'_ :: HG3DClassPtr -> Ptr CChar -> IO ()Source
setVerbose'_ :: HG3DClassPtr -> CInt -> IO ()Source
getVerbose'_ :: HG3DClassPtr -> Ptr CInt -> IO ()Source
destroyResourcePool2'_ :: HG3DClassPtr -> Ptr CChar -> IO ()Source