Diff for /np2/sound/opngeng.c between versions 1.7 and 1.9

version 1.7, 2003/11/28 08:01:33 version 1.9, 2005/02/04 05:32:24
Line 45  extern OPNCFG opncfg; Line 45  extern OPNCFG opncfg;
   
 #define SLOTOUT(s, e, c)                                                                                                        \  #define SLOTOUT(s, e, c)                                                                                                        \
                 ((opncfg.sintable[(((s).freq_cnt + (c)) >>                                                      \                  ((opncfg.sintable[(((s).freq_cnt + (c)) >>                                                      \
                                                         (FREQ_BITS - SIN_BITS)) & (SIN_ENT-1)] *                \                                                          (FREQ_BITS - SIN_BITS)) & (SIN_ENT - 1)] *              \
                                 opncfg.envtable[(e)]) >> (ENVTBL_BIT+SINTBL_BIT-TL_BITS))                                  opncfg.envtable[(e)]) >> (ENVTBL_BIT+SINTBL_BIT-TL_BITS))
   
   
Line 143  void SOUNDCALL opngen_getpcm(void *hdl,  Line 143  void SOUNDCALL opngen_getpcm(void *hdl, 
                 samp_l >>= (OPM_OUTSB + FMDIV_BITS + 1 + 6 - FMVOL_SFTBIT - 8);                  samp_l >>= (OPM_OUTSB + FMDIV_BITS + 1 + 6 - FMVOL_SFTBIT - 8);
                 pcm[0] += samp_l;                  pcm[0] += samp_l;
                 samp_r += opngen.outdr * opngen.calcremain;                  samp_r += opngen.outdr * opngen.calcremain;
                 samp_r >>= FMDIV_BITS;                  samp_r >>= 8;
                 samp_r *= opncfg.fmvol;                  samp_r *= opncfg.fmvol;
                 samp_r >>= (OPM_OUTSB + FMDIV_BITS + 1 + 6 - FMVOL_SFTBIT - 8);                  samp_r >>= (OPM_OUTSB + FMDIV_BITS + 1 + 6 - FMVOL_SFTBIT - 8);
                 pcm[1] += samp_r;                  pcm[1] += samp_r;
Line 200  void SOUNDCALL opngen_getpcmvr(void *hdl Line 200  void SOUNDCALL opngen_getpcmvr(void *hdl
                 samp_l >>= (OPM_OUTSB + FMDIV_BITS + 1 + 6 - FMVOL_SFTBIT - 8);                  samp_l >>= (OPM_OUTSB + FMDIV_BITS + 1 + 6 - FMVOL_SFTBIT - 8);
                 pcm[0] += samp_l;                  pcm[0] += samp_l;
                 samp_r += opngen.outdr * opngen.calcremain;                  samp_r += opngen.outdr * opngen.calcremain;
                 samp_r >>= FMDIV_BITS;                  samp_r >>= 8;
                 samp_r *= opncfg.fmvol;                  samp_r *= opncfg.fmvol;
                 samp_r >>= (OPM_OUTSB + FMDIV_BITS + 1 + 6 - FMVOL_SFTBIT - 8);                  samp_r >>= (OPM_OUTSB + FMDIV_BITS + 1 + 6 - FMVOL_SFTBIT - 8);
                 pcm[1] += samp_r;                  pcm[1] += samp_r;

Removed from v.1.7  
changed lines
  Added in v.1.9


RetroPC.NET-CVS <cvs@retropc.net>