diff --git a/stepmania/src/Background.cpp b/stepmania/src/Background.cpp index 3ee5a57ac6..30680034b1 100644 --- a/stepmania/src/Background.cpp +++ b/stepmania/src/Background.cpp @@ -548,7 +548,15 @@ void BackgroundImpl::LoadFromSong( const Song* pSong ) - if( pSong->HasBGChanges() ) + if( !PREFSMAN->m_bSongBackgrounds ) + { + /* Backgrounds are disabled; just display the song background. */ + BackgroundChange change; + change.m_def = m_StaticBackgroundDef; + change.m_fStartBeat = 0; + m_Layer[0].m_aBGChanges.push_back( change ); + } + else if( pSong->HasBGChanges() ) { FOREACH_BackgroundLayer( i ) { diff --git a/stepmania/src/PrefsManager.cpp b/stepmania/src/PrefsManager.cpp index 19e599e57b..b9ce49f033 100644 --- a/stepmania/src/PrefsManager.cpp +++ b/stepmania/src/PrefsManager.cpp @@ -223,6 +223,7 @@ PrefsManager::PrefsManager() : m_bShowStats ( "ShowStats", TRUE_IF_DEBUG), m_bShowBanners ( "ShowBanners", true ), + m_bSongBackgrounds ( "SongBackgrounds", true ), m_RandomBackgroundMode ( "RandomBackgroundMode", BGMODE_ANIMATIONS ), m_iNumBackgrounds ( "NumBackgrounds", 8 ), m_fBGBrightness ( "BGBrightness", 0.8f ), diff --git a/stepmania/src/PrefsManager.h b/stepmania/src/PrefsManager.h index 26230a5527..e073369983 100644 --- a/stepmania/src/PrefsManager.h +++ b/stepmania/src/PrefsManager.h @@ -33,6 +33,7 @@ public: Preference m_bShowStats; Preference m_bShowBanners; + Preference m_bSongBackgrounds; enum RandomBackgroundMode { BGMODE_OFF, BGMODE_ANIMATIONS, BGMODE_RANDOMMOVIES, NUM_RandomBackgroundMode }; Preference m_RandomBackgroundMode; Preference m_iNumBackgrounds; diff --git a/stepmania/src/ScreenOptionsMasterPrefs.cpp b/stepmania/src/ScreenOptionsMasterPrefs.cpp index 4ad0d097fa..ac4182531c 100644 --- a/stepmania/src/ScreenOptionsMasterPrefs.cpp +++ b/stepmania/src/ScreenOptionsMasterPrefs.cpp @@ -265,6 +265,17 @@ static void BGBrightness( int &sel, bool ToSel, const ConfOption *pConfOption ) MoveMap( sel, pConfOption, ToSel, mapping, ARRAYSIZE(mapping) ); } +static void BGBrightnessOrStatic( int &sel, bool ToSel, const ConfOption *pConfOption ) +{ + const float mapping[] = { 0.4f,0.4f,0.7f }; + MoveMap( sel, PREFSMAN->m_fBGBrightness, ToSel, mapping, ARRAYSIZE(mapping) ); + + if( ToSel && !PREFSMAN->m_bSongBackgrounds ) + sel = 0; + if( !ToSel ) + PREFSMAN->m_bSongBackgrounds.Set( sel != 0 ); +} + static void NumBackgrounds( int &sel, bool ToSel, const ConfOption *pConfOption ) { const int mapping[] = { 5,10,15,20 }; @@ -527,6 +538,7 @@ static void InitializeConfOptions() /* Background options */ ADD( ConfOption( "RandomBackgroundMode", MovePref, "OFF","ANIMATIONS","VISUALIZATIONS","RANDOM MOVIES" ) ); ADD( ConfOption( "BGBrightness", BGBrightness, "0%","10%","20%","30%","40%","50%","60%","70%","80%","90%","100%" ) ); + ADD( ConfOption( "BGBrightnessOrStatic", BGBrightnessOrStatic,"DISABLED","DIM","BRIGHT" ) ); ADD( ConfOption( "ShowDanger", MovePref, "HIDE","SHOW" ) ); ADD( ConfOption( "ShowDancingCharacters", MovePref, "DEFAULT TO OFF","DEFAULT TO RANDOM","SELECT" ) ); ADD( ConfOption( "ShowBeginnerHelper", MovePref, "OFF","ON" ) );