git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@9493 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale
2008-09-09 17:04:42 +00:00
parent bc5cf34915
commit ea964d8fe6
79 changed files with 2804 additions and 1642 deletions

View File

@@ -22,7 +22,7 @@
* License along with this program; if not, write to the Free Software
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*
* $Id: dds_int.c,v 1.9 2008/07/02 14:48:25 steveu Exp $
* $Id: dds_int.c,v 1.10 2008/09/01 16:07:33 steveu Exp $
*/
/*! \file */
@@ -288,4 +288,58 @@ complexi_t dds_complexi_mod(uint32_t *phase_acc, int32_t phase_rate, int scale,
return amp;
}
/*- End of function --------------------------------------------------------*/
complexi16_t dds_lookup_complexi16(uint32_t phase)
{
return complex_seti16(dds_lookup(phase + (1 << 30)), dds_lookup(phase));
}
/*- End of function --------------------------------------------------------*/
complexi16_t dds_complexi16(uint32_t *phase_acc, int32_t phase_rate)
{
complexi16_t amp;
amp = complex_seti16(dds_lookup(*phase_acc + (1 << 30)), dds_lookup(*phase_acc));
*phase_acc += phase_rate;
return amp;
}
/*- End of function --------------------------------------------------------*/
complexi16_t dds_complexi16_mod(uint32_t *phase_acc, int32_t phase_rate, int scale, int32_t phase)
{
complexi16_t amp;
amp = complex_seti16((dds_lookup(*phase_acc + phase + (1 << 30))*scale) >> 15,
(dds_lookup(*phase_acc + phase)*scale) >> 15);
*phase_acc += phase_rate;
return amp;
}
/*- End of function --------------------------------------------------------*/
complexi32_t dds_lookup_complexi32(uint32_t phase)
{
return complex_seti32(dds_lookup(phase + (1 << 30)), dds_lookup(phase));
}
/*- End of function --------------------------------------------------------*/
complexi32_t dds_complexi32(uint32_t *phase_acc, int32_t phase_rate)
{
complexi32_t amp;
amp = complex_seti32(dds_lookup(*phase_acc + (1 << 30)), dds_lookup(*phase_acc));
*phase_acc += phase_rate;
return amp;
}
/*- End of function --------------------------------------------------------*/
complexi32_t dds_complexi32_mod(uint32_t *phase_acc, int32_t phase_rate, int scale, int32_t phase)
{
complexi32_t amp;
amp = complex_seti32((dds_lookup(*phase_acc + phase + (1 << 30))*scale) >> 15,
(dds_lookup(*phase_acc + phase)*scale) >> 15);
*phase_acc += phase_rate;
return amp;
}
/*- End of function --------------------------------------------------------*/
/*- End of file ------------------------------------------------------------*/