MCPcopy Create free account
hub / github.com/carbonengine/trinity / Reserve

Method Reserve

trinity/Tr2ImpostorManager.cpp:66–75  ·  view source on GitHub ↗

-------------------------------------------------------------------------------------- Description: Reserves a new texcoord from the atlas. Arguments: coord - (out) New texcoord Return Value: true If texcoord was reserved false If the atlas is full --------------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

64// false If the atlas is full
65// --------------------------------------------------------------------------------------
66bool Tr2ImpostorManager::ImpostorAtlas::Reserve( Vector2_16& coord )
67{
68 if( m_free.empty() )
69 {
70 return false;
71 }
72 coord = m_free.back();
73 m_free.pop_back();
74 return true;
75}
76
77// --------------------------------------------------------------------------------------
78// Description:

Callers 2

AddMethod · 0.45

Calls 1

emptyMethod · 0.80

Tested by

no test coverage detected