Commit graph

16 commits

Author SHA1 Message Date
Sandor Zsombor Vegh
d4494e6ed7
Arm: Speed up FLOAT2INT16 conversion with Neon
Using Neon for float to int conversion, and introducing platform-
specific function for converting an array of float values to int16.
Also adding appropriate unit test.

Signed-off-by: Jean-Marc Valin <jeanmarcv@google.com>
2025-03-24 10:38:14 -04:00
Jean-Marc Valin
6ba284f22f Fix lrint/lrintf detection
Prevents using lrint/lrintf when compiling with -std=c90 even though the
functions are in libm. This was causing tests to fail, likely due to
incorrect prototypes.
2022-04-02 15:18:07 -04:00
Marcus Asteborg
b816d1da68
Fix trailing whitspace in previous commit
Signed-off-by: Ralph Giles <giles@thaumas.net>
2020-06-13 23:27:20 -07:00
Marcus Asteborg
12c751e05c
Prefer SSE and ASM implementation of float2int before lrintf for MSVC
Signed-off-by: Jean-Marc Valin <jmvalin@jmvalin.ca>
2020-06-14 02:06:27 -04:00
Jean-Marc Valin
55480908be
Make float2int() static with VS
Addresses the rest of https://github.com/xiph/opus/pull/79
2018-10-31 02:36:17 -04:00
Pavel P
4d523a9fd2
Proper detection of _mm_cvtss_si32 for MS compiler
Signed-off-by: Jean-Marc Valin <jmvalin@jmvalin.ca>
2018-10-16 15:59:48 -04:00
Jean-Marc Valin
cd159fd1ec Making gcc use SSE directly for float->int conversion when available 2016-08-13 02:53:12 -04:00
Cameron Gutman
8921f82fb9 float_cast: Fix MSVC ARM build
Signed-off-by: Tristan Matthews <tmatth@videolan.org>
2014-11-19 03:04:14 -05:00
Gregory Maxwell
7830cf1bd2 Replace "inline" with OPUS_INLINE.
Newer versions of MSVC are unhappy with the strategy of the build
 environment redefining "inline" (even though they don't support the
 actual keyword). Instead we define OPUS_INLINE to the right thing
 in opus_defines.h.

This is the same approach we use for restrict.
2013-10-28 10:18:54 -07:00
Rafaël Carré
7909d8af20 Guard _MSC_VER tests, remove FLOAT2INT16 when DISABLE_FLOAT_API. 2012-07-26 14:26:43 -04:00
Gregory Maxwell
27a0a5fa46 Avoid using win32 lrintf ASM on mingw even when config.h is broken. 2012-07-07 02:01:44 -04:00
Jean-Marc Valin
cb05e7cd96 s/FOUNDATION/COPYRIGHT OWNER/ in CELT code and "glue code"
Also added 3rd clause to "master" COPYING file
2012-04-20 16:41:42 -04:00
Jean-Marc Valin
66820f350d Tweaks the CELT fractional resampling delay to get perfect alignment
Also using the same int->float conversion functions for SILK as for CELT
and changed encoder implementation default to constrained VBR just to
be safe when VBR gets more aggressive.
2012-01-31 02:18:05 -05:00
Ralph Giles
da025d5632 Convert tabs to spaces in the opus and celt code.
Also reformat some, but by no means all, of the opus
code for line length and three-character indents.
2011-10-26 20:24:49 -07:00
Gregory Maxwell
f7bf43b3e9 Some fixes for C89 builds. 2011-09-19 15:56:48 -04:00
Jean-Marc Valin
c37499090b renames the libcelt/ directory to celt/ 2011-09-13 18:21:18 -07:00
Renamed from libcelt/float_cast.h (Browse further)