From: <sag...@us...> - 2013-06-08 23:47:00
|
Revision: 2335 http://sourceforge.net/p/modplug/code/2335 Author: saga-games Date: 2013-06-08 23:46:51 +0000 (Sat, 08 Jun 2013) Log Message: ----------- [Fix] Sample editor: Fractional sample frequency display didn't always show the correct fraction. [Fix] MOD playback: Frequency limiting was not always correct in PT1x mode (Fixes black_queen.mod) [Mod] OpenMPT: Version is now 1.22.03.03 Modified Paths: -------------- trunk/OpenMPT/common/versionNumber.h trunk/OpenMPT/mptrack/View_smp.cpp trunk/OpenMPT/soundlib/Sndmix.cpp Modified: trunk/OpenMPT/common/versionNumber.h =================================================================== --- trunk/OpenMPT/common/versionNumber.h 2013-06-08 20:01:49 UTC (rev 2334) +++ trunk/OpenMPT/common/versionNumber.h 2013-06-08 23:46:51 UTC (rev 2335) @@ -17,7 +17,7 @@ #define VER_MAJORMAJOR 1 #define VER_MAJOR 22 #define VER_MINOR 03 -#define VER_MINORMINOR 02 +#define VER_MINORMINOR 03 //Version string. For example "1.17.02.28" #define MPT_VERSION_STR VER_STRINGIZE(VER_MAJORMAJOR)"."VER_STRINGIZE(VER_MAJOR)"."VER_STRINGIZE(VER_MINOR)"."VER_STRINGIZE(VER_MINORMINOR) Modified: trunk/OpenMPT/mptrack/View_smp.cpp =================================================================== --- trunk/OpenMPT/mptrack/View_smp.cpp 2013-06-08 20:01:49 UTC (rev 2334) +++ trunk/OpenMPT/mptrack/View_smp.cpp 2013-06-08 23:46:51 UTC (rev 2335) @@ -2246,7 +2246,7 @@ uint32 freq = sndFile.GetFreqFromPeriod(sndFile.GetPeriodFromNote(note + (sndFile.GetType() == MOD_TYPE_XM ? sample.RelativeTone : 0), sample.nFineTune, sample.nC5Speed), sample.nC5Speed, 0); CHAR s[32]; - wsprintf(s, "%s (%d.%d Hz)", szDefaultNoteNames[note - 1], freq >> FREQ_FRACBITS, Util::muldiv(freq & ((1 << FREQ_FRACBITS) - 1), 100, 1 << FREQ_FRACBITS)); + wsprintf(s, "%s (%d.%02d Hz)", szDefaultNoteNames[note - 1], freq >> FREQ_FRACBITS, Util::muldiv(freq & ((1 << FREQ_FRACBITS) - 1), 100, 1 << FREQ_FRACBITS)); pMainFrm->SetInfoText(s); } } Modified: trunk/OpenMPT/soundlib/Sndmix.cpp =================================================================== --- trunk/OpenMPT/soundlib/Sndmix.cpp 2013-06-08 20:01:49 UTC (rev 2334) +++ trunk/OpenMPT/soundlib/Sndmix.cpp 2013-06-08 23:46:51 UTC (rev 2335) @@ -1871,9 +1871,15 @@ // Test case: AmigaLimits.s3m, AmigaLimitsFinetune.mod if(m_SongFlags[SONG_AMIGALIMITS | SONG_PT1XMODE]) { - ASSERT(pChn->nFineTune == 0 || GetType() != MOD_TYPE_S3M); - Limit(period, 113 * 4 - pChn->nFineTune, 856 * 4 - pChn->nFineTune); - Limit(pChn->nPeriod, 113 * 4 - pChn->nFineTune, 856 * 4 - pChn->nFineTune); + int limitLow = 113 * 4, limitHigh = 856 * 4; + if(m_SongFlags[SONG_PT1XMODE]) + { + const int tableOffset = XM2MODFineTune(pChn->nFineTune) * 12; + limitLow = ProTrackerTunedPeriods[tableOffset + 11] / 2; + limitHigh = ProTrackerTunedPeriods[tableOffset] * 2; + } + Limit(period, limitLow, limitHigh); + Limit(pChn->nPeriod, limitLow, limitHigh); } ProcessPanbrello(pChn); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |