From: <sag...@us...> - 2014-03-09 00:51:20
|
Revision: 3850 http://sourceforge.net/p/modplug/code/3850 Author: saga-games Date: 2014-03-09 00:51:12 +0000 (Sun, 09 Mar 2014) Log Message: ----------- [Ref] Fix spelling of CHN_REVERSE [Ref] Change compatibility check with "all" trackers to really cover all module types (only interesting for libopenmpt) [Doc] Update documentation about empty "last saved with" values in IT and XM loaders Modified Paths: -------------- trunk/OpenMPT/mptrack/Ctrl_smp.cpp trunk/OpenMPT/soundlib/Load_ams.cpp trunk/OpenMPT/soundlib/Load_it.cpp trunk/OpenMPT/soundlib/Load_xm.cpp trunk/OpenMPT/soundlib/Snd_defs.h trunk/OpenMPT/soundlib/Snd_fx.cpp Modified: trunk/OpenMPT/mptrack/Ctrl_smp.cpp =================================================================== --- trunk/OpenMPT/mptrack/Ctrl_smp.cpp 2014-03-09 00:47:29 UTC (rev 3849) +++ trunk/OpenMPT/mptrack/Ctrl_smp.cpp 2014-03-09 00:51:12 UTC (rev 3850) @@ -726,7 +726,7 @@ // Loop d = 0; if (sample.uFlags[CHN_LOOP]) d = sample.uFlags[CHN_PINGPONGLOOP] ? 2 : 1; - if (sample.uFlags[CHN_REVRSE]) d |= 4; + if (sample.uFlags[CHN_REVERSE]) d |= 4; m_ComboLoopType.SetCurSel(d); wsprintf(s, "%lu", sample.nLoopStart); m_EditLoopStart.SetWindowText(s); Modified: trunk/OpenMPT/soundlib/Load_ams.cpp =================================================================== --- trunk/OpenMPT/soundlib/Load_ams.cpp 2014-03-09 00:47:29 UTC (rev 3849) +++ trunk/OpenMPT/soundlib/Load_ams.cpp 2014-03-09 00:51:12 UTC (rev 3850) @@ -712,7 +712,7 @@ } if(flags & smpReverse) { - mptSmp.uFlags.set(CHN_REVRSE); + mptSmp.uFlags.set(CHN_REVERSE); } } } Modified: trunk/OpenMPT/soundlib/Load_it.cpp =================================================================== --- trunk/OpenMPT/soundlib/Load_it.cpp 2014-03-09 00:47:29 UTC (rev 3849) +++ trunk/OpenMPT/soundlib/Load_it.cpp 2014-03-09 00:51:12 UTC (rev 3850) @@ -930,8 +930,8 @@ if(!m_dwLastSavedWithVersion && fileHeader.cwtv == 0x0888) { - // There are some files with OpenMPT extensions, but the "last saved with" field contains 0. - // Was there an OpenMPT version that wrote 0 there, or are they hacked? + // Up to OpenMPT 1.17.02.45 (r165), it was possible that the "last saved with" field was 0 + // when saving a file in OpenMPT for the first time. m_dwLastSavedWithVersion = MAKE_VERSION_NUMERIC(1, 17, 00, 00); } Modified: trunk/OpenMPT/soundlib/Load_xm.cpp =================================================================== --- trunk/OpenMPT/soundlib/Load_xm.cpp 2014-03-09 00:47:29 UTC (rev 3849) +++ trunk/OpenMPT/soundlib/Load_xm.cpp 2014-03-09 00:51:12 UTC (rev 3850) @@ -626,7 +626,9 @@ if(m_dwLastSavedWithVersion == 0) { - m_dwLastSavedWithVersion = MAKE_VERSION_NUMERIC(1, 17, 00, 00); // early versions of OpenMPT had no version indication. + // Up to OpenMPT 1.17.02.45 (r165), it was possible that the "last saved with" field was 0 + // when saving a file in OpenMPT for the first time. + m_dwLastSavedWithVersion = MAKE_VERSION_NUMERIC(1, 17, 00, 00); } } Modified: trunk/OpenMPT/soundlib/Snd_defs.h =================================================================== --- trunk/OpenMPT/soundlib/Snd_defs.h 2014-03-09 00:47:29 UTC (rev 3849) +++ trunk/OpenMPT/soundlib/Snd_defs.h 2014-03-09 00:51:12 UTC (rev 3850) @@ -133,7 +133,7 @@ #define TRK_FASTTRACKER2 (MOD_TYPE_XM) #define TRK_SCREAMTRACKER (MOD_TYPE_S3M) #define TRK_PROTRACKER (MOD_TYPE_MOD) -#define TRK_ALLTRACKERS (TRK_IMPULSETRACKER | TRK_FASTTRACKER2 | TRK_SCREAMTRACKER | TRK_PROTRACKER) +#define TRK_ALLTRACKERS (MODTYPE(~0)) // Channel flags: @@ -147,7 +147,7 @@ CHN_PINGPONGSUSTAIN = 0x10, // sample with bidi sustain loop CHN_PANNING = 0x20, // sample with forced panning CHN_STEREO = 0x40, // stereo sample - CHN_REVRSE = 0x80, // start sample playback from sample / loop end (Velvet Studio feature) - this is intentionally the same flag as CHN_PINGPONGFLAG. + CHN_REVERSE = 0x80, // start sample playback from sample / loop end (Velvet Studio feature) - this is intentionally the same flag as CHN_PINGPONGFLAG. // Channel Flags CHN_PINGPONGFLAG = 0x80, // when flag is on, sample is processed backwards CHN_MUTE = 0x100, // muted channel @@ -174,7 +174,7 @@ DECLARE_FLAGSET(ChannelFlags) -#define CHN_SAMPLEFLAGS (CHN_16BIT | CHN_LOOP | CHN_PINGPONGLOOP | CHN_SUSTAINLOOP | CHN_PINGPONGSUSTAIN | CHN_PANNING | CHN_STEREO | CHN_PINGPONGFLAG | CHN_REVRSE) +#define CHN_SAMPLEFLAGS (CHN_16BIT | CHN_LOOP | CHN_PINGPONGLOOP | CHN_SUSTAINLOOP | CHN_PINGPONGSUSTAIN | CHN_PANNING | CHN_STEREO | CHN_PINGPONGFLAG | CHN_REVERSE) #define CHN_CHANNELFLAGS (~CHN_SAMPLEFLAGS) @@ -249,7 +249,7 @@ #define DCT_NOTE 1 #define DCT_SAMPLE 2 #define DCT_INSTRUMENT 3 -#define DCT_PLUGIN 4 //rewbs.VSTiNNA +#define DCT_PLUGIN 4 // DNA types (Duplicate Note Action) #define DNA_NOTECUT 0 @@ -257,7 +257,7 @@ #define DNA_NOTEFADE 2 -// Module flags +// Module flags - note: these are written out as-is in ITP files! enum SongFlags { SONG_EMBEDMIDICFG = 0x0001, // Embed macros in file @@ -312,7 +312,6 @@ #define SNDMIX_SOFTPANNING 0x10 // soft panning mode (this is forced with mixmode RC3 and later) // Misc Flags (can safely be turned on or off) -//#define SNDMIX_NOBACKWARDJUMPS 0x40000 // stop when jumping back in the order (currently unused as it seems) #define SNDMIX_MAXDEFAULTPAN 0x80000 // Used by the MOD loader (currently unused) #define SNDMIX_MUTECHNMODE 0x100000 // Notes are not played on muted channels @@ -328,7 +327,7 @@ SRCMODE_LINEAR = 1, SRCMODE_SPLINE = 2, SRCMODE_POLYPHASE = 3, - SRCMODE_FIRFILTER = 4, //rewbs.resamplerConf + SRCMODE_FIRFILTER = 4, SRCMODE_DEFAULT = 5, }; Modified: trunk/OpenMPT/soundlib/Snd_fx.cpp =================================================================== --- trunk/OpenMPT/soundlib/Snd_fx.cpp 2014-03-09 00:47:29 UTC (rev 3849) +++ trunk/OpenMPT/soundlib/Snd_fx.cpp 2014-03-09 00:51:12 UTC (rev 3850) @@ -1320,7 +1320,7 @@ if (pChn->nLength > pChn->nLoopEnd) pChn->nLength = pChn->nLoopEnd; } - if(pChn->dwFlags[CHN_REVRSE]) + if(pChn->dwFlags[CHN_REVERSE]) { pChn->dwFlags.set(CHN_PINGPONGFLAG); pChn->nPos = pChn->nLength - 1; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |