forked from organicmaps/organicmaps
closes #453
This commit is contained in:
parent
6f096ed00c
commit
358a248ab3
3 changed files with 12 additions and 0 deletions
|
@ -292,6 +292,9 @@ namespace yg
|
|||
|
||||
void GeometryBatcher::freeTexture(int pipelineID)
|
||||
{
|
||||
if (!m_skin->getPage(pipelineID)->texture())
|
||||
return;
|
||||
|
||||
shared_ptr<FreeTexture> freeTexCmd(new FreeTexture());
|
||||
|
||||
freeTexCmd->m_texture = m_skin->getPage(pipelineID)->texture();
|
||||
|
@ -311,6 +314,9 @@ namespace yg
|
|||
|
||||
if (freeTexCmd->m_texture)
|
||||
processCommand(freeTexCmd);
|
||||
|
||||
m_skin->getPage(pipelineID)->resetTexture();
|
||||
|
||||
/*
|
||||
m_skin->getPage(pipelineID)->freeTexture();*/
|
||||
}
|
||||
|
|
|
@ -377,6 +377,11 @@ namespace yg
|
|||
0x00FFFFFF - 1);
|
||||
}
|
||||
|
||||
void SkinPage::resetTexture()
|
||||
{
|
||||
m_texture.reset();
|
||||
}
|
||||
|
||||
void SkinPage::freeTexture()
|
||||
{
|
||||
if (m_texture)
|
||||
|
|
|
@ -128,6 +128,7 @@ namespace yg
|
|||
|
||||
void reserveTexture() const;
|
||||
void freeTexture();
|
||||
void resetTexture();
|
||||
void createPacker();
|
||||
|
||||
uint32_t findColor(Color const & c) const;
|
||||
|
|
Loading…
Add table
Reference in a new issue