From: <man...@us...> - 2013-03-25 21:11:56
|
Revision: 1691 http://sourceforge.net/p/modplug/code/1691 Author: manxorist Date: 2013-03-25 21:11:50 +0000 (Mon, 25 Mar 2013) Log Message: ----------- [Mod] Remove SYSMIX_SLOWCPU and associated lower quality resampling in some cases. In 2013, the user can just disable interpolation for CPUs that old. Also remove SYSMIX_FASTCPU which meant exactly the same as SYSMIX_ENABLEMMX. Modified Paths: -------------- trunk/OpenMPT/mptrack/Mpdlgs.cpp trunk/OpenMPT/soundlib/Mmx_mix.cpp trunk/OpenMPT/soundlib/Snd_defs.h trunk/OpenMPT/soundlib/Sndmix.cpp Modified: trunk/OpenMPT/mptrack/Mpdlgs.cpp =================================================================== --- trunk/OpenMPT/mptrack/Mpdlgs.cpp 2013-03-25 20:55:55 UTC (rev 1690) +++ trunk/OpenMPT/mptrack/Mpdlgs.cpp 2013-03-25 21:11:50 UTC (rev 1691) @@ -518,9 +518,7 @@ GetDlgItem(IDC_CHECK5)->ShowWindow(SW_HIDE); #endif #ifndef NO_EQ - if (CSoundFile::GetSysInfo() & SYSMIX_SLOWCPU) - ::EnableWindow(::GetDlgItem(m_hWnd, IDC_CHECK3), FALSE); - else if (dwQuality & QUALITY_EQ) CheckDlgButton(IDC_CHECK3, MF_CHECKED); + if (dwQuality & QUALITY_EQ) CheckDlgButton(IDC_CHECK3, MF_CHECKED); #else GetDlgItem(IDC_CHECK3)->ShowWindow(SW_HIDE); ::EnableWindow(::GetDlgItem(m_hWnd, IDC_CHECK3), FALSE); Modified: trunk/OpenMPT/soundlib/Mmx_mix.cpp =================================================================== --- trunk/OpenMPT/soundlib/Mmx_mix.cpp 2013-03-25 20:55:55 UTC (rev 1690) +++ trunk/OpenMPT/soundlib/Mmx_mix.cpp 2013-03-25 21:11:50 UTC (rev 1691) @@ -137,11 +137,9 @@ dwProcSupport &= PROCSUPPORT_CPUID|PROCSUPPORT_MMX|PROCSUPPORT_3DNOW|PROCSUPPORT_MMXEX; } } - if (dwProcSupport & PROCSUPPORT_MMX) d |= (SYSMIX_ENABLEMMX|SYSMIX_FASTCPU); if (dwProcSupport & PROCSUPPORT_MMXEX) d |= SYSMIX_MMXEX; if (dwProcSupport & PROCSUPPORT_3DNOW) d |= SYSMIX_3DNOW; if (dwProcSupport & PROCSUPPORT_SSE) d |= SYSMIX_SSE; - if (!(dwProcSupport & PROCSUPPORT_CPUID)) d |= SYSMIX_SLOWCPU; gdwSysInfo = d; return d; } Modified: trunk/OpenMPT/soundlib/Snd_defs.h =================================================================== --- trunk/OpenMPT/soundlib/Snd_defs.h 2013-03-25 20:55:55 UTC (rev 1690) +++ trunk/OpenMPT/soundlib/Snd_defs.h 2013-03-25 21:11:50 UTC (rev 1691) @@ -234,8 +234,6 @@ // Mixer Hardware-Dependent features #define SYSMIX_ENABLEMMX 0x01 // Hardware acceleration features (MMX/3DNow!/SSE) are supported by this processor -#define SYSMIX_SLOWCPU 0x02 // *Really* old processor (in this context, it doesn't know CPUID instructions => Must be older than Pentium) -#define SYSMIX_FASTCPU 0x04 // "Fast" processor (in this context, anything that is at least a Pentium MMX) #define SYSMIX_MMXEX 0x08 // Processor supports AMD MMX extensions #define SYSMIX_3DNOW 0x10 // Processor supports AMD 3DNow! instructions #define SYSMIX_SSE 0x20 // Processor supports SSE instructions Modified: trunk/OpenMPT/soundlib/Sndmix.cpp =================================================================== --- trunk/OpenMPT/soundlib/Sndmix.cpp 2013-03-25 20:55:55 UTC (rev 1690) +++ trunk/OpenMPT/soundlib/Sndmix.cpp 2013-03-25 21:11:50 UTC (rev 1691) @@ -1603,10 +1603,10 @@ LONG nRightDelta = ((pChn->nNewRightVol - pChn->nRightVol) << VOLUMERAMPPRECISION); LONG nLeftDelta = ((pChn->nNewLeftVol - pChn->nLeftVol) << VOLUMERAMPPRECISION); // if ((gdwSoundSetup & SNDMIX_DIRECTTODISK) -// || ((gdwSysInfo & (SYSMIX_ENABLEMMX|SYSMIX_FASTCPU)) +// || ((gdwSysInfo & (SYSMIX_ENABLEMMX)) // && (gdwSoundSetup & SNDMIX_HQRESAMPLER))) if((gdwSoundSetup & SNDMIX_DIRECTTODISK) - || ((gdwSysInfo & (SYSMIX_ENABLEMMX | SYSMIX_FASTCPU)) && (gdwSoundSetup & SNDMIX_HQRESAMPLER) && !enableCustomRamp)) + || ((gdwSysInfo & SYSMIX_ENABLEMMX) && (gdwSoundSetup & SNDMIX_HQRESAMPLER) && !enableCustomRamp)) { if((pChn->nRightVol | pChn->nLeftVol) && (pChn->nNewRightVol | pChn->nNewLeftVol) && !pChn->dwFlags[CHN_FASTVOLRAMP]) { @@ -2044,12 +2044,8 @@ if ((!(gdwSoundSetup & SNDMIX_DIRECTTODISK)) && (!(gdwSoundSetup & SNDMIX_ULTRAHQSRCMODE))) { int fmax = 0x20000; - if (gdwSysInfo & SYSMIX_SLOWCPU) + if (!(gdwSysInfo & SYSMIX_ENABLEMMX)) { - fmax = 0xFE00; - } else - if (!(gdwSysInfo & (SYSMIX_ENABLEMMX|SYSMIX_FASTCPU))) - { fmax = 0x18000; } if ((pChn->nNewLeftVol < 0x80) && (pChn->nNewRightVol < 0x80) @@ -2067,8 +2063,7 @@ } else { - if ((pChn->nInc >= 0x14000) - || ((pChn->nInc >= 0xFF00) && ((pChn->nInc < 0x10100) || (gdwSysInfo & SYSMIX_SLOWCPU)))) + if ((pChn->nInc >= 0x14000) || ((pChn->nInc >= 0xFF00) && (pChn->nInc < 0x10100))) pChn->dwFlags.set(CHN_NOIDO); } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |