[asterisk-commits] dvossel: branch 1.6.0 r205608 - in /branches/1.6.0: ./ include/asterisk/time.h
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Thu Jul 9 11:21:14 CDT 2009
Author: dvossel
Date: Thu Jul 9 11:21:10 2009
New Revision: 205608
URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=205608
Log:
Merged revisions 205600 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk
................
r205600 | dvossel | 2009-07-09 11:19:09 -0500 (Thu, 09 Jul 2009) | 9 lines
Merged revisions 205599 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r205599 | dvossel | 2009-07-09 11:18:09 -0500 (Thu, 09 Jul 2009) | 2 lines
Changing ast_samp2tv to not use floating point.
........
................
Modified:
branches/1.6.0/ (props changed)
branches/1.6.0/include/asterisk/time.h
Propchange: branches/1.6.0/
------------------------------------------------------------------------------
Binary property 'trunk-merged' - no diff available.
Modified: branches/1.6.0/include/asterisk/time.h
URL: http://svn.asterisk.org/svn-view/asterisk/branches/1.6.0/include/asterisk/time.h?view=diff&rev=205608&r1=205607&r2=205608
==============================================================================
--- branches/1.6.0/include/asterisk/time.h (original)
+++ branches/1.6.0/include/asterisk/time.h Thu Jul 9 11:21:10 2009
@@ -172,7 +172,7 @@
AST_INLINE_API(
struct timeval ast_samp2tv(unsigned int _nsamp, unsigned int _rate),
{
- return ast_tv(_nsamp / _rate, (_nsamp % _rate) * (1000000 / (float) _rate));
+ return ast_tv(_nsamp / _rate, ((_nsamp % _rate) * (4000000 / _rate)) / 4); /* this calculation is accurate up to 32000Hz. */
}
)
More information about the asterisk-commits
mailing list