banner cache for course banners
This commit is contained in:
@@ -24,6 +24,7 @@
|
|||||||
#include "TitleSubstitution.h"
|
#include "TitleSubstitution.h"
|
||||||
#include "Notes.h"
|
#include "Notes.h"
|
||||||
#include "GameState.h"
|
#include "GameState.h"
|
||||||
|
#include "BannerCache.h"
|
||||||
|
|
||||||
|
|
||||||
Course::Course()
|
Course::Course()
|
||||||
@@ -121,8 +122,13 @@ void Course::LoadFromCRSFile( CString sPath )
|
|||||||
GetDirListing( sFName + ".bmp", arrayPossibleBanners, false, true );
|
GetDirListing( sFName + ".bmp", arrayPossibleBanners, false, true );
|
||||||
GetDirListing( sFName + ".gif", arrayPossibleBanners, false, true );
|
GetDirListing( sFName + ".gif", arrayPossibleBanners, false, true );
|
||||||
if( !arrayPossibleBanners.empty() )
|
if( !arrayPossibleBanners.empty() )
|
||||||
|
{
|
||||||
m_sBannerPath = arrayPossibleBanners[0];
|
m_sBannerPath = arrayPossibleBanners[0];
|
||||||
|
|
||||||
|
/* Cache and load the course banner. */
|
||||||
|
BANNERCACHE->CacheBanner( m_sBannerPath );
|
||||||
|
}
|
||||||
|
|
||||||
for( unsigned i=0; i<msd.GetNumValues(); i++ )
|
for( unsigned i=0; i<msd.GetNumValues(); i++ )
|
||||||
{
|
{
|
||||||
CString sValueName = msd.GetParam(i, 0);
|
CString sValueName = msd.GetParam(i, 0);
|
||||||
|
|||||||
@@ -16,6 +16,9 @@
|
|||||||
#include "BannerCache.h"
|
#include "BannerCache.h"
|
||||||
#include "song.h"
|
#include "song.h"
|
||||||
#include "RageLog.h"
|
#include "RageLog.h"
|
||||||
|
#include "course.h"
|
||||||
|
#include "PrefsManager.h"
|
||||||
|
#include "ThemeManager.h"
|
||||||
|
|
||||||
/* XXX: metric */
|
/* XXX: metric */
|
||||||
static const float FadeTime = 0.25;
|
static const float FadeTime = 0.25;
|
||||||
@@ -34,8 +37,6 @@ void FadingBanner::SetCroppedSize( float fWidth, float fHeight )
|
|||||||
m_Banner[i].SetCroppedSize( fWidth, fHeight );
|
m_Banner[i].SetCroppedSize( fWidth, fHeight );
|
||||||
}
|
}
|
||||||
|
|
||||||
#include "PrefsManager.h"
|
|
||||||
#include "ThemeManager.h"
|
|
||||||
void FadingBanner::Update( float fDeltaTime )
|
void FadingBanner::Update( float fDeltaTime )
|
||||||
{
|
{
|
||||||
ActorFrame::Update( fDeltaTime );
|
ActorFrame::Update( fDeltaTime );
|
||||||
@@ -150,9 +151,9 @@ void FadingBanner::LoadFromGroup( CString sGroupName )
|
|||||||
|
|
||||||
void FadingBanner::LoadFromCourse( Course* pCourse )
|
void FadingBanner::LoadFromCourse( Course* pCourse )
|
||||||
{
|
{
|
||||||
// LoadFromCachedBanner( pCourse->GetBannerPath() );
|
LoadFromCachedBanner( pCourse->m_sBannerPath );
|
||||||
BeforeChange();
|
// BeforeChange();
|
||||||
m_Banner[GetBackIndex()].LoadFromCourse( pCourse );
|
// m_Banner[GetBackIndex()].LoadFromCourse( pCourse );
|
||||||
}
|
}
|
||||||
|
|
||||||
void FadingBanner::LoadRoulette()
|
void FadingBanner::LoadRoulette()
|
||||||
|
|||||||
Reference in New Issue
Block a user