Mercurial > audlegacy-plugins
diff src/console/Ym2612_Emu.cxx @ 316:fb513e10174e trunk
[svn] - merge libconsole-blargg into mainline libconsole:
+ obsoletes plugins-ugly:sapplug
author | nenolod |
---|---|
date | Thu, 30 Nov 2006 19:54:33 -0800 |
parents | 3da1b8942b8b |
children | 986f098da058 |
line wrap: on
line diff
--- a/src/console/Ym2612_Emu.cxx Wed Nov 29 14:42:11 2006 -0800 +++ b/src/console/Ym2612_Emu.cxx Thu Nov 30 19:54:33 2006 -0800 @@ -1,5 +1,4 @@ - -// Game_Music_Emu 0.3.0. http://www.slack.net/~ant/ +// Game_Music_Emu 0.5.1. http://www.slack.net/~ant/ // Based on Gens 2.10 ym2612.c @@ -19,10 +18,10 @@ version 2.1 of the License, or (at your option) any later version. This module is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS -FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for -more details. You should have received a copy of the GNU Lesser General -Public License along with this module; if not, write to the Free Software -Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ +FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more +details. You should have received a copy of the GNU Lesser General Public +License along with this module; if not, write to the Free Software Foundation, +Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ // This is mostly the original source in its C style and all. // @@ -33,6 +32,10 @@ // high sample accuracy (the Genesis sounds like it has only 8 bit samples). // - Shay +#ifdef BLARGG_ENABLE_OPTIMIZER + #include BLARGG_ENABLE_OPTIMIZER +#endif + const int output_bits = 14; struct slot_t @@ -547,7 +550,7 @@ break; case 0x25: - YM2612.TimerA = (YM2612.TimerA & 0x3fc) | (data & 3); + YM2612.TimerA = (YM2612.TimerA & 0x3FC) | (data & 3); if (YM2612.TimerAL != (1024 - YM2612.TimerA) << 12) { @@ -636,7 +639,6 @@ // prescale set to 6 by default double Frequence = clock_rate / sample_rate / 144.0; - //dprintf( "Frequence: %.40f\n", Frequence ); if ( fabs( Frequence - 1.0 ) < 0.0000001 ) Frequence = 1.0; YM2612.TimerBase = int (Frequence * 4096.0); @@ -1318,4 +1320,3 @@ } void Ym2612_Emu::run( int pair_count, sample_t* out ) { impl->run( pair_count, out ); } -