Kodi Documentation 18.0
Kodi is an open source media player and entertainment hub.
CGUITextureManager Class Reference

#include <TextureManager.h>

Public Member Functions

 CGUITextureManager (void)
 
virtual ~CGUITextureManager (void)
 
bool HasTexture (const std::string &textureName, std::string *path=NULL, int *bundle=NULL, int *size=NULL)
 
const CTextureArrayLoad (const std::string &strTextureName, bool checkBundleOnly=false)
 
void ReleaseTexture (const std::string &strTextureName, bool immediately=false)
 
void Cleanup ()
 
void Dump () const
 
uint32_t GetMemoryUsage () const
 
void Flush ()
 
std::string GetTexturePath (const std::string &textureName, bool directory=false)
 
void GetBundledTexturesFromPath (const std::string &texturePath, std::vector< std::string > &items)
 
void AddTexturePath (const std::string &texturePath)
 Add a new path to the paths to check when loading media. More...
 
void SetTexturePath (const std::string &texturePath)
 Set a single path as the path to check when loading media (clear then add) More...
 
void RemoveTexturePath (const std::string &texturePath)
 Remove a path from the paths to check when loading media. More...
 
void FreeUnusedTextures (unsigned int timeDelay=0)
 Free textures (called from app thread only) More...
 
void ReleaseHwTexture (unsigned int texture)
 

Static Public Member Functions

static bool CanLoad (const std::string &texturePath)
 Returns true if the texture manager can load this texture. More...
 

Protected Types

typedef std::vector< CTextureMap * >::iterator ivecTextures
 
typedef std::list< std::pair< CTextureMap *, unsignedint > >::iterator ilistUnused
 

Protected Attributes

std::vector< CTextureMap * > m_vecTextures
 
std::list< std::pair< CTextureMap *, unsigned int > > m_unusedTextures
 
std::vector< unsigned int > m_unusedHwTextures
 
CTextureBundle m_TexBundle [2]
 
std::vector< std::string > m_texturePaths
 
CCriticalSection m_section
 

Member Typedef Documentation

◆ ilistUnused

typedef std::list<std::pair<CTextureMap*,unsignedint>>::iterator CGUITextureManager::ilistUnused
protected

◆ ivecTextures

typedef std::vector<CTextureMap*>::iterator CGUITextureManager::ivecTextures
protected

Constructor & Destructor Documentation

◆ CGUITextureManager()

CGUITextureManager::CGUITextureManager ( void  )

◆ ~CGUITextureManager()

CGUITextureManager::~CGUITextureManager ( void  )
virtual

Member Function Documentation

◆ AddTexturePath()

void CGUITextureManager::AddTexturePath ( const std::string &  texturePath)

Add a new path to the paths to check when loading media.

◆ CanLoad()

bool CGUITextureManager::CanLoad ( const std::string &  texturePath)
static

Returns true if the texture manager can load this texture.

◆ Cleanup()

void CGUITextureManager::Cleanup ( )

◆ Dump()

void CGUITextureManager::Dump ( ) const

◆ Flush()

void CGUITextureManager::Flush ( )

◆ FreeUnusedTextures()

void CGUITextureManager::FreeUnusedTextures ( unsigned int  timeDelay = 0)

Free textures (called from app thread only)

◆ GetBundledTexturesFromPath()

void CGUITextureManager::GetBundledTexturesFromPath ( const std::string &  texturePath,
std::vector< std::string > &  items 
)

◆ GetMemoryUsage()

unsigned int CGUITextureManager::GetMemoryUsage ( ) const

◆ GetTexturePath()

std::string CGUITextureManager::GetTexturePath ( const std::string &  textureName,
bool  directory = false 
)

◆ HasTexture()

bool CGUITextureManager::HasTexture ( const std::string &  textureName,
std::string *  path = NULL,
int *  bundle = NULL,
int *  size = NULL 
)

◆ Load()

const CTextureArray & CGUITextureManager::Load ( const std::string &  strTextureName,
bool  checkBundleOnly = false 
)

◆ ReleaseHwTexture()

void CGUITextureManager::ReleaseHwTexture ( unsigned int  texture)

◆ ReleaseTexture()

void CGUITextureManager::ReleaseTexture ( const std::string &  strTextureName,
bool  immediately = false 
)

◆ RemoveTexturePath()

void CGUITextureManager::RemoveTexturePath ( const std::string &  texturePath)

Remove a path from the paths to check when loading media.

◆ SetTexturePath()

void CGUITextureManager::SetTexturePath ( const std::string &  texturePath)

Set a single path as the path to check when loading media (clear then add)

Member Data Documentation

◆ m_section

CCriticalSection CGUITextureManager::m_section
protected

◆ m_TexBundle

CTextureBundle CGUITextureManager::m_TexBundle[2]
protected

◆ m_texturePaths

std::vector<std::string> CGUITextureManager::m_texturePaths
protected

◆ m_unusedHwTextures

std::vector<unsigned int> CGUITextureManager::m_unusedHwTextures
protected

◆ m_unusedTextures

std::list<std::pair<CTextureMap*, unsigned int> > CGUITextureManager::m_unusedTextures
protected

◆ m_vecTextures

std::vector<CTextureMap*> CGUITextureManager::m_vecTextures
protected

The documentation for this class was generated from the following files: