|
TextureCacheGetTextureFromFile Method |
Checks if a texture with specified fileName was already loaded and cached.
In this case the method returns a cached texture and increases its reference count. Otherwise null is returned.
You need to dispose the texture when it is not used any more.
Namespace: Ab3d.DirectXAssembly: Ab3d.DXEngine (in Ab3d.DXEngine.dll) Version: 7.0.8865.1045
Syntax public SharedDXResourceWrapper<ShaderResourceView> GetTextureFromFile(
string fileName,
out bool hasTransparency
)
Parameters
- fileName String
- file name
- hasTransparency Boolean
- returns true if texture has transparent colors
Return Value
SharedDXResourceWrapperShaderResourceViewShaderResourceView wrapped by SharedDXResourceWrapper or null if texture with the specified fileName was not yet cached
See Also