make GetFrameDimensionsFromFileName available
This commit is contained in:
@@ -67,7 +67,7 @@ void RageTexture::CreateFrameRects()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void RageTexture::GetFrameDimensionsFromFileName( CString sPath, int* piFramesWide, int* piFramesHigh ) const
|
void RageTexture::GetFrameDimensionsFromFileName( CString sPath, int* piFramesWide, int* piFramesHigh )
|
||||||
{
|
{
|
||||||
*piFramesWide = *piFramesHigh = 1; // set default values in case we don't find the dimension in the file name
|
*piFramesWide = *piFramesHigh = 1; // set default values in case we don't find the dimension in the file name
|
||||||
|
|
||||||
@@ -79,6 +79,7 @@ void RageTexture::GetFrameDimensionsFromFileName( CString sPath, int* piFramesWi
|
|||||||
CStringArray arrayBits;
|
CStringArray arrayBits;
|
||||||
split( sFName, " ", arrayBits, false );
|
split( sFName, " ", arrayBits, false );
|
||||||
|
|
||||||
|
/* XXX: allow dims to be in parens */
|
||||||
for( unsigned i=0; i<arrayBits.size(); i++ )
|
for( unsigned i=0; i<arrayBits.size(); i++ )
|
||||||
{
|
{
|
||||||
CString &sBit = arrayBits[ i ];
|
CString &sBit = arrayBits[ i ];
|
||||||
|
|||||||
@@ -90,6 +90,8 @@ public:
|
|||||||
/* The ID that we actually got: */
|
/* The ID that we actually got: */
|
||||||
const RageTextureID &GetActualID() const { return m_ActualID; }
|
const RageTextureID &GetActualID() const { return m_ActualID; }
|
||||||
|
|
||||||
|
static void GetFrameDimensionsFromFileName( CString sPath, int* puFramesWide, int* puFramesHigh );
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/* The file we were asked to load. (This is never changed.) */
|
/* The file we were asked to load. (This is never changed.) */
|
||||||
RageTextureID m_ID;
|
RageTextureID m_ID;
|
||||||
@@ -106,7 +108,6 @@ protected:
|
|||||||
vector<RectF> m_TextureCoordRects; // size = m_iFramesWide * m_iFramesHigh
|
vector<RectF> m_TextureCoordRects; // size = m_iFramesWide * m_iFramesHigh
|
||||||
|
|
||||||
virtual void CreateFrameRects();
|
virtual void CreateFrameRects();
|
||||||
virtual void GetFrameDimensionsFromFileName( CString sPath, int* puFramesWide, int* puFramesHigh ) const;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Reference in New Issue
Block a user