diff --git a/stepmania/src/Song.cpp b/stepmania/src/Song.cpp index b615b3066e..50b744ca9a 100644 --- a/stepmania/src/Song.cpp +++ b/stepmania/src/Song.cpp @@ -1452,8 +1452,8 @@ void SortSongPointerArrayByTitle( CArray &arraySongPointers ) int CompareSongPointersByBPM(const void *arg1, const void *arg2) { - Song* pSong1 = *(Song**)arg1; - Song* pSong2 = *(Song**)arg2; + const Song* pSong1 = *(const Song**)arg1; + const Song* pSong2 = *(const Song**)arg2; float fMinBPM1, fMaxBPM1, fMinBPM2, fMaxBPM2; pSong1->GetMinMaxBPM( fMinBPM1, fMaxBPM1 ); diff --git a/stepmania/src/song.h b/stepmania/src/song.h index cddcf3b6f0..aac233f2ef 100644 --- a/stepmania/src/song.h +++ b/stepmania/src/song.h @@ -117,7 +117,7 @@ public: void AddStopSegment( StopSegment seg ); void AddAnimationSegment( AnimationSegment seg ); - void GetMinMaxBPM( float &fMinBPM, float &fMaxBPM ) + void GetMinMaxBPM( float &fMinBPM, float &fMaxBPM ) const { fMaxBPM = 0; fMinBPM = 100000; // inf @@ -128,7 +128,7 @@ public: fMinBPM = min( seg.m_fBPM, fMinBPM ); } }; - float GetBPMAtBeat( float fBeat ) + float GetBPMAtBeat( float fBeat ) const { for( int i=0; i fBeat )