Squashed commit of the following:
authorKoen Vos <koen.vos@skype.net>
Mon, 2 May 2011 14:01:10 +0000 (10:01 -0400)
committerJean-Marc Valin <jean-marc.valin@octasic.com>
Mon, 2 May 2011 14:01:10 +0000 (10:01 -0400)
commit dfe4d46f9abf6b0e96e66370d428da4e283204ce
Author: Jean-Marc Valin <jean-marc.valin@octasic.com>
Date:   Mon May 2 09:59:45 2011 -0400

    SILK file list update

commit 5faf541d86445eb8ce1775ea206e88afe83c7107
Author: Jean-Marc Valin <jean-marc.valin@octasic.com>
Date:   Mon May 2 09:51:29 2011 -0400

    Makefiles update

commit f5d70b3ccbe209cc07a1a604fffca93ea34bc64b
Author: Koen Vos <koen.vos@skype.net>
Date:   Mon May 2 09:50:33 2011 -0400

    SILK stereo update and MSVC build update

62 files changed:
Makefile.draft
libcelt/libcelt.vcxproj
libcelt/libcelt.vcxproj.filters
libcelt/match-test.sh [changed mode: 0755->0644]
opus.sln
silk/SKP_Silk_Inlines.h
silk/SKP_Silk_LPC_analysis_filter.c
silk/SKP_Silk_LP_variable_cutoff.c
silk/SKP_Silk_assembler_FLP.h [deleted file]
silk/SKP_Silk_control_codec.c
silk/SKP_Silk_dec_API.c
silk/SKP_Silk_decode_core.c
silk/SKP_Silk_define.h
silk/SKP_Silk_enc_API.c
silk/SKP_Silk_init_encoder.c
silk/SKP_Silk_main.h
silk/SKP_Silk_stereo_LR_to_MS.c
silk/SKP_Silk_stereo_MS_to_LR.c
silk/SKP_Silk_stereo_decode_pred.c [new file with mode: 0644]
silk/SKP_Silk_stereo_encode_pred.c [new file with mode: 0644]
silk/SKP_Silk_stereo_find_predictor.c [new file with mode: 0644]
silk/SKP_Silk_structs.h
silk/SKP_Silk_tables.h
silk/SKP_Silk_tables_other.c
silk/fixed/SKP_Silk_encode_frame_FIX.c
silk/fixed/SKP_Silk_find_pred_coefs_FIX.c
silk/fixed/SKP_Silk_main_FIX.h [moved from silk/SKP_Silk_main_FIX.h with 97% similarity]
silk/fixed/SKP_Silk_structs_FIX.h [moved from silk/SKP_Silk_structs_FIX.h with 100% similarity]
silk/fixed/silk_fixed.vcxproj [moved from silk/src_FIX.vcxproj with 85% similarity]
silk/fixed/silk_fixed.vcxproj.filters [moved from silk/src_FIX.vcxproj.filters with 97% similarity]
silk/float/SKP_Silk_LPC_analysis_filter_FLP.c
silk/float/SKP_Silk_LPC_inv_pred_gain_FLP.c [moved from silk/SKP_Silk_LPC_inv_pred_gain_FLP.c with 100% similarity]
silk/float/SKP_Silk_SigProc_FLP.h [moved from silk/SKP_Silk_SigProc_FLP.h with 100% similarity]
silk/float/SKP_Silk_autocorrelation_FLP.c [moved from silk/SKP_Silk_autocorrelation_FLP.c with 100% similarity]
silk/float/SKP_Silk_burg_modified_FLP.c [moved from silk/SKP_Silk_burg_modified_FLP.c with 100% similarity]
silk/float/SKP_Silk_bwexpander_FLP.c [moved from silk/SKP_Silk_bwexpander_FLP.c with 100% similarity]
silk/float/SKP_Silk_encode_frame_FLP.c
silk/float/SKP_Silk_energy_FLP.c [moved from silk/SKP_Silk_energy_FLP.c with 100% similarity]
silk/float/SKP_Silk_find_pred_coefs_FLP.c
silk/float/SKP_Silk_inner_product_FLP.c [moved from silk/SKP_Silk_inner_product_FLP.c with 95% similarity]
silk/float/SKP_Silk_k2a_FLP.c [moved from silk/SKP_Silk_k2a_FLP.c with 100% similarity]
silk/float/SKP_Silk_levinsondurbin_FLP.c [moved from silk/SKP_Silk_levinsondurbin_FLP.c with 100% similarity]
silk/float/SKP_Silk_main_FLP.h [moved from silk/SKP_Silk_main_FLP.h with 97% similarity]
silk/float/SKP_Silk_pitch_analysis_core_FLP.c [moved from silk/SKP_Silk_pitch_analysis_core_FLP.c with 100% similarity]
silk/float/SKP_Silk_scale_copy_vector_FLP.c [moved from silk/SKP_Silk_scale_copy_vector_FLP.c with 100% similarity]
silk/float/SKP_Silk_scale_vector_FLP.c [moved from silk/SKP_Silk_scale_vector_FLP.c with 100% similarity]
silk/float/SKP_Silk_schur_FLP.c [moved from silk/SKP_Silk_schur_FLP.c with 100% similarity]
silk/float/SKP_Silk_sort_FLP.c [moved from silk/SKP_Silk_sort_FLP.c with 100% similarity]
silk/float/SKP_Silk_structs_FLP.h [moved from silk/SKP_Silk_structs_FLP.h with 96% similarity]
silk/float/silk_float.vcxproj [moved from silk/src_FLP.vcxproj with 74% similarity]
silk/float/silk_float.vcxproj.filters [moved from silk/src_FLP.vcxproj.filters with 65% similarity]
silk/silk_common.vcxproj [moved from silk/src_SigProc_FIX.vcxproj with 59% similarity]
silk/silk_common.vcxproj.filters [moved from silk/src_SigProc_FIX.vcxproj.filters with 51% similarity]
silk/src_SigProc_FLP.vcxproj [deleted file]
silk/src_SigProc_FLP.vcxproj.filters [deleted file]
silk/src_common.vcxproj [deleted file]
silk/src_common.vcxproj.filters [deleted file]
silk_headers.txt
silk_sources.mk
src/opus.vcxproj [moved from src/hybrid.vcxproj with 81% similarity]
src/opus.vcxproj.filters [moved from src/hybrid.vcxproj.filters with 90% similarity]
win32/config.h

index b1bfb6d..20b178c 100644 (file)
@@ -62,6 +62,8 @@ ARCHIVE.cmdline     = $(AR) $(ARFLAGS) $@ $^ && $(RANLIB) $@
 # Directives
 
 CINCLUDES += silk/ \
+        silk/float/ \
+        silk/fixed/ \
        libcelt/ \
        src/
 
index ba2af56..fe04999 100644 (file)
@@ -45,7 +45,7 @@
       <WarningLevel>Level3</WarningLevel>\r
       <Optimization>Disabled</Optimization>\r
       <PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>..\msvc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\r
+      <AdditionalIncludeDirectories>..\win32;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\r
     </ClCompile>\r
     <Link>\r
       <SubSystem>Windows</SubSystem>\r
@@ -61,7 +61,7 @@
       <FunctionLevelLinking>true</FunctionLevelLinking>\r
       <IntrinsicFunctions>true</IntrinsicFunctions>\r
       <PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>..\msvc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\r
+      <AdditionalIncludeDirectories>..\win32;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\r
     </ClCompile>\r
     <Link>\r
       <SubSystem>Windows</SubSystem>\r
@@ -74,6 +74,7 @@
     <None Include="ReadMe.txt" />\r
   </ItemGroup>\r
   <ItemGroup>\r
+    <ClInclude Include="..\..\win32\config.h" />\r
     <ClInclude Include="..\msvc\config.h" />\r
     <ClInclude Include="arch.h" />\r
     <ClInclude Include="bands.h" />\r
index 2967ebf..5c53e5c 100644 (file)
@@ -96,6 +96,9 @@
     <ClInclude Include="..\msvc\config.h">\r
       <Filter>Header Files</Filter>\r
     </ClInclude>\r
+    <ClInclude Include="..\..\win32\config.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
   </ItemGroup>\r
   <ItemGroup>\r
     <ClCompile Include="bands.c">\r
old mode 100755 (executable)
new mode 100644 (file)
index 7525308..2df4309 100644 (file)
--- a/opus.sln
+++ b/opus.sln
@@ -1,43 +1,15 @@
 \r
 Microsoft Visual Studio Solution File, Format Version 11.00\r
 # Visual Studio 2010\r
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "opus", "src\hybrid.vcxproj", "{219EC965-228A-1824-174D-96449D05F88A}"\r
-       ProjectSection(ProjectDependencies) = postProject\r
-               {8484C90D-1561-402F-A91D-2DB10F8C5171} = {8484C90D-1561-402F-A91D-2DB10F8C5171}\r
-               {9C4961D2-5DDB-40C7-9BE8-CA918DC4E782} = {9C4961D2-5DDB-40C7-9BE8-CA918DC4E782}\r
-               {245603E3-F580-41A5-9632-B25FE3372CBF} = {245603E3-F580-41A5-9632-B25FE3372CBF}\r
-               {C303D2FC-FF97-49B8-9DDD-467B4C9A0B16} = {C303D2FC-FF97-49B8-9DDD-467B4C9A0B16}\r
-       EndProjectSection\r
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "silk_common", "silk\silk_common.vcxproj", "{C303D2FC-FF97-49B8-9DDD-467B4C9A0B16}"\r
 EndProject\r
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libcelt", "celt\libcelt\libcelt.vcxproj", "{245603E3-F580-41A5-9632-B25FE3372CBF}"\r
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "opus", "src\opus.vcxproj", "{219EC965-228A-1824-174D-96449D05F88A}"\r
 EndProject\r
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "src_common", "silk\src_common\src_common.vcxproj", "{C303D2FC-FF97-49B8-9DDD-467B4C9A0B16}"\r
-       ProjectSection(ProjectDependencies) = postProject\r
-               {245603E3-F580-41A5-9632-B25FE3372CBF} = {245603E3-F580-41A5-9632-B25FE3372CBF}\r
-       EndProjectSection\r
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "silk_fixed", "silk\fixed\silk_fixed.vcxproj", "{8484C90D-1561-402F-A91D-2DB10F8C5171}"\r
 EndProject\r
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "src_SigProc_FIX", "silk\src_SigProc_FIX\src_SigProc_FIX.vcxproj", "{950F7176-3D29-4CBF-8C40-58B918EAEBB2}"\r
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "silk_float", "silk\float\silk_float.vcxproj", "{9C4961D2-5DDB-40C7-9BE8-CA918DC4E782}"\r
 EndProject\r
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "src_SigProc_FLP", "silk\src_SigProc_FLP\src_SigProc_FLP.vcxproj", "{06D10292-A23C-4C5E-9C0F-28737769206F}"\r
-       ProjectSection(ProjectDependencies) = postProject\r
-               {950F7176-3D29-4CBF-8C40-58B918EAEBB2} = {950F7176-3D29-4CBF-8C40-58B918EAEBB2}\r
-       EndProjectSection\r
-EndProject\r
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "src_FIX", "silk\src_FIX\src_FIX.vcxproj", "{8484C90D-1561-402F-A91D-2DB10F8C5171}"\r
-       ProjectSection(ProjectDependencies) = postProject\r
-               {950F7176-3D29-4CBF-8C40-58B918EAEBB2} = {950F7176-3D29-4CBF-8C40-58B918EAEBB2}\r
-               {06D10292-A23C-4C5E-9C0F-28737769206F} = {06D10292-A23C-4C5E-9C0F-28737769206F}\r
-               {245603E3-F580-41A5-9632-B25FE3372CBF} = {245603E3-F580-41A5-9632-B25FE3372CBF}\r
-               {C303D2FC-FF97-49B8-9DDD-467B4C9A0B16} = {C303D2FC-FF97-49B8-9DDD-467B4C9A0B16}\r
-       EndProjectSection\r
-EndProject\r
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "src_FLP", "silk\src_FLP\src_FLP.vcxproj", "{9C4961D2-5DDB-40C7-9BE8-CA918DC4E782}"\r
-       ProjectSection(ProjectDependencies) = postProject\r
-               {950F7176-3D29-4CBF-8C40-58B918EAEBB2} = {950F7176-3D29-4CBF-8C40-58B918EAEBB2}\r
-               {06D10292-A23C-4C5E-9C0F-28737769206F} = {06D10292-A23C-4C5E-9C0F-28737769206F}\r
-               {245603E3-F580-41A5-9632-B25FE3372CBF} = {245603E3-F580-41A5-9632-B25FE3372CBF}\r
-               {C303D2FC-FF97-49B8-9DDD-467B4C9A0B16} = {C303D2FC-FF97-49B8-9DDD-467B4C9A0B16}\r
-       EndProjectSection\r
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libcelt", "libcelt\libcelt.vcxproj", "{245603E3-F580-41A5-9632-B25FE3372CBF}"\r
 EndProject\r
 Global\r
        GlobalSection(SolutionConfigurationPlatforms) = preSolution\r
@@ -45,26 +17,14 @@ Global
                Release|Win32 = Release|Win32\r
        EndGlobalSection\r
        GlobalSection(ProjectConfigurationPlatforms) = postSolution\r
-               {219EC965-228A-1824-174D-96449D05F88A}.Debug|Win32.ActiveCfg = Debug|Win32\r
-               {219EC965-228A-1824-174D-96449D05F88A}.Debug|Win32.Build.0 = Debug|Win32\r
-               {219EC965-228A-1824-174D-96449D05F88A}.Release|Win32.ActiveCfg = Release|Win32\r
-               {219EC965-228A-1824-174D-96449D05F88A}.Release|Win32.Build.0 = Release|Win32\r
-               {245603E3-F580-41A5-9632-B25FE3372CBF}.Debug|Win32.ActiveCfg = Debug|Win32\r
-               {245603E3-F580-41A5-9632-B25FE3372CBF}.Debug|Win32.Build.0 = Debug|Win32\r
-               {245603E3-F580-41A5-9632-B25FE3372CBF}.Release|Win32.ActiveCfg = Release|Win32\r
-               {245603E3-F580-41A5-9632-B25FE3372CBF}.Release|Win32.Build.0 = Release|Win32\r
                {C303D2FC-FF97-49B8-9DDD-467B4C9A0B16}.Debug|Win32.ActiveCfg = Debug|Win32\r
                {C303D2FC-FF97-49B8-9DDD-467B4C9A0B16}.Debug|Win32.Build.0 = Debug|Win32\r
                {C303D2FC-FF97-49B8-9DDD-467B4C9A0B16}.Release|Win32.ActiveCfg = Release|Win32\r
                {C303D2FC-FF97-49B8-9DDD-467B4C9A0B16}.Release|Win32.Build.0 = Release|Win32\r
-               {950F7176-3D29-4CBF-8C40-58B918EAEBB2}.Debug|Win32.ActiveCfg = Debug|Win32\r
-               {950F7176-3D29-4CBF-8C40-58B918EAEBB2}.Debug|Win32.Build.0 = Debug|Win32\r
-               {950F7176-3D29-4CBF-8C40-58B918EAEBB2}.Release|Win32.ActiveCfg = Release|Win32\r
-               {950F7176-3D29-4CBF-8C40-58B918EAEBB2}.Release|Win32.Build.0 = Release|Win32\r
-               {06D10292-A23C-4C5E-9C0F-28737769206F}.Debug|Win32.ActiveCfg = Debug|Win32\r
-               {06D10292-A23C-4C5E-9C0F-28737769206F}.Debug|Win32.Build.0 = Debug|Win32\r
-               {06D10292-A23C-4C5E-9C0F-28737769206F}.Release|Win32.ActiveCfg = Release|Win32\r
-               {06D10292-A23C-4C5E-9C0F-28737769206F}.Release|Win32.Build.0 = Release|Win32\r
+               {219EC965-228A-1824-174D-96449D05F88A}.Debug|Win32.ActiveCfg = Debug|Win32\r
+               {219EC965-228A-1824-174D-96449D05F88A}.Debug|Win32.Build.0 = Debug|Win32\r
+               {219EC965-228A-1824-174D-96449D05F88A}.Release|Win32.ActiveCfg = Release|Win32\r
+               {219EC965-228A-1824-174D-96449D05F88A}.Release|Win32.Build.0 = Release|Win32\r
                {8484C90D-1561-402F-A91D-2DB10F8C5171}.Debug|Win32.ActiveCfg = Debug|Win32\r
                {8484C90D-1561-402F-A91D-2DB10F8C5171}.Debug|Win32.Build.0 = Debug|Win32\r
                {8484C90D-1561-402F-A91D-2DB10F8C5171}.Release|Win32.ActiveCfg = Release|Win32\r
@@ -73,6 +33,10 @@ Global
                {9C4961D2-5DDB-40C7-9BE8-CA918DC4E782}.Debug|Win32.Build.0 = Debug|Win32\r
                {9C4961D2-5DDB-40C7-9BE8-CA918DC4E782}.Release|Win32.ActiveCfg = Release|Win32\r
                {9C4961D2-5DDB-40C7-9BE8-CA918DC4E782}.Release|Win32.Build.0 = Release|Win32\r
+               {245603E3-F580-41A5-9632-B25FE3372CBF}.Debug|Win32.ActiveCfg = Debug|Win32\r
+               {245603E3-F580-41A5-9632-B25FE3372CBF}.Debug|Win32.Build.0 = Debug|Win32\r
+               {245603E3-F580-41A5-9632-B25FE3372CBF}.Release|Win32.ActiveCfg = Release|Win32\r
+               {245603E3-F580-41A5-9632-B25FE3372CBF}.Release|Win32.Build.0 = Release|Win32\r
        EndGlobalSection\r
        GlobalSection(SolutionProperties) = preSolution\r
                HideSolutionNode = FALSE\r
index 43c9d0a..49c69e5 100644 (file)
@@ -151,7 +151,7 @@ SKP_INLINE SKP_int32 SKP_DIV32_varQ(    /* O    returns a good approximation of
 \r
     /* Convert to Qres domain */\r
     lshift = 29 + a_headrm - b_headrm - Qres;\r
-    if( lshift <= 0 ) {\r
+    if( lshift < 0 ) {\r
         return SKP_LSHIFT_SAT32(result, -lshift);\r
     } else {\r
         if( lshift < 32){\r
index 6029ae6..ba9475b 100644 (file)
@@ -73,7 +73,4 @@ void SKP_Silk_LPC_analysis_filter(
         /* Saturate output */\r
         out[ ix ] = ( SKP_int16 )SKP_SAT16( out32 );\r
     }\r
-\r
-    /* Set first LPC d samples to zero instead of undefined */\r
-    SKP_memset( out, 0, d * sizeof( SKP_int16 ) );\r
 }\r
index f95bbc9..7654c50 100644 (file)
@@ -63,7 +63,6 @@ SKP_INLINE void SKP_Silk_LP_interpolate_filter_taps(
                         fac_Q16 );\r
                 }\r
             } else { /* ( fac_Q16 - ( 1 << 16 ) ) is in range of a 16-bit int */\r
-                \r
                 SKP_assert( fac_Q16 - ( 1 << 16 ) == SKP_SAT16( fac_Q16 - ( 1 << 16 ) ) );\r
                 /* Piece-wise linear interpolation of B and A */\r
                 for( nb = 0; nb < TRANSITION_NB; nb++ ) {\r
@@ -106,7 +105,7 @@ void SKP_Silk_LP_variable_cutoff(
 \r
     SKP_assert( psLP->transition_frame_no >= 0 && psLP->transition_frame_no <= TRANSITION_FRAMES );\r
 \r
-    /* Interpolate filter coefficients if needed */\r
+    /* Run filter if needed */\r
     if( psLP->mode != 0 ) {\r
         /* Calculate index and interpolation factor for interpolation */\r
 #if( TRANSITION_INT_STEPS == 64 )\r
diff --git a/silk/SKP_Silk_assembler_FLP.h b/silk/SKP_Silk_assembler_FLP.h
deleted file mode 100644 (file)
index e4129ad..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-/***********************************************************************\r
-Copyright (c) 2006-2011, Skype Limited. All rights reserved. \r
-Redistribution and use in source and binary forms, with or without \r
-modification, (subject to the limitations in the disclaimer below) \r
-are permitted provided that the following conditions are met:\r
-- Redistributions of source code must retain the above copyright notice,\r
-this list of conditions and the following disclaimer.\r
-- Redistributions in binary form must reproduce the above copyright \r
-notice, this list of conditions and the following disclaimer in the \r
-documentation and/or other materials provided with the distribution.\r
-- Neither the name of Skype Limited, nor the names of specific \r
-contributors, may be used to endorse or promote products derived from \r
-this software without specific prior written permission.\r
-NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE GRANTED \r
-BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND \r
-CONTRIBUTORS ''AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING,\r
-BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND \r
-FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE \r
-COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, \r
-INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT\r
-NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF \r
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON \r
-ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT \r
-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE \r
-OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
-***********************************************************************/\r
-\r
-#ifndef SKP_SILK_ASSEMBLER_FLP_H\r
-#define SKP_SILK_ASSEMBLER_FLP_H\r
-\r
-#include "SKP_Silk_typedef.h"\r
-\r
-/* Declaration of assembler functions */\r
-\r
-void SKP_Silk_LPC_ana_sse( \r
-       float                                                   *r_LPC,                         /* O    LPC residual signal                                             */\r
-       const float                                             *coefs,                         /* I    LPC coefficients                                                */\r
-       const float                                             *speech,                        /* I    Input signal                                                    */\r
-       int                                                             len                                     /* I    Length of input signal                                  */\r
-);\r
-\r
-#endif\r
index 0beb245..4356330 100644 (file)
@@ -25,12 +25,8 @@ ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
 ***********************************************************************/\r
 \r
-#ifdef HAVE_CONFIG_H\r
-#include "config.h"\r
-#endif\r
-\r
 #include "SKP_Silk_tuning_parameters.h"\r
-#if FIXED_POINT\r
+#ifdef FIXED_POINT\r
 #include "SKP_Silk_main_FIX.h"\r
 #define SKP_Silk_encoder_state_Fxx      SKP_Silk_encoder_state_FIX\r
 #else\r
@@ -64,8 +60,9 @@ SKP_INLINE SKP_int SKP_Silk_setup_LBRR(
 SKP_int SKP_Silk_control_encoder( \r
     SKP_Silk_encoder_state_Fxx      *psEnc,             /* I/O  Pointer to Silk encoder state           */\r
     SKP_SILK_SDK_EncControlStruct   *encControl,        /* I:   Control structure                       */\r
-    const SKP_int32                 TargetRate_bps,      /* I    Target max bitrate (bps)                */\r
-    const SKP_int                   allow_bw_switch     /* I    Flag to allow switching audio bandwidth */\r
+    const SKP_int32                 TargetRate_bps,     /* I    Target max bitrate (bps)                */\r
+    const SKP_int                   allow_bw_switch,    /* I    Flag to allow switching audio bandwidth */\r
+    const SKP_int                   channelNb           /* I    Channel number                          */\r
 )\r
 {\r
     SKP_int   fs_kHz, ret = 0;\r
@@ -77,7 +74,9 @@ SKP_int SKP_Silk_control_encoder(
     psEnc->sCmn.minInternal_fs_Hz      = encControl->minInternalSampleRate;\r
     psEnc->sCmn.desiredInternal_fs_Hz  = encControl->desiredInternalSampleRate;\r
     psEnc->sCmn.useInBandFEC           = encControl->useInBandFEC;\r
+    psEnc->sCmn.nChannels              = encControl->nChannels;\r
     psEnc->sCmn.allow_bandwidth_switch = allow_bw_switch;\r
+    psEnc->sCmn.channelNb              = channelNb;\r
 \r
     if( psEnc->sCmn.controlled_since_last_payload != 0 && psEnc->sCmn.prefillFlag == 0 ) {\r
         if( psEnc->sCmn.API_fs_Hz != psEnc->sCmn.prev_API_fs_Hz && psEnc->sCmn.fs_kHz > 0 ) {\r
@@ -140,7 +139,7 @@ SKP_int SKP_Silk_setup_resamplers(
         } else {\r
             /* Allocate space for worst case temporary upsampling, 8 to 48 kHz, so a factor 6 */\r
             SKP_int16 x_buf_API_fs_Hz[ ( 2 * MAX_FRAME_LENGTH + LA_SHAPE_MAX ) * ( MAX_API_FS_KHZ / 8 ) ];\r
-#if FIXED_POINT\r
+#ifdef FIXED_POINT\r
             SKP_int16 *x_bufFIX = psEnc->x_buf;\r
 #else\r
             SKP_int16 x_bufFIX[ 2 * MAX_FRAME_LENGTH + LA_SHAPE_MAX ]; \r
@@ -148,7 +147,7 @@ SKP_int SKP_Silk_setup_resamplers(
 \r
             nSamples_temp = SKP_LSHIFT( psEnc->sCmn.frame_length, 1 ) + LA_SHAPE_MS * psEnc->sCmn.fs_kHz;\r
 \r
-#if !FIXED_POINT\r
+#ifndef FIXED_POINT\r
             SKP_float2short_array( x_bufFIX, psEnc->x_buf, nSamples_temp );\r
 #endif\r
 \r
@@ -178,7 +177,7 @@ SKP_int SKP_Silk_setup_resamplers(
                 /* Correct resampler state (unless resampling by a factor 1) by resampling buffered data from API_fs_Hz to fs_kHz */\r
                 ret += SKP_Silk_resampler( &psEnc->sCmn.resampler_state, x_bufFIX, x_buf_API_fs_Hz, nSamples_temp );\r
             }\r
-#if !FIXED_POINT\r
+#ifndef FIXED_POINT\r
             SKP_short2float_array( psEnc->x_buf, x_bufFIX, ( 2 * MAX_FRAME_LENGTH_MS + LA_SHAPE_MS ) * fs_kHz );\r
 #endif\r
         }\r
@@ -235,7 +234,7 @@ SKP_int SKP_Silk_setup_fs(
     SKP_assert( psEnc->sCmn.nb_subfr == 2 || psEnc->sCmn.nb_subfr == 4 );\r
     if( psEnc->sCmn.fs_kHz != fs_kHz ) {\r
         /* reset part of the state */\r
-#if FIXED_POINT\r
+#ifdef FIXED_POINT\r
         SKP_memset( &psEnc->sShape,               0, sizeof( SKP_Silk_shape_state_FIX ) );\r
         SKP_memset( &psEnc->sPrefilt,             0, sizeof( SKP_Silk_prefilter_state_FIX ) );\r
 #else\r
index 7d046f4..6340f2d 100644 (file)
@@ -31,14 +31,15 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 #include "SKP_Silk_SDK_API.h"\r
 #include "SKP_Silk_main.h"\r
 \r
+/************************/\r
 /* Decoder Super Struct */\r
+/************************/\r
 typedef struct {\r
     SKP_Silk_decoder_state          channel_state[ DECODER_NUM_CHANNELS ];\r
     stereo_state                    sStereo;\r
     SKP_int                         nChannels;\r
 } SKP_Silk_decoder;\r
 \r
-\r
 /*********************/\r
 /* Decoder functions */\r
 /*********************/\r
@@ -78,10 +79,11 @@ SKP_int SKP_Silk_SDK_Decode(
     SKP_int32                           *nSamplesOut    /* O:   Number of samples decoded                       */\r
 )\r
 {\r
-    SKP_int   i, n, prev_fs_kHz, doResample, flags, nFlags, MS_predictorIx, ret = SKP_SILK_NO_ERROR;\r
+    SKP_int   i, n, prev_fs_kHz, doResample, flags, nFlags, ret = SKP_SILK_NO_ERROR;\r
     SKP_int32 nSamplesOutDec, LBRR_symbol;\r
     SKP_int16 samplesOut1_tmp[ 2 * MAX_FS_KHZ * MAX_FRAME_LENGTH_MS ];\r
     SKP_int16 samplesOut2_tmp[ MAX_API_FS_KHZ * MAX_FRAME_LENGTH_MS ];\r
+    SKP_int   MS_pred_Q14[ 2 ] = { 0 };\r
     SKP_int16 *dec_out_ptr, *resample_out_ptr;\r
     SKP_Silk_decoder *psDec = ( SKP_Silk_decoder * )decState;\r
     SKP_Silk_decoder_state *channel_state = psDec->channel_state;\r
@@ -200,7 +202,7 @@ SKP_int SKP_Silk_SDK_Decode(
 \r
     /* Get MS predictor index */\r
     if( decControl->nChannels == 2 ) {\r
-        MS_predictorIx = ec_dec_icdf( psRangeDec, SKP_Silk_stereo_predictor_iCDF, 8 );\r
+        SKP_Silk_stereo_decode_pred( psRangeDec, MS_pred_Q14 );\r
     }\r
 \r
     /* Call decoder for one frame */\r
@@ -210,7 +212,7 @@ SKP_int SKP_Silk_SDK_Decode(
 \r
     /* Convert Mid/Side to Left/Right */\r
     if( decControl->nChannels == 2 ) {\r
-        SKP_Silk_stereo_MS_to_LR( &psDec->sStereo, dec_out_ptr, &dec_out_ptr[ MAX_FS_KHZ * MAX_FRAME_LENGTH_MS ], MS_predictorIx, channel_state[ 0 ].fs_kHz, nSamplesOutDec );\r
+        SKP_Silk_stereo_MS_to_LR( &psDec->sStereo, dec_out_ptr, &dec_out_ptr[ MAX_FS_KHZ * MAX_FRAME_LENGTH_MS ], MS_pred_Q14, channel_state[ 0 ].fs_kHz, nSamplesOutDec );\r
     }\r
 \r
     /* Number of output samples */\r
index ef8c57b..3c795f5 100644 (file)
@@ -164,7 +164,7 @@ void SKP_Silk_decode_core(
                 LTP_pred_Q14 = SKP_SMLAWB( LTP_pred_Q14, pred_lag_ptr[ -4 ], B_Q14[ 4 ] );\r
                 pred_lag_ptr++;\r
             \r
-                /* Generate LPC residual */ \r
+                /* Generate LPC excitation */ \r
                 pres_Q10[ i ] = SKP_ADD32( pexc_Q10[ i ], SKP_RSHIFT_ROUND( LTP_pred_Q14, 4 ) );\r
             \r
                 /* Update states */\r
@@ -196,7 +196,7 @@ void SKP_Silk_decode_core(
                 LPC_pred_Q10 = SKP_SMLAWB( LPC_pred_Q10, psDec->sLPC_Q14[ MAX_LPC_ORDER + i - j - 1 ], A_Q12_tmp[ j ] );\r
             }\r
 \r
-            /* Add prediction to LPC residual */\r
+            /* Add prediction to LPC excitation */\r
             vec_Q10[ i ] = SKP_ADD32( pres_Q10[ i ], LPC_pred_Q10 );\r
 \r
             /* Update states */\r
index adefef8..22917fa 100644 (file)
@@ -47,10 +47,6 @@ extern "C"
 \r
 #define MAX_FRAMES_PER_PACKET                   3\r
 \r
-#ifndef FIXED_POINT\r
-#    define FIXED_POINT                         0\r
-#endif\r
-\r
 /* Limits on bitrate */\r
 #define MIN_TARGET_RATE_BPS                     5000\r
 #define MAX_TARGET_RATE_BPS                     80000\r
@@ -78,9 +74,9 @@ extern "C"
 #define TYPE_VOICED                             2\r
 \r
 /* Setting for stereo processing */\r
-#define STEREO_QUANT_STEPS                      15\r
-#define STEREO_QUANT_HYSTERESIS                 0.25\r
-#define STEREO_INTERPOL_LENGTH_MS               10\r
+#define STEREO_QUANT_TAB_SIZE                   16\r
+#define STEREO_QUANT_SUB_STEPS                  5\r
+#define STEREO_INTERP_LEN_MS                    8           /* must be even */\r
 \r
 /* Range of pitch lag estimates */\r
 #define PITCH_EST_MIN_LAG_MS                    2           /* 2 ms -> 500 Hz */\r
index 5c23d99..fd092c0 100644 (file)
@@ -25,9 +25,6 @@ ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
 ***********************************************************************/\r
 \r
-#ifdef HAVE_CONFIG_H\r
-#include "config.h"\r
-#endif\r
 \r
 #include "SKP_Silk_define.h"\r
 #include "SKP_Silk_SDK_API.h"\r
@@ -35,7 +32,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 #include "SKP_Silk_typedef.h"\r
 #include "SKP_Silk_structs.h"\r
 #include "SKP_Silk_tuning_parameters.h"\r
-#if FIXED_POINT\r
+#ifdef FIXED_POINT\r
 #include "SKP_Silk_main_FIX.h"\r
 #define SKP_Silk_encoder_state_Fxx      SKP_Silk_encoder_state_FIX\r
 #define SKP_Silk_encode_frame_Fxx       SKP_Silk_encode_frame_FIX\r
@@ -142,11 +139,12 @@ SKP_int SKP_Silk_SDK_Encode(
     const SKP_int                       prefillFlag     /* I:   Flag to indicate prefilling buffers; no coding  */\r
 )\r
 {\r
-    SKP_int   n, i, nBits, flags, tmp_payloadSize_ms, tmp_complexity, MS_predictorIx = 0, ret = 0;\r
+    SKP_int   n, i, nBits, flags, tmp_payloadSize_ms, tmp_complexity, ret = 0;\r
     SKP_int   nSamplesToBuffer, nBlocksOf10ms, nSamplesFromInput = 0;\r
     SKP_int   speech_act_thr_for_switch_Q8;\r
     SKP_int32 TargetRate_bps, channelRate_bps, LBRR_symbol;\r
     SKP_Silk_encoder *psEnc = ( SKP_Silk_encoder * )encState;\r
+    SKP_int   MS_predictorIx[ 2 ] = { 0 };\r
     SKP_int16 buf[ MAX_FRAME_LENGTH_MS * MAX_API_FS_KHZ ];\r
 \r
     /* Check values in encoder control structure */\r
@@ -201,7 +199,7 @@ SKP_int SKP_Silk_SDK_Encode(
 \r
     TargetRate_bps = SKP_RSHIFT32( encControl->bitRate, encControl->nChannels - 1 );\r
     for( n = 0; n < encControl->nChannels; n++ ) {\r
-        if( ( ret = SKP_Silk_control_encoder( &psEnc->state_Fxx[ n ], encControl, TargetRate_bps, psEnc->allowBandwidthSwitch ) ) != 0 ) {\r
+        if( ( ret = SKP_Silk_control_encoder( &psEnc->state_Fxx[ n ], encControl, TargetRate_bps, psEnc->allowBandwidthSwitch, n ) ) != 0 ) {\r
             SKP_assert( 0 );\r
             return ret;\r
         }\r
@@ -287,9 +285,8 @@ SKP_int SKP_Silk_SDK_Encode(
 \r
             /* Convert Left/Right to Mid/Side */\r
             if( encControl->nChannels == 2 ) {\r
-                SKP_Silk_stereo_LR_to_MS( &psEnc->sStereo, psEnc->state_Fxx[ 0 ].sCmn.inputBuf, psEnc->state_Fxx[ 1 ].sCmn.inputBuf, \r
-                    &MS_predictorIx, psEnc->state_Fxx[ 0 ].sCmn.fs_kHz, psEnc->state_Fxx[ 0 ].sCmn.frame_length );\r
-                ec_enc_icdf( psRangeEnc, MS_predictorIx, SKP_Silk_stereo_predictor_iCDF, 8 );\r
+                SKP_Silk_stereo_LR_to_MS( psRangeEnc, &psEnc->sStereo, psEnc->state_Fxx[ 0 ].sCmn.inputBuf, psEnc->state_Fxx[ 1 ].sCmn.inputBuf, \r
+                    psEnc->state_Fxx[ 0 ].sCmn.fs_kHz, psEnc->state_Fxx[ 0 ].sCmn.frame_length );\r
             }\r
 \r
 \r
@@ -316,12 +313,11 @@ SKP_int SKP_Silk_SDK_Encode(
                 if( encControl->nChannels == 1 ) {\r
                     channelRate_bps = TargetRate_bps;\r
                 } else if( n == 0 ) {\r
-                    channelRate_bps = SKP_SMULWW( TargetRate_bps, SKP_FIX_CONST( 0.6, 16 ) );\r
+                    channelRate_bps = SKP_RSHIFT( TargetRate_bps, 1 ) + 2000;\r
                 } else {\r
-                    channelRate_bps = SKP_SMULWB( TargetRate_bps, SKP_FIX_CONST( 0.4, 16 ) );\r
+                    channelRate_bps = SKP_RSHIFT( TargetRate_bps, 1 ) - 2000;\r
                 }\r
                 SKP_Silk_control_SNR( &psEnc->state_Fxx[ n ].sCmn, channelRate_bps );\r
-                //SKP_Silk_control_SNR( &psEnc->state_Fxx[ n ].sCmn, TargetRate_bps / 2 );\r
                 if( ( ret = SKP_Silk_encode_frame_Fxx( &psEnc->state_Fxx[ n ], nBytesOut, psRangeEnc ) ) != 0 ) {\r
                     SKP_assert( 0 );\r
                 }\r
index 3baf672..2e85ce7 100644 (file)
@@ -25,11 +25,7 @@ ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
 ***********************************************************************/\r
 \r
-#ifdef HAVE_CONFIG_H\r
-#include "config.h"\r
-#endif\r
-\r
-#if FIXED_POINT\r
+#ifdef FIXED_POINT\r
 #include "SKP_Silk_main_FIX.h"\r
 #define SKP_Silk_encoder_state_Fxx      SKP_Silk_encoder_state_FIX\r
 #else\r
index 3aff2df..f80cc80 100644 (file)
@@ -52,10 +52,10 @@ extern "C"
 \r
 /* Convert Left/Right stereo signal to adaptive Mid/Side representation */\r
 void SKP_Silk_stereo_LR_to_MS( \r
+    ec_enc              *psRangeEnc,                    /* I/O  Compressor data structure                   */\r
     stereo_state        *state,                         /* I/O  State                                       */\r
     SKP_int16           x1[],                           /* I/O  Left input signal, becomes mid signal       */\r
     SKP_int16           x2[],                           /* I/O  Right input signal, becomes side signal     */\r
-    SKP_int             *predictorIx,                   /* O    Index for predictor filter                  */\r
     SKP_int             fs_kHz,                         /* I    Samples rate (kHz)                          */\r
     SKP_int             frame_length                    /* I    Number of samples                           */\r
 );\r
@@ -65,11 +65,30 @@ void SKP_Silk_stereo_MS_to_LR(
     stereo_state        *state,                         /* I/O  State                                       */\r
     SKP_int16           x1[],                           /* I/O  Left input signal, becomes mid signal       */\r
     SKP_int16           x2[],                           /* I/O  Right input signal, becomes side signal     */\r
-    SKP_int             predictorIx,                    /* I    Index for predictor filter                  */\r
+    const SKP_int32     pred_Q13[],                     /* I    Predictors                                  */\r
     SKP_int             fs_kHz,                         /* I    Samples rate (kHz)                          */\r
     SKP_int             frame_length                    /* I    Number of samples                           */\r
 );\r
 \r
+/* Find least-squares prediction gain for one signal based on another and quantize it */\r
+SKP_int32 SKP_Silk_stereo_find_predictor(               /* O    Returns predictor in Q13                    */\r
+    const SKP_int16     x[],                            /* I    Basis signal                                */\r
+    const SKP_int16     y[],                            /* I    Target signal                               */\r
+    SKP_int             length                          /* I    Number of samples                           */\r
+);\r
+\r
+/* Quantize mid/side predictors and entropy code the quantization indices */\r
+void SKP_Silk_stereo_encode_pred(\r
+    ec_enc              *psRangeEnc,                    /* I/O  Compressor data structure                   */\r
+    SKP_int32           pred_Q13[]                      /* I/O  Predictors (out: quantized)                 */\r
+);\r
+\r
+/* Decode mid/side predictors */\r
+void SKP_Silk_stereo_decode_pred(\r
+    ec_dec              *psRangeDec,                    /* I/O  Compressor data structure                   */\r
+    SKP_int32           pred_Q13[]                      /* O    Predictors                                  */\r
+);\r
+\r
 /* Encodes signs of excitation */\r
 void SKP_Silk_encode_signs(\r
     ec_enc                      *psRangeEnc,                        /* I/O  Compressor data structure                   */\r
index e4a60ae..190d95f 100644 (file)
@@ -29,66 +29,79 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 \r
 /* Convert Left/Right stereo signal to adaptive Mid/Side representation */\r
 void SKP_Silk_stereo_LR_to_MS( \r
+    ec_enc              *psRangeEnc,                    /* I/O  Compressor data structure                   */\r
     stereo_state        *state,                         /* I/O  State                                       */\r
     SKP_int16           x1[],                           /* I/O  Left input signal, becomes mid signal       */\r
     SKP_int16           x2[],                           /* I/O  Right input signal, becomes side signal     */\r
-    SKP_int             *predictorIx,                   /* O    Index for predictor filter                  */\r
     SKP_int             fs_kHz,                         /* I    Samples rate (kHz)                          */\r
     SKP_int             frame_length                    /* I    Number of samples                           */\r
 )\r
 {\r
-    SKP_int   n, scale, scale1, scale2;\r
-    SKP_int32 sum, diff, nrg1, nrg2, corr, predictor_Q16, pred_Q16, delta_Q16;\r
+    SKP_int   n, denom_Q16, delta0_Q13, delta1_Q13;\r
+    SKP_int32 sum, diff, pred_Q13[ 2 ], pred0_Q13, pred1_Q13;\r
+    SKP_int16 mid[ MAX_FRAME_LENGTH + 2 ], side[ MAX_FRAME_LENGTH + 2 ];\r
+    SKP_int16 LP_mid[  MAX_FRAME_LENGTH ], HP_mid[  MAX_FRAME_LENGTH ];\r
+    SKP_int16 LP_side[ MAX_FRAME_LENGTH ], HP_side[ MAX_FRAME_LENGTH ];\r
 \r
     /* Convert to basic mid/side signals */\r
     for( n = 0; n < frame_length; n++ ) {\r
         sum  = x1[ n ] + (SKP_int32)x2[ n ];\r
         diff = x1[ n ] - (SKP_int32)x2[ n ];\r
-        x1[ n ] = (SKP_int16)SKP_RSHIFT32( sum + 1,  1 );\r
-        x2[ n ] = (SKP_int16)SKP_RSHIFT32( diff, 1 );\r
+        mid[  n + 2 ] = (SKP_int16)SKP_RSHIFT_ROUND( sum,  1 );\r
+        side[ n + 2 ] = (SKP_int16)SKP_SAT16( SKP_RSHIFT_ROUND( diff, 1 ) );\r
     }\r
 \r
-    /* Find  predictor */\r
-    SKP_Silk_sum_sqr_shift( &nrg1, &scale1, x1, frame_length );\r
-    SKP_Silk_sum_sqr_shift( &nrg2, &scale2, x2, frame_length );\r
-    if( scale1 > scale2 ) {\r
-        scale = scale1;\r
-    } else {\r
-        scale = scale2;\r
-        nrg1 = SKP_RSHIFT32( nrg1, scale2 - scale1 );\r
+    /* Buffering */\r
+    SKP_memcpy( mid,  state->sMid,  2 * sizeof( SKP_int16 ) );\r
+    SKP_memcpy( side, state->sSide, 2 * sizeof( SKP_int16 ) );\r
+    SKP_memcpy( state->sMid,  &mid[  frame_length ], 2 * sizeof( SKP_int16 ) );\r
+    SKP_memcpy( state->sSide, &side[ frame_length ], 2 * sizeof( SKP_int16 ) );\r
+\r
+    /* LP and HP filter mid signal */\r
+    for( n = 0; n < frame_length; n++ ) {\r
+        sum = SKP_RSHIFT_ROUND( SKP_ADD_LSHIFT( mid[ n ] + mid[ n + 2 ], mid[ n + 1 ], 1 ), 2 );\r
+        LP_mid[ n ] = sum;\r
+        HP_mid[ n ] = mid[ n + 1 ] - sum;\r
     }\r
-    corr = SKP_Silk_inner_prod_aligned_scale( x1, x2, scale, frame_length );\r
-    predictor_Q16 = SKP_DIV32_varQ( corr, nrg1 + 1, 16 );\r
 \r
-    /* Hysteresis */\r
-    if( predictor_Q16 > state->predictor_prev_Q16 ) {\r
-        predictor_Q16 -= SKP_FIX_CONST( STEREO_QUANT_HYSTERESIS / STEREO_QUANT_STEPS, 16 );\r
-    } else {\r
-        predictor_Q16 += SKP_FIX_CONST( STEREO_QUANT_HYSTERESIS / STEREO_QUANT_STEPS, 16 );\r
+    /* LP and HP filter side signal */\r
+    for( n = 0; n < frame_length; n++ ) {\r
+        sum = SKP_RSHIFT_ROUND( SKP_ADD_LSHIFT( side[ n ] + side[ n + 2 ], side[ n + 1 ], 1 ), 2 );\r
+        LP_side[ n ] = sum;\r
+        HP_side[ n ] = side[ n + 1 ] - sum;\r
     }\r
 \r
-    /* Quantize */\r
-    *predictorIx = SKP_RSHIFT_ROUND( SKP_MUL( predictor_Q16 + 65536, STEREO_QUANT_STEPS - 1 ), 17 );\r
-    *predictorIx = SKP_LIMIT( *predictorIx, 0, STEREO_QUANT_STEPS - 1 );\r
+    /* Find predictors */\r
+    pred_Q13[ 0 ] = SKP_Silk_stereo_find_predictor( LP_mid, LP_side, frame_length );\r
+    pred_Q13[ 1 ] = SKP_Silk_stereo_find_predictor( HP_mid, HP_side, frame_length );\r
 \r
-    predictor_Q16 = SKP_SMLABB( -65536, *predictorIx, ( 1 << 17 ) / ( STEREO_QUANT_STEPS - 1 ) );\r
+    /* Quantize and encode predictors */\r
+    SKP_Silk_stereo_encode_pred( psRangeEnc, pred_Q13 );\r
 \r
-    /* Subtract prediction from side channel */\r
-    if( predictor_Q16 != state->predictor_prev_Q16 ) {\r
-        /* Interpolate predictor */\r
-        pred_Q16 = -state->predictor_prev_Q16;\r
-        delta_Q16 = -SKP_DIV32_16( predictor_Q16 - state->predictor_prev_Q16, STEREO_INTERPOL_LENGTH_MS * fs_kHz );\r
-        for( n = 0; n < STEREO_INTERPOL_LENGTH_MS * fs_kHz; n++ ) {\r
-            pred_Q16 += delta_Q16;\r
-            x2[ n ] = (SKP_int16)SKP_SAT16( SKP_SMLAWB( x2[ n ], pred_Q16, x1[ n ] ) );\r
-        }\r
-    } else {\r
-        n = 0;\r
+    /* Interpolate predictors and subtract prediction from side channel */\r
+    pred0_Q13  = -state->pred_prev_Q13[ 0 ];\r
+    pred1_Q13  = -state->pred_prev_Q13[ 1 ];\r
+    denom_Q16  = SKP_DIV32_16( 1 << 16, STEREO_INTERP_LEN_MS * fs_kHz );\r
+    delta0_Q13 = -SKP_RSHIFT_ROUND( SKP_SMULBB( pred_Q13[ 0 ] - state->pred_prev_Q13[ 0 ], denom_Q16 ), 16 );\r
+    delta1_Q13 = -SKP_RSHIFT_ROUND( SKP_SMULBB( pred_Q13[ 1 ] - state->pred_prev_Q13[ 1 ], denom_Q16 ), 16 );\r
+    for( n = 0; n < STEREO_INTERP_LEN_MS * fs_kHz; n++ ) {\r
+        pred0_Q13 += delta0_Q13;\r
+        pred1_Q13 += delta1_Q13;\r
+        sum = SKP_LSHIFT( SKP_ADD_LSHIFT( mid[ n ] + mid[ n + 2 ], mid[ n + 1 ], 1 ), 9 );      /* Q11 */ \r
+        sum = SKP_SMLAWB( SKP_LSHIFT( ( SKP_int32 )side[ n + 1 ], 8 ), sum, pred0_Q13 );        /* Q8  */\r
+        sum = SKP_SMLAWB( sum, SKP_LSHIFT( ( SKP_int32 )mid[ n + 1 ], 11 ), pred1_Q13 );        /* Q8  */\r
+        x2[ n ] = (SKP_int16)SKP_SAT16( SKP_RSHIFT_ROUND( sum, 8 ) );\r
     }\r
-    pred_Q16 = -predictor_Q16;\r
-    for( ; n < frame_length; n++ ) {\r
-        x2[ n ] = (SKP_int16)SKP_SAT16( SKP_SMLAWB( x2[ n ], pred_Q16, x1[ n ] ) );\r
+    pred0_Q13 = -pred_Q13[ 0 ];\r
+    pred1_Q13 = -pred_Q13[ 1 ];\r
+    for( n = STEREO_INTERP_LEN_MS * fs_kHz; n < frame_length; n++ ) {\r
+        sum = SKP_LSHIFT( SKP_ADD_LSHIFT( mid[ n ] + mid[ n + 2 ], mid[ n + 1 ], 1 ), 9 );      /* Q11 */ \r
+        sum = SKP_SMLAWB( SKP_LSHIFT( ( SKP_int32 )side[ n + 1 ], 8 ), sum, pred0_Q13 );        /* Q8  */\r
+        sum = SKP_SMLAWB( sum, SKP_LSHIFT( ( SKP_int32 )mid[ n + 1 ], 11 ), pred1_Q13 );        /* Q8  */\r
+        x2[ n ] = (SKP_int16)SKP_SAT16( SKP_RSHIFT_ROUND( sum, 8 ) );\r
     }\r
+    state->pred_prev_Q13[ 0 ] = pred_Q13[ 0 ];\r
+    state->pred_prev_Q13[ 1 ] = pred_Q13[ 1 ];\r
 \r
-    state->predictor_prev_Q16 = predictor_Q16;\r
+    SKP_memcpy( x1, mid + 1, frame_length * sizeof( SKP_int16 ) );\r
 }\r
index ad3ed14..b8ba55d 100644 (file)
@@ -32,40 +32,52 @@ void SKP_Silk_stereo_MS_to_LR(
     stereo_state        *state,                         /* I/O  State                                       */\r
     SKP_int16           x1[],                           /* I/O  Left input signal, becomes mid signal       */\r
     SKP_int16           x2[],                           /* I/O  Right input signal, becomes side signal     */\r
-    SKP_int             predictorIx,                    /* I    Index for predictor filter                  */\r
+    const SKP_int32     pred_Q13[],                     /* I    Predictors                                  */\r
     SKP_int             fs_kHz,                         /* I    Samples rate (kHz)                          */\r
     SKP_int             frame_length                    /* I    Number of samples                           */\r
 )\r
 {\r
-    SKP_int   n;\r
-    SKP_int32 sum, diff, predictor_Q16, pred_Q16, delta_Q16;\r
+    SKP_int   n, denom_Q16, delta0_Q13, delta1_Q13;\r
+    SKP_int32 sum, diff, pred0_Q13, pred1_Q13;\r
+    SKP_int16 mid[ MAX_FRAME_LENGTH + 2 ], side[ MAX_FRAME_LENGTH + 2 ];\r
 \r
-    /* Dequantize */\r
-    predictor_Q16 = SKP_SMLABB( -65536, predictorIx, ( 1 << 17 ) / ( STEREO_QUANT_STEPS - 1 ) );\r
+    /* Buffering */\r
+    SKP_memcpy( mid,  state->sMid,  2 * sizeof( SKP_int16 ) );\r
+    SKP_memcpy( side, state->sSide, 2 * sizeof( SKP_int16 ) );\r
+    SKP_memcpy( mid  + 2, x1, frame_length * sizeof( SKP_int16 ) );\r
+    SKP_memcpy( side + 2, x2, frame_length * sizeof( SKP_int16 ) );\r
+    SKP_memcpy( state->sMid,  &mid[  frame_length ], 2 * sizeof( SKP_int16 ) );\r
+    SKP_memcpy( state->sSide, &side[ frame_length ], 2 * sizeof( SKP_int16 ) );\r
 \r
-    /* Add prediction to side channel */\r
-    if( predictor_Q16 != state->predictor_prev_Q16 ) {\r
-        /* Interpolate predictor */\r
-        pred_Q16 = state->predictor_prev_Q16;\r
-        delta_Q16 = SKP_DIV32_16( predictor_Q16 - state->predictor_prev_Q16, STEREO_INTERPOL_LENGTH_MS * fs_kHz );\r
-        for( n = 0; n < STEREO_INTERPOL_LENGTH_MS * fs_kHz; n++ ) {\r
-            pred_Q16 += delta_Q16;\r
-            x2[ n ] = (SKP_int16)SKP_SAT16( SKP_SMLAWB( x2[ n ], pred_Q16, x1[ n ] ) );\r
-        }\r
-    } else {\r
-        n = 0;\r
+    /* Interpolate predictors and add prediction to side channel */\r
+    pred0_Q13  = state->pred_prev_Q13[ 0 ];\r
+    pred1_Q13  = state->pred_prev_Q13[ 1 ];\r
+    denom_Q16  = SKP_DIV32_16( 1 << 16, STEREO_INTERP_LEN_MS * fs_kHz );\r
+    delta0_Q13 = SKP_RSHIFT_ROUND( SKP_SMULBB( pred_Q13[ 0 ] - state->pred_prev_Q13[ 0 ], denom_Q16 ), 16 );\r
+    delta1_Q13 = SKP_RSHIFT_ROUND( SKP_SMULBB( pred_Q13[ 1 ] - state->pred_prev_Q13[ 1 ], denom_Q16 ), 16 );\r
+    for( n = 0; n < STEREO_INTERP_LEN_MS * fs_kHz; n++ ) {\r
+        pred0_Q13 += delta0_Q13;\r
+        pred1_Q13 += delta1_Q13;\r
+        sum = SKP_LSHIFT( SKP_ADD_LSHIFT( mid[ n ] + mid[ n + 2 ], mid[ n + 1 ], 1 ), 9 );      /* Q11 */ \r
+        sum = SKP_SMLAWB( SKP_LSHIFT( ( SKP_int32 )side[ n + 1 ], 8 ), sum, pred0_Q13 );        /* Q8  */\r
+        sum = SKP_SMLAWB( sum, SKP_LSHIFT( ( SKP_int32 )mid[ n + 1 ], 11 ), pred1_Q13 );        /* Q8  */\r
+        side[ n + 1 ] = (SKP_int16)SKP_SAT16( SKP_RSHIFT_ROUND( sum, 8 ) );\r
     }\r
-    pred_Q16 = predictor_Q16;\r
-    for( ; n < frame_length; n++ ) {\r
-        x2[ n ] = (SKP_int16)SKP_SAT16( SKP_SMLAWB( x2[ n ], pred_Q16, x1[ n ] ) );\r
+    pred0_Q13 = pred_Q13[ 0 ];\r
+    pred1_Q13 = pred_Q13[ 1 ];\r
+    for( n = STEREO_INTERP_LEN_MS * fs_kHz; n < frame_length; n++ ) {\r
+        sum = SKP_LSHIFT( SKP_ADD_LSHIFT( mid[ n ] + mid[ n + 2 ], mid[ n + 1 ], 1 ), 9 );      /* Q11 */ \r
+        sum = SKP_SMLAWB( SKP_LSHIFT( ( SKP_int32 )side[ n + 1 ], 8 ), sum, pred0_Q13 );        /* Q8  */\r
+        sum = SKP_SMLAWB( sum, SKP_LSHIFT( ( SKP_int32 )mid[ n + 1 ], 11 ), pred1_Q13 );        /* Q8  */\r
+        side[ n + 1 ] = (SKP_int16)SKP_SAT16( SKP_RSHIFT_ROUND( sum, 8 ) );\r
     }\r
-\r
-    state->predictor_prev_Q16 = predictor_Q16;\r
+    state->pred_prev_Q13[ 0 ] = pred_Q13[ 0 ];\r
+    state->pred_prev_Q13[ 1 ] = pred_Q13[ 1 ];\r
 \r
     /* Convert to left/right signals */\r
     for( n = 0; n < frame_length; n++ ) {\r
-        sum  = x1[ n ] + (SKP_int32)x2[ n ];\r
-        diff = x1[ n ] - (SKP_int32)x2[ n ];\r
+        sum  = mid[ n + 1 ] + (SKP_int32)side[ n + 1 ];\r
+        diff = mid[ n + 1 ] - (SKP_int32)side[ n + 1 ];\r
         x1[ n ] = (SKP_int16)SKP_SAT16( sum );\r
         x2[ n ] = (SKP_int16)SKP_SAT16( diff );\r
     }\r
diff --git a/silk/SKP_Silk_stereo_decode_pred.c b/silk/SKP_Silk_stereo_decode_pred.c
new file mode 100644 (file)
index 0000000..828b8bd
--- /dev/null
@@ -0,0 +1,59 @@
+/***********************************************************************\r
+Copyright (c) 2006-2011, Skype Limited. All rights reserved. \r
+Redistribution and use in source and binary forms, with or without \r
+modification, (subject to the limitations in the disclaimer below) \r
+are permitted provided that the following conditions are met:\r
+- Redistributions of source code must retain the above copyright notice,\r
+this list of conditions and the following disclaimer.\r
+- Redistributions in binary form must reproduce the above copyright \r
+notice, this list of conditions and the following disclaimer in the \r
+documentation and/or other materials provided with the distribution.\r
+- Neither the name of Skype Limited, nor the names of specific \r
+contributors, may be used to endorse or promote products derived from \r
+this software without specific prior written permission.\r
+NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE GRANTED \r
+BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND \r
+CONTRIBUTORS ''AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING,\r
+BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND \r
+FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE \r
+COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, \r
+INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT\r
+NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF \r
+USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON \r
+ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT \r
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE \r
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
+***********************************************************************/\r
+\r
+#include "SKP_Silk_main.h"\r
+\r
+/* Decode mid/side predictors */\r
+void SKP_Silk_stereo_decode_pred(\r
+    ec_dec              *psRangeDec,                    /* I/O  Compressor data structure                   */\r
+    SKP_int32           pred_Q13[]                      /* O    Predictors                                  */\r
+)\r
+{\r
+    SKP_int   n, ibest[ 2 ] = { 0 }, jbest[ 2 ] = { 0 }, kbest[ 2 ];\r
+    SKP_int32 low_Q13, step_Q13;\r
+\r
+    /* Entropy decoding */\r
+    n = ec_dec_icdf( psRangeDec, SKP_Silk_stereo_pred_joint_iCDF, 8 );\r
+    kbest[ 0 ] = SKP_DIV32_16( n, 5 );\r
+    kbest[ 1 ] = n - 5 * kbest[ 0 ];\r
+    for( n = 0; n < 2; n++ ) {\r
+        ibest[ n ] = ec_dec_icdf( psRangeDec, SKP_Silk_uniform3_iCDF, 8 );\r
+        ibest[ n ] += 3 * kbest[ n ];\r
+        jbest[ n ] = ec_dec_icdf( psRangeDec, SKP_Silk_uniform5_iCDF, 8 );\r
+    }\r
+\r
+    /* Dequantize */\r
+    for( n = 0; n < 2; n++ ) {\r
+        low_Q13 = SKP_Silk_stereo_pred_quant_Q13[ ibest[ n ] ];\r
+        step_Q13 = SKP_SMULWB( SKP_Silk_stereo_pred_quant_Q13[ ibest[ n ] + 1 ] - low_Q13, \r
+            SKP_FIX_CONST( 0.5 / STEREO_QUANT_SUB_STEPS, 16 ) );\r
+        pred_Q13[ n ] = SKP_SMLABB( low_Q13, step_Q13, 2 * jbest[ n ] + 1 );\r
+    }\r
+\r
+    /* Subtract second from first predictor (helps when actually applying these) */\r
+    pred_Q13[ 0 ] -= pred_Q13[ 1 ];\r
+}\r
diff --git a/silk/SKP_Silk_stereo_encode_pred.c b/silk/SKP_Silk_stereo_encode_pred.c
new file mode 100644 (file)
index 0000000..4bc38ed
--- /dev/null
@@ -0,0 +1,80 @@
+/***********************************************************************\r
+Copyright (c) 2006-2011, Skype Limited. All rights reserved. \r
+Redistribution and use in source and binary forms, with or without \r
+modification, (subject to the limitations in the disclaimer below) \r
+are permitted provided that the following conditions are met:\r
+- Redistributions of source code must retain the above copyright notice,\r
+this list of conditions and the following disclaimer.\r
+- Redistributions in binary form must reproduce the above copyright \r
+notice, this list of conditions and the following disclaimer in the \r
+documentation and/or other materials provided with the distribution.\r
+- Neither the name of Skype Limited, nor the names of specific \r
+contributors, may be used to endorse or promote products derived from \r
+this software without specific prior written permission.\r
+NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE GRANTED \r
+BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND \r
+CONTRIBUTORS ''AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING,\r
+BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND \r
+FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE \r
+COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, \r
+INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT\r
+NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF \r
+USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON \r
+ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT \r
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE \r
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
+***********************************************************************/\r
+\r
+#include "SKP_Silk_main.h"\r
+\r
+/* Quantize mid/side predictors and entropy code the quantization indices */\r
+void SKP_Silk_stereo_encode_pred(\r
+    ec_enc              *psRangeEnc,                    /* I/O  Compressor data structure                   */\r
+    SKP_int32           pred_Q13[]                      /* I/O  Predictors (out: quantized)                 */\r
+)\r
+{\r
+    SKP_int   i, j, n, ibest[ 2 ] = { 0 }, jbest[ 2 ] = { 0 }, kbest[ 2 ];\r
+    SKP_int32 low_Q13, step_Q13, lvl_Q13, err_min_Q13, err_Q13, quant_pred_Q13 = 0;\r
+\r
+    /* Quantize */\r
+    for( n = 0; n < 2; n++ ) {\r
+        /* Brute-force search over quantization levels */\r
+        err_min_Q13 = SKP_int32_MAX;\r
+        for( i = 0; i < STEREO_QUANT_TAB_SIZE - 1; i++ ) {\r
+            low_Q13 = SKP_Silk_stereo_pred_quant_Q13[ i ];\r
+            step_Q13 = SKP_SMULWB( SKP_Silk_stereo_pred_quant_Q13[ i + 1 ] - low_Q13, \r
+                SKP_FIX_CONST( 0.5 / STEREO_QUANT_SUB_STEPS, 16 ) );\r
+            for( j = 0; j < STEREO_QUANT_SUB_STEPS; j++ ) {\r
+                lvl_Q13 = SKP_SMLABB( low_Q13, step_Q13, 2 * j + 1 );\r
+                err_Q13 = SKP_abs( pred_Q13[ n ] - lvl_Q13 );\r
+                if( err_Q13 < err_min_Q13 ) {\r
+                    err_min_Q13 = err_Q13;\r
+                    quant_pred_Q13 = lvl_Q13;\r
+                    ibest[ n ] = i;\r
+                    jbest[ n ] = j;\r
+                } else {\r
+                    /* Error increasing, so we're past the optimum */\r
+                    goto done;\r
+                }\r
+            }\r
+        }\r
+        done:\r
+        kbest[ n ]  = SKP_DIV32_16( ibest[ n ], 3 );\r
+        ibest[ n ] -= kbest[ n ] * 3;\r
+        pred_Q13[ n ] = quant_pred_Q13; \r
+    }\r
+\r
+    /* Subtract second from first predictor (helps when actually applying these) */\r
+    pred_Q13[ 0 ] -= pred_Q13[ 1 ];\r
+    \r
+    /* Entropy coding */\r
+    i = 5 * kbest[ 0 ] + kbest[ 1 ];\r
+    SKP_assert( i < 25 );\r
+    ec_enc_icdf( psRangeEnc, i, SKP_Silk_stereo_pred_joint_iCDF, 8 );\r
+    for( n = 0; n < 2; n++ ) {\r
+        SKP_assert( ibest[ n ] < 3 );\r
+        SKP_assert( jbest[ n ] < STEREO_QUANT_SUB_STEPS );\r
+        ec_enc_icdf( psRangeEnc, ibest[ n ], SKP_Silk_uniform3_iCDF, 8 );\r
+        ec_enc_icdf( psRangeEnc, jbest[ n ], SKP_Silk_uniform5_iCDF, 8 );\r
+    }\r
+}\r
diff --git a/silk/SKP_Silk_stereo_find_predictor.c b/silk/SKP_Silk_stereo_find_predictor.c
new file mode 100644 (file)
index 0000000..0fa373b
--- /dev/null
@@ -0,0 +1,54 @@
+/***********************************************************************\r
+Copyright (c) 2006-2011, Skype Limited. All rights reserved. \r
+Redistribution and use in source and binary forms, with or without \r
+modification, (subject to the limitations in the disclaimer below) \r
+are permitted provided that the following conditions are met:\r
+- Redistributions of source code must retain the above copyright notice,\r
+this list of conditions and the following disclaimer.\r
+- Redistributions in binary form must reproduce the above copyright \r
+notice, this list of conditions and the following disclaimer in the \r
+documentation and/or other materials provided with the distribution.\r
+- Neither the name of Skype Limited, nor the names of specific \r
+contributors, may be used to endorse or promote products derived from \r
+this software without specific prior written permission.\r
+NO EXPRESS OR IMPLIED LICENSES TO ANY PARTY'S PATENT RIGHTS ARE GRANTED \r
+BY THIS LICENSE. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND \r
+CONTRIBUTORS ''AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING,\r
+BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND \r
+FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE \r
+COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, \r
+INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT\r
+NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF \r
+USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON \r
+ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT \r
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE \r
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
+***********************************************************************/\r
+\r
+#include "SKP_Silk_main.h"\r
+\r
+/* Find least-squares prediction gain for one signal based on another and quantize it */\r
+SKP_int32 SKP_Silk_stereo_find_predictor(               /* O    Returns predictor in Q13                    */\r
+    const SKP_int16     x[],                            /* I    Basis signal                                */\r
+    const SKP_int16     y[],                            /* I    Target signal                               */\r
+    SKP_int             length                          /* I    Number of samples                           */\r
+)\r
+{\r
+    SKP_int   scale, scale1, scale2;\r
+    SKP_int32 nrg1, nrg2, corr, pred_Q13;\r
+\r
+    /* Find  predictor */\r
+    SKP_Silk_sum_sqr_shift( &nrg1, &scale1, x, length );\r
+    SKP_Silk_sum_sqr_shift( &nrg2, &scale2, y, length );\r
+    if( scale1 > scale2 ) {\r
+        scale = scale1;\r
+    } else {\r
+        scale = scale2;\r
+        nrg1 = SKP_RSHIFT32( nrg1, scale2 - scale1 );\r
+    }\r
+    corr = SKP_Silk_inner_prod_aligned_scale( x, y, scale, length );\r
+    pred_Q13 = SKP_DIV32_varQ( corr, SKP_max( nrg1, 1 ), 13 );\r
+    pred_Q13 = SKP_LIMIT( pred_Q13, -SKP_FIX_CONST( 10, 13 ), SKP_FIX_CONST( 10, 13 ) );\r
+\r
+    return pred_Q13;\r
+}\r
index fbd618d..75f58d3 100644 (file)
@@ -28,9 +28,9 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 #ifndef SKP_SILK_STRUCTS_H\r
 #define SKP_SILK_STRUCTS_H\r
 \r
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
+#ifdef HAVE_CONFIG_H\r
+#include "config.h"\r
+#endif\r
 \r
 #include "SKP_Silk_typedef.h"\r
 #include "SKP_Silk_SigProc_FIX.h"\r
@@ -99,7 +99,9 @@ typedef struct {
 } SKP_Silk_NLSF_CB_struct;\r
 \r
 typedef struct {\r
-    SKP_int32                   predictor_prev_Q16;\r
+    SKP_int32                   pred_prev_Q13[ 2 ];\r
+    SKP_int16                   sMid[ 2 ];\r
+    SKP_int16                   sSide[ 2 ];\r
 } stereo_state;\r
 \r
 typedef struct {\r
@@ -187,6 +189,9 @@ typedef struct {
     SKP_int                         nFramesPerPacket;\r
     SKP_int                         nFramesAnalyzed;                /* Number of frames analyzed in current packet                          */\r
 \r
+    SKP_int                         nChannels;\r
+    SKP_int                         channelNb;\r
+\r
     /* Parameters For LTP scaling Control */\r
     SKP_int                         frames_since_onset;\r
 \r
@@ -301,6 +306,7 @@ typedef struct {
     SKP_int             LTP_scale_Q14;\r
 } SKP_Silk_decoder_control;\r
 \r
+\r
 #ifdef __cplusplus\r
 }\r
 #endif\r
index cb59570..7cb5ac9 100644 (file)
@@ -44,8 +44,8 @@ extern const SKP_uint8  SKP_Silk_pitch_lag_iCDF[ 2 * ( PITCH_EST_MAX_LAG_MS - PI
 extern const SKP_uint8  SKP_Silk_pitch_delta_iCDF[ 21 ];                                            /*  21 */\r
 extern const SKP_uint8  SKP_Silk_pitch_contour_iCDF[ 34 ];                                          /*  34 */\r
 extern const SKP_uint8  SKP_Silk_pitch_contour_NB_iCDF[ 11 ];                                       /*  11 */\r
-extern const SKP_uint8 SKP_Silk_pitch_contour_10_ms_iCDF[ 12 ];                                     /*  12 */\r
-extern const SKP_uint8 SKP_Silk_pitch_contour_10_ms_NB_iCDF[ 3 ];                                   /*   3 */\r
+extern const SKP_uint8  SKP_Silk_pitch_contour_10_ms_iCDF[ 12 ];                                    /*  12 */\r
+extern const SKP_uint8  SKP_Silk_pitch_contour_10_ms_NB_iCDF[ 3 ];                                  /*   3 */\r
 \r
 extern const SKP_uint8  SKP_Silk_pulses_per_block_iCDF[ N_RATE_LEVELS ][ MAX_PULSES + 2 ];          /* 180 */\r
 extern const SKP_uint8  SKP_Silk_pulses_per_block_BITS_Q5[ N_RATE_LEVELS - 1 ][ MAX_PULSES + 2 ];   /* 162 */\r
@@ -65,12 +65,14 @@ extern const SKP_uint8  SKP_Silk_lsb_iCDF[ 2 ];
 \r
 extern const SKP_uint8  SKP_Silk_sign_iCDF[ 36 ];                                                   /*  36 */\r
 \r
-extern const SKP_uint8  SKP_Silk_uniform2_iCDF[   2 ];                                              /*   2 */\r
-extern const SKP_uint8  SKP_Silk_uniform4_iCDF[   4 ];                                              /*   4 */\r
-extern const SKP_uint8  SKP_Silk_uniform6_iCDF[   6 ];                                              /*   6 */\r
-extern const SKP_uint8  SKP_Silk_uniform8_iCDF[   8 ];                                              /*   8 */\r
+extern const SKP_uint8  SKP_Silk_uniform2_iCDF[ 2 ];                                                /*   2 */\r
+extern const SKP_uint8  SKP_Silk_uniform3_iCDF[ 3 ];                                                /*   3 */\r
+extern const SKP_uint8  SKP_Silk_uniform4_iCDF[ 4 ];                                                /*   4 */\r
+extern const SKP_uint8  SKP_Silk_uniform5_iCDF[ 5 ];                                                /*   5 */\r
+extern const SKP_uint8  SKP_Silk_uniform6_iCDF[ 6 ];                                                /*   6 */\r
+extern const SKP_uint8  SKP_Silk_uniform8_iCDF[ 8 ];                                                /*   8 */\r
 \r
-extern const SKP_uint8 SKP_Silk_NLSF_EXT_iCDF[ 7 ];                                                 /*   7 */\r
+extern const SKP_uint8  SKP_Silk_NLSF_EXT_iCDF[ 7 ];                                                /*   7 */\r
 \r
 extern const SKP_uint8  SKP_Silk_LTP_per_index_iCDF[ 3 ];                                           /*   3 */\r
 extern const SKP_uint8  * const SKP_Silk_LTP_gain_iCDF_ptrs[ NB_LTP_CBKS ];                         /*   3 */\r
@@ -82,10 +84,11 @@ extern const SKP_int8   SKP_Silk_LTP_vq_sizes[ NB_LTP_CBKS ];
 extern const SKP_uint8  SKP_Silk_LTPscale_iCDF[ 3 ];                                                /*   4 */\r
 extern const SKP_int16  SKP_Silk_LTPScales_table_Q14[ 3 ];\r
 \r
-extern const SKP_uint8 SKP_Silk_type_offset_VAD_iCDF[ 4 ];                                          /*   4 */\r
-extern const SKP_uint8 SKP_Silk_type_offset_no_VAD_iCDF[ 2 ];                                       /*   2 */\r
+extern const SKP_uint8  SKP_Silk_type_offset_VAD_iCDF[ 4 ];                                         /*   4 */\r
+extern const SKP_uint8  SKP_Silk_type_offset_no_VAD_iCDF[ 2 ];                                      /*   2 */\r
 \r
-extern const SKP_uint8 SKP_Silk_stereo_predictor_iCDF[ STEREO_QUANT_STEPS + 1 ];\r
+extern const SKP_int16  SKP_Silk_stereo_pred_quant_Q13[ STEREO_QUANT_TAB_SIZE ];                    /*  32 */\r
+extern const SKP_uint8  SKP_Silk_stereo_pred_joint_iCDF[ 25 ];                                      /*  25 */\r
 \r
 extern const SKP_uint8 * const SKP_Silk_LBRR_flags_iCDF_ptr[ 2 ];                                   /*  10 */\r
 \r
@@ -104,8 +107,8 @@ extern const SKP_int16  SNR_table_Q1[         TARGET_RATE_TAB_SZ ];
 extern const SKP_int16  SKP_Silk_Quantization_Offsets_Q10[ 2 ][ 2 ];\r
 \r
 /* Interpolation points for filter coefficients used in the bandwidth transition smoother */\r
-extern const SKP_int32 SKP_Silk_Transition_LP_B_Q28[ TRANSITION_INT_NUM ][ TRANSITION_NB ];\r
-extern const SKP_int32 SKP_Silk_Transition_LP_A_Q28[ TRANSITION_INT_NUM ][ TRANSITION_NA ];\r
+extern const SKP_int32  SKP_Silk_Transition_LP_B_Q28[ TRANSITION_INT_NUM ][ TRANSITION_NB ];\r
+extern const SKP_int32  SKP_Silk_Transition_LP_A_Q28[ TRANSITION_INT_NUM ][ TRANSITION_NA ];\r
 \r
 #ifdef __cplusplus\r
 }\r
index 442959e..2cbf607 100644 (file)
@@ -48,9 +48,18 @@ const SKP_int16 SNR_table_Q1[ TARGET_RATE_TAB_SZ ] = {
     19,     29,     35,     39,     44,     50,     60,     80\r
 };\r
 \r
-/* Table for stereo predictor coding */\r
-/* p = [2.^(-7:-1), 1, fliplr(2.^(-7:-1))]+2e-2; p = p/sum(p); fprintf('%d, ', round(256 - 256 * cumsum(p(1:end-1)))) */\r
-const SKP_uint8 SKP_Silk_stereo_predictor_iCDF[ STEREO_QUANT_STEPS + 1 ] = { 254, 251, 247, 241, 229, 208, 168, 88, 48, 27, 15, 9, 5, 2 };\r
+/* Tables for stereo predictor coding */\r
+const SKP_int16 SKP_Silk_stereo_pred_quant_Q13[ STEREO_QUANT_TAB_SIZE ] = {\r
+    -13732, -10050, -8266, -7526, -6500, -5000, -2950,  -820, \r
+       820,   2950,  5000,  6500,  7526,  8266, 10050, 13732\r
+};\r
+const SKP_uint8  SKP_Silk_stereo_pred_joint_iCDF[ 25 ] = {\r
+    249, 247, 246, 245, 244, \r
+    234, 210, 202, 201, 200, \r
+    197, 174,  82,  59,  56, \r
+     55,  54,  46,  22,  12, \r
+     11,  10,   9,   7,   0\r
+};\r
 \r
 /* Tables for LBRR flags */\r
 const SKP_uint8 SKP_Silk_LBRR_flags_2_iCDF[ 3 ] = { 203, 150, 0 };\r
@@ -87,7 +96,9 @@ const SKP_int16 SKP_Silk_LTPScales_table_Q14[ 3 ] = { 15565, 12288, 8192 };
 \r
 /* Uniform entropy tables */\r
 const SKP_uint8 SKP_Silk_uniform2_iCDF[ 2 ] = { 128, 0 };\r
+const SKP_uint8 SKP_Silk_uniform3_iCDF[ 3 ] = { 171, 85, 0 };\r
 const SKP_uint8 SKP_Silk_uniform4_iCDF[ 4 ] = { 192, 128, 64, 0 };\r
+const SKP_uint8 SKP_Silk_uniform5_iCDF[ 5 ] = { 205, 154, 102, 51, 0 };\r
 const SKP_uint8 SKP_Silk_uniform6_iCDF[ 6 ] = { 213, 171, 128, 85, 43, 0 };\r
 const SKP_uint8 SKP_Silk_uniform8_iCDF[ 8 ] = { 224, 192, 160, 128, 96, 64, 32, 0 };\r
 \r
index e9003fc..a1fbf1e 100644 (file)
@@ -108,13 +108,6 @@ TIC(NOISE_SHAPE_ANALYSIS)
     SKP_Silk_noise_shape_analysis_FIX( psEnc, &sEncCtrl, res_pitch_frame, x_frame );\r
 TOC(NOISE_SHAPE_ANALYSIS)\r
 \r
-    /*****************************************/\r
-    /* Prefiltering for noise shaper         */\r
-    /*****************************************/\r
-TIC(PREFILTER)\r
-    SKP_Silk_prefilter_FIX( psEnc, &sEncCtrl, xfw, x_frame );\r
-TOC(PREFILTER)\r
-\r
     /***************************************************/\r
     /* Find linear prediction coefficients (LPC + LTP) */\r
     /***************************************************/\r
@@ -137,6 +130,13 @@ TIC(LBRR)
 TOC(LBRR)\r
 \r
     /*****************************************/\r
+    /* Prefiltering for noise shaper         */\r
+    /*****************************************/\r
+TIC(PREFILTER)\r
+    SKP_Silk_prefilter_FIX( psEnc, &sEncCtrl, xfw, x_frame );\r
+TOC(PREFILTER)\r
+\r
+    /*****************************************/\r
     /* Noise shaping quantization            */\r
     /*****************************************/\r
 TIC(NSQ)\r
index 532a695..033a5a0 100644 (file)
@@ -85,8 +85,8 @@ void SKP_Silk_find_pred_coefs_FIX(
         SKP_Silk_LTP_scale_ctrl_FIX( psEnc, psEncCtrl );\r
 \r
         /* Create LTP residual */\r
-        SKP_Silk_LTP_analysis_filter_FIX( LPC_in_pre, psEnc->x_buf + psEnc->sCmn.ltp_mem_length - psEnc->sCmn.predictLPCOrder\r
-            psEncCtrl->LTPCoef_Q14, psEncCtrl->pitchL, invGains_Q16, psEnc->sCmn.subfr_length, psEnc->sCmn.nb_subfr, psEnc->sCmn.predictLPCOrder );\r
+        SKP_Silk_LTP_analysis_filter_FIX( LPC_in_pre, x - psEnc->sCmn.predictLPCOrder, psEncCtrl->LTPCoef_Q14\r
+            psEncCtrl->pitchL, invGains_Q16, psEnc->sCmn.subfr_length, psEnc->sCmn.nb_subfr, psEnc->sCmn.predictLPCOrder );\r
 \r
     } else {\r
         /************/\r
similarity index 97%
rename from silk/SKP_Silk_main_FIX.h
rename to silk/fixed/SKP_Silk_main_FIX.h
index b72516b..b65c78f 100644 (file)
@@ -71,7 +71,8 @@ SKP_int SKP_Silk_control_encoder(
     SKP_Silk_encoder_state_FIX      *psEnc,             /* I/O  Pointer to Silk encoder state           */\r
     SKP_SILK_SDK_EncControlStruct   *encControl,        /* I:   Control structure                       */\r
     const SKP_int32                 TargetRate_bps,     /* I    Target max bitrate (bps)                */\r
-    const SKP_int                   allow_bw_switch     /* I    Flag to allow switching audio bandwidth */\r
+    const SKP_int                   allow_bw_switch,    /* I    Flag to allow switching audio bandwidth */\r
+    const SKP_int                   channelNb           /* I    Channel number                          */\r
 );\r
 \r
 /****************/\r
similarity index 85%
rename from silk/src_FIX.vcxproj
rename to silk/fixed/silk_fixed.vcxproj
index 3b885a4..004b032 100644 (file)
@@ -14,6 +14,7 @@
     <ProjectGuid>{8484C90D-1561-402F-A91D-2DB10F8C5171}</ProjectGuid>\r
     <Keyword>Win32Proj</Keyword>\r
     <RootNamespace>src_FIX</RootNamespace>\r
+    <ProjectName>silk_fixed</ProjectName>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />\r
   </ImportGroup>\r
   <PropertyGroup Label="UserMacros" />\r
-  <PropertyGroup />\r
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">\r
+    <TargetName>$(ProjectName)</TargetName>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">\r
+    <TargetName>$(ProjectName)</TargetName>\r
+  </PropertyGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">\r
     <ClCompile>\r
       <PrecompiledHeader>\r
       <WarningLevel>Level3</WarningLevel>\r
       <Optimization>Disabled</Optimization>\r
       <PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>../interface;../src_SigProc_FIX;../src_common;../../celt/msvc;../../celt/libcelt</AdditionalIncludeDirectories>\r
+      <AdditionalIncludeDirectories>../;../../win32;../../libcelt</AdditionalIncludeDirectories>\r
     </ClCompile>\r
     <Link>\r
       <SubSystem>Windows</SubSystem>\r
       <GenerateDebugInformation>true</GenerateDebugInformation>\r
     </Link>\r
+    <Lib>\r
+      <OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>\r
+    </Lib>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">\r
     <ClCompile>\r
@@ -61,7 +70,7 @@
       <FunctionLevelLinking>true</FunctionLevelLinking>\r
       <IntrinsicFunctions>true</IntrinsicFunctions>\r
       <PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>../interface;../src_SigProc_FIX;../src_common;../../celt/msvc;../../celt/libcelt</AdditionalIncludeDirectories>\r
+      <AdditionalIncludeDirectories>../;../../win32;../../libcelt</AdditionalIncludeDirectories>\r
     </ClCompile>\r
     <Link>\r
       <SubSystem>Windows</SubSystem>\r
       <EnableCOMDATFolding>true</EnableCOMDATFolding>\r
       <OptimizeReferences>true</OptimizeReferences>\r
     </Link>\r
+    <Lib>\r
+      <OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>\r
+    </Lib>\r
   </ItemDefinitionGroup>\r
   <ItemGroup>\r
     <None Include="ReadMe.txt" />\r
   </ItemGroup>\r
   <ItemGroup>\r
-    <ClInclude Include="SKP_Silk_main_FIX.h" />\r
-    <ClInclude Include="SKP_Silk_structs_FIX.h" />\r
-  </ItemGroup>\r
-  <ItemGroup>\r
     <ClCompile Include="SKP_Silk_corrMatrix_FIX.c" />\r
     <ClCompile Include="SKP_Silk_encode_frame_FIX.c" />\r
     <ClCompile Include="SKP_Silk_find_LPC_FIX.c" />\r
     <ClCompile Include="SKP_Silk_solve_LS_FIX.c" />\r
     <ClCompile Include="SKP_Silk_warped_autocorrelation_FIX.c" />\r
   </ItemGroup>\r
+  <ItemGroup>\r
+    <ClInclude Include="SKP_Silk_main_FIX.h" />\r
+    <ClInclude Include="SKP_Silk_structs_FIX.h" />\r
+  </ItemGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />\r
   <ImportGroup Label="ExtensionTargets">\r
   </ImportGroup>\r
similarity index 97%
rename from silk/src_FIX.vcxproj.filters
rename to silk/fixed/silk_fixed.vcxproj.filters
index d640244..49c8f28 100644 (file)
     <None Include="ReadMe.txt" />\r
   </ItemGroup>\r
   <ItemGroup>\r
-    <ClInclude Include="SKP_Silk_main_FIX.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_structs_FIX.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-  </ItemGroup>\r
-  <ItemGroup>\r
-    <ClCompile Include="SKP_Silk_corrMatrix_FIX.c">\r
+    <ClCompile Include="SKP_Silk_LTP_scale_ctrl_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_encode_frame_FIX.c">\r
+    <ClCompile Include="SKP_Silk_noise_shape_analysis_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_find_LPC_FIX.c">\r
+    <ClCompile Include="SKP_Silk_prefilter_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_find_LTP_FIX.c">\r
+    <ClCompile Include="SKP_Silk_process_gains_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_find_pitch_lags_FIX.c">\r
+    <ClCompile Include="SKP_Silk_regularize_correlations_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_find_pred_coefs_FIX.c">\r
+    <ClCompile Include="SKP_Silk_residual_energy_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_LTP_analysis_filter_FIX.c">\r
+    <ClCompile Include="SKP_Silk_residual_energy16_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_LTP_scale_ctrl_FIX.c">\r
+    <ClCompile Include="SKP_Silk_solve_LS_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_noise_shape_analysis_FIX.c">\r
+    <ClCompile Include="SKP_Silk_warped_autocorrelation_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_prefilter_FIX.c">\r
+    <ClCompile Include="SKP_Silk_corrMatrix_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_process_gains_FIX.c">\r
+    <ClCompile Include="SKP_Silk_encode_frame_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_regularize_correlations_FIX.c">\r
+    <ClCompile Include="SKP_Silk_find_LPC_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_residual_energy_FIX.c">\r
+    <ClCompile Include="SKP_Silk_find_LTP_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_residual_energy16_FIX.c">\r
+    <ClCompile Include="SKP_Silk_find_pitch_lags_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_solve_LS_FIX.c">\r
+    <ClCompile Include="SKP_Silk_find_pred_coefs_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_warped_autocorrelation_FIX.c">\r
+    <ClCompile Include="SKP_Silk_LTP_analysis_filter_FIX.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
   </ItemGroup>\r
+  <ItemGroup>\r
+    <ClInclude Include="SKP_Silk_main_FIX.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_structs_FIX.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+  </ItemGroup>\r
 </Project>
\ No newline at end of file
index b340f55..e8d7d6b 100644 (file)
@@ -233,6 +233,13 @@ void SKP_Silk_LPC_analysis_filter6_FLP(
     }\r
 }\r
 \r
+/*******************************************/\r
+/* LPC analysis filter                     */\r
+/* NB! State is kept internally and the    */\r
+/* filter always starts with zero state    */\r
+/* first Order output samples are not set  */\r
+/*******************************************/\r
+\r
 void SKP_Silk_LPC_analysis_filter_FLP(\r
           SKP_float                 r_LPC[],            /* O    LPC residual signal                     */\r
     const SKP_float                 PredCoef[],         /* I    LPC coefficients                        */\r
@@ -272,8 +279,5 @@ void SKP_Silk_LPC_analysis_filter_FLP(
             SKP_assert( 0 );\r
         break;\r
     }\r
-\r
-    /* Set first LPC Order samples to zero instead of undefined */\r
-    SKP_memset( r_LPC, 0, Order * sizeof( SKP_float ) );\r
 }\r
 \r
index 43b5283..0a9fc0c 100644 (file)
@@ -119,13 +119,6 @@ TIC(NOISE_SHAPE_ANALYSIS)
     SKP_Silk_noise_shape_analysis_FLP( psEnc, &sEncCtrl, res_pitch_frame, x_frame );\r
 TOC(NOISE_SHAPE_ANALYSIS)\r
 \r
-    /*****************************************/\r
-    /* Prefiltering for noise shaper         */\r
-    /*****************************************/\r
-TIC(PREFILTER)\r
-    SKP_Silk_prefilter_FLP( psEnc, &sEncCtrl, xfw, x_frame );\r
-TOC(PREFILTER)\r
-\r
     /***************************************************/\r
     /* Find linear prediction coefficients (LPC + LTP) */\r
     /***************************************************/\r
@@ -139,7 +132,7 @@ TOC(FIND_PRED_COEF)
 TIC(PROCESS_GAINS)\r
     SKP_Silk_process_gains_FLP( psEnc, &sEncCtrl );\r
 TOC(PROCESS_GAINS)\r
-    \r
+\r
     /****************************************/\r
     /* Low Bitrate Redundant Encoding       */\r
     /****************************************/\r
@@ -148,6 +141,13 @@ TIC(LBRR)
 TOC(LBRR)\r
 \r
     /*****************************************/\r
+    /* Prefiltering for noise shaper         */\r
+    /*****************************************/\r
+TIC(PREFILTER)\r
+    SKP_Silk_prefilter_FLP( psEnc, &sEncCtrl, xfw, x_frame );\r
+TOC(PREFILTER)\r
+\r
+    /*****************************************/\r
     /* Noise shaping quantization            */\r
     /*****************************************/\r
 TIC(NSQ)\r
index 00b1cea..4224402 100644 (file)
@@ -66,14 +66,14 @@ void SKP_Silk_find_pred_coefs_FLP(
 \r
         /* Quantize LTP gain parameters */\r
         SKP_Silk_quant_LTP_gains_FLP( psEncCtrl->LTPCoef, psEnc->sCmn.indices.LTPIndex, &psEnc->sCmn.indices.PERIndex, \r
-            WLTP, psEnc->sCmn.mu_LTP_Q9, psEnc->sCmn.LTPQuantLowComplexity , psEnc->sCmn.nb_subfr );\r
+            WLTP, psEnc->sCmn.mu_LTP_Q9, psEnc->sCmn.LTPQuantLowComplexity, psEnc->sCmn.nb_subfr );\r
 \r
         /* Control LTP scaling */\r
         SKP_Silk_LTP_scale_ctrl_FLP( psEnc, psEncCtrl );\r
 \r
         /* Create LTP residual */\r
-        SKP_Silk_LTP_analysis_filter_FLP( LPC_in_pre, psEnc->x_buf + psEnc->sCmn.ltp_mem_length - psEnc->sCmn.predictLPCOrder\r
-            psEncCtrl->LTPCoef, psEncCtrl->pitchL, invGains, psEnc->sCmn.subfr_length, psEnc->sCmn.nb_subfr, psEnc->sCmn.predictLPCOrder );\r
+        SKP_Silk_LTP_analysis_filter_FLP( LPC_in_pre, x - psEnc->sCmn.predictLPCOrder, psEncCtrl->LTPCoef\r
+            psEncCtrl->pitchL, invGains, psEnc->sCmn.subfr_length, psEnc->sCmn.nb_subfr, psEnc->sCmn.predictLPCOrder );\r
 \r
     } else {\r
         /************/\r
@@ -98,7 +98,6 @@ void SKP_Silk_find_pred_coefs_FLP(
         psEnc->sCmn.useInterpolatedNLSFs, psEnc->sCmn.first_frame_after_reset, psEnc->sCmn.predictLPCOrder, \r
         LPC_in_pre, psEnc->sCmn.subfr_length + psEnc->sCmn.predictLPCOrder, psEnc->sCmn.nb_subfr );\r
 \r
-\r
     /* Quantize LSFs */\r
 TIC(LSF_quant);\r
     SKP_Silk_process_NLSFs_FLP( &psEnc->sCmn, psEncCtrl->PredCoef, NLSF_Q15, psEnc->sCmn.prev_NLSFq_Q15 );\r
similarity index 95%
rename from silk/SKP_Silk_inner_product_FLP.c
rename to silk/float/SKP_Silk_inner_product_FLP.c
index 05f5233..d901294 100644 (file)
@@ -28,7 +28,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 #include "SKP_Silk_SigProc_FLP.h"\r
 \r
 /* inner product of two SKP_float arrays, with result as double     */\r
-double SKP_Silk_inner_product_FLP(    /* O    result              */\r
+double SKP_Silk_inner_product_FLP(      /* O    result              */\r
     const SKP_float     *data1,         /* I    vector 1            */\r
     const SKP_float     *data2,         /* I    vector 2            */\r
     SKP_int             dataSize        /* I    length of vectors   */\r
similarity index 97%
rename from silk/SKP_Silk_main_FLP.h
rename to silk/float/SKP_Silk_main_FLP.h
index c3f3072..faa20c8 100644 (file)
@@ -69,7 +69,8 @@ SKP_int SKP_Silk_control_encoder(
     SKP_Silk_encoder_state_FLP      *psEnc,             /* I/O  Pointer to Silk encoder state FLP       */\r
     SKP_SILK_SDK_EncControlStruct   *encControl,        /* I:   Control structure                       */\r
     const SKP_int32                 TargetRate_bps,     /* I    Target max bitrate (bps)                */\r
-    const SKP_int                   allow_bw_switch     /* I    Flag to allow switching audio bandwidth */\r
+    const SKP_int                   allow_bw_switch,    /* I    Flag to allow switching audio bandwidth */\r
+    const SKP_int                   channelNb           /* I    Channel number                          */\r
 );\r
 \r
 /****************/\r
similarity index 96%
rename from silk/SKP_Silk_structs_FLP.h
rename to silk/float/SKP_Silk_structs_FLP.h
index 2b57a02..3c823fa 100644 (file)
@@ -83,7 +83,7 @@ typedef struct {
 /************************/\r
 typedef struct {\r
     /* Prediction and coding parameters */\r
-       SKP_float                                       Gains[MAX_NB_SUBFR];\r
+       SKP_float                                       Gains[ MAX_NB_SUBFR ];\r
        SKP_float                                       PredCoef[ 2 ][ MAX_LPC_ORDER ];         /* holds interpolated and final coefficients */\r
        SKP_float                                       LTPCoef[LTP_ORDER * MAX_NB_SUBFR];\r
        SKP_float                                       LTP_scale;\r
similarity index 74%
rename from silk/src_FLP.vcxproj
rename to silk/float/silk_float.vcxproj
index 6310247..313ba68 100644 (file)
@@ -14,6 +14,7 @@
     <ProjectGuid>{9C4961D2-5DDB-40C7-9BE8-CA918DC4E782}</ProjectGuid>\r
     <Keyword>Win32Proj</Keyword>\r
     <RootNamespace>src_FLP</RootNamespace>\r
+    <ProjectName>silk_float</ProjectName>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />\r
   </ImportGroup>\r
   <PropertyGroup Label="UserMacros" />\r
-  <PropertyGroup />\r
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">\r
+    <TargetName>$(ProjectName)</TargetName>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">\r
+    <TargetName>$(ProjectName)</TargetName>\r
+  </PropertyGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">\r
     <ClCompile>\r
       <PrecompiledHeader>\r
       <WarningLevel>Level3</WarningLevel>\r
       <Optimization>Disabled</Optimization>\r
       <PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>../interface;../src_SigProc_FLP;../src_SigProc_FIX;../src_common;../../celt/msvc;../../celt/libcelt</AdditionalIncludeDirectories>\r
+      <AdditionalIncludeDirectories>../;../fixed;../../win32;../../libcelt</AdditionalIncludeDirectories>\r
     </ClCompile>\r
     <Link>\r
       <SubSystem>Windows</SubSystem>\r
       <GenerateDebugInformation>true</GenerateDebugInformation>\r
     </Link>\r
+    <Lib>\r
+      <OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>\r
+    </Lib>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">\r
     <ClCompile>\r
@@ -61,7 +70,7 @@
       <FunctionLevelLinking>true</FunctionLevelLinking>\r
       <IntrinsicFunctions>true</IntrinsicFunctions>\r
       <PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>../interface;../src_SigProc_FLP;../src_SigProc_FIX;../src_common;../../celt/msvc;../../celt/libcelt</AdditionalIncludeDirectories>\r
+      <AdditionalIncludeDirectories>../;../fixed;../../win32;../../libcelt</AdditionalIncludeDirectories>\r
     </ClCompile>\r
     <Link>\r
       <SubSystem>Windows</SubSystem>\r
       <EnableCOMDATFolding>true</EnableCOMDATFolding>\r
       <OptimizeReferences>true</OptimizeReferences>\r
     </Link>\r
+    <Lib>\r
+      <OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>\r
+    </Lib>\r
   </ItemDefinitionGroup>\r
   <ItemGroup>\r
     <None Include="ReadMe.txt" />\r
   </ItemGroup>\r
   <ItemGroup>\r
-    <ClInclude Include="SKP_Silk_assembler_FLP.h" />\r
-    <ClInclude Include="SKP_Silk_main_FLP.h" />\r
-    <ClInclude Include="SKP_Silk_structs_FLP.h" />\r
-  </ItemGroup>\r
-  <ItemGroup>\r
     <ClCompile Include="SKP_Silk_apply_sine_window_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_autocorrelation_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_burg_modified_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_bwexpander_FLP.c" />\r
     <ClCompile Include="SKP_Silk_corrMatrix_FLP.c" />\r
     <ClCompile Include="SKP_Silk_encode_frame_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_energy_FLP.c" />\r
     <ClCompile Include="SKP_Silk_find_LPC_FLP.c" />\r
     <ClCompile Include="SKP_Silk_find_LTP_FLP.c" />\r
     <ClCompile Include="SKP_Silk_find_pitch_lags_FLP.c" />\r
     <ClCompile Include="SKP_Silk_find_pred_coefs_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_inner_product_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_k2a_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_levinsondurbin_FLP.c" />\r
     <ClCompile Include="SKP_Silk_LPC_analysis_filter_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_LPC_inv_pred_gain_FLP.c" />\r
     <ClCompile Include="SKP_Silk_LTP_analysis_filter_FLP.c" />\r
     <ClCompile Include="SKP_Silk_LTP_scale_ctrl_FLP.c" />\r
     <ClCompile Include="SKP_Silk_noise_shape_analysis_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_pitch_analysis_core_FLP.c" />\r
     <ClCompile Include="SKP_Silk_prefilter_FLP.c" />\r
     <ClCompile Include="SKP_Silk_process_gains_FLP.c" />\r
     <ClCompile Include="SKP_Silk_regularize_correlations_FLP.c" />\r
     <ClCompile Include="SKP_Silk_residual_energy_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_scale_copy_vector_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_scale_vector_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_schur_FLP.c" />\r
     <ClCompile Include="SKP_Silk_solve_LS_FLP.c" />\r
+    <ClCompile Include="SKP_Silk_sort_FLP.c" />\r
     <ClCompile Include="SKP_Silk_warped_autocorrelation_FLP.c" />\r
     <ClCompile Include="SKP_Silk_wrappers_FLP.c" />\r
   </ItemGroup>\r
+  <ItemGroup>\r
+    <ClInclude Include="..\..\win32\config.h" />\r
+    <ClInclude Include="SKP_Silk_main_FLP.h" />\r
+    <ClInclude Include="SKP_Silk_SigProc_FLP.h" />\r
+    <ClInclude Include="SKP_Silk_structs_FLP.h" />\r
+  </ItemGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />\r
   <ImportGroup Label="ExtensionTargets">\r
   </ImportGroup>\r
similarity index 65%
rename from silk/src_FLP.vcxproj.filters
rename to silk/float/silk_float.vcxproj.filters
index 92d93ea..8c6efb0 100644 (file)
     <None Include="ReadMe.txt" />\r
   </ItemGroup>\r
   <ItemGroup>\r
-    <ClInclude Include="SKP_Silk_assembler_FLP.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_main_FLP.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_structs_FLP.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-  </ItemGroup>\r
-  <ItemGroup>\r
-    <ClCompile Include="SKP_Silk_apply_sine_window_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_corrMatrix_FLP.c">\r
+    <ClCompile Include="SKP_Silk_LPC_analysis_filter_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_encode_frame_FLP.c">\r
+    <ClCompile Include="SKP_Silk_LPC_inv_pred_gain_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_find_LPC_FLP.c">\r
+    <ClCompile Include="SKP_Silk_LTP_analysis_filter_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_find_LTP_FLP.c">\r
+    <ClCompile Include="SKP_Silk_LTP_scale_ctrl_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_find_pitch_lags_FLP.c">\r
+    <ClCompile Include="SKP_Silk_noise_shape_analysis_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_find_pred_coefs_FLP.c">\r
+    <ClCompile Include="SKP_Silk_pitch_analysis_core_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_LPC_analysis_filter_FLP.c">\r
+    <ClCompile Include="SKP_Silk_prefilter_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_LTP_analysis_filter_FLP.c">\r
+    <ClCompile Include="SKP_Silk_process_gains_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_LTP_scale_ctrl_FLP.c">\r
+    <ClCompile Include="SKP_Silk_regularize_correlations_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_noise_shape_analysis_FLP.c">\r
+    <ClCompile Include="SKP_Silk_residual_energy_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_prefilter_FLP.c">\r
+    <ClCompile Include="SKP_Silk_scale_copy_vector_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_process_gains_FLP.c">\r
+    <ClCompile Include="SKP_Silk_scale_vector_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_regularize_correlations_FLP.c">\r
+    <ClCompile Include="SKP_Silk_schur_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_residual_energy_FLP.c">\r
+    <ClCompile Include="SKP_Silk_solve_LS_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_solve_LS_FLP.c">\r
+    <ClCompile Include="SKP_Silk_sort_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
     <ClCompile Include="SKP_Silk_warped_autocorrelation_FLP.c">\r
     <ClCompile Include="SKP_Silk_wrappers_FLP.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="SKP_Silk_apply_sine_window_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_autocorrelation_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_burg_modified_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_bwexpander_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_corrMatrix_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_encode_frame_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_energy_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_find_LPC_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_find_LTP_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_find_pitch_lags_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_find_pred_coefs_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_inner_product_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_k2a_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_levinsondurbin_FLP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <ClInclude Include="SKP_Silk_main_FLP.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_SigProc_FLP.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_structs_FLP.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="..\..\win32\config.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
   </ItemGroup>\r
 </Project>
\ No newline at end of file
similarity index 59%
rename from silk/src_SigProc_FIX.vcxproj
rename to silk/silk_common.vcxproj
index fb9df8d..748da77 100644 (file)
     </ProjectConfiguration>\r
   </ItemGroup>\r
   <PropertyGroup Label="Globals">\r
-    <ProjectGuid>{950F7176-3D29-4CBF-8C40-58B918EAEBB2}</ProjectGuid>\r
+    <ProjectGuid>{C303D2FC-FF97-49B8-9DDD-467B4C9A0B16}</ProjectGuid>\r
     <Keyword>Win32Proj</Keyword>\r
-    <RootNamespace>src_SigProc_FIX</RootNamespace>\r
+    <RootNamespace>src_common</RootNamespace>\r
+    <ProjectName>silk_common</ProjectName>\r
   </PropertyGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />\r
   </ImportGroup>\r
   <PropertyGroup Label="UserMacros" />\r
-  <PropertyGroup />\r
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">\r
+    <TargetName>$(ProjectName)</TargetName>\r
+  </PropertyGroup>\r
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">\r
+    <TargetName>$(ProjectName)</TargetName>\r
+  </PropertyGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">\r
     <ClCompile>\r
       <PrecompiledHeader>\r
       </PrecompiledHeader>\r
       <WarningLevel>Level3</WarningLevel>\r
       <Optimization>Disabled</Optimization>\r
-      <PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>../interface;..\..\celt\libcelt</AdditionalIncludeDirectories>\r
+      <PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
+      <AdditionalIncludeDirectories>fixed;float;../win32;../libcelt</AdditionalIncludeDirectories>\r
     </ClCompile>\r
     <Link>\r
       <SubSystem>Windows</SubSystem>\r
       <GenerateDebugInformation>true</GenerateDebugInformation>\r
     </Link>\r
+    <Lib>\r
+      <OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>\r
+    </Lib>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">\r
     <ClCompile>\r
@@ -60,8 +69,8 @@
       <Optimization>MaxSpeed</Optimization>\r
       <FunctionLevelLinking>true</FunctionLevelLinking>\r
       <IntrinsicFunctions>true</IntrinsicFunctions>\r
-      <PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>../interface;..\..\celt\libcelt</AdditionalIncludeDirectories>\r
+      <PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
+      <AdditionalIncludeDirectories>fixed;float;../win32;../libcelt</AdditionalIncludeDirectories>\r
     </ClCompile>\r
     <Link>\r
       <SubSystem>Windows</SubSystem>\r
       <EnableCOMDATFolding>true</EnableCOMDATFolding>\r
       <OptimizeReferences>true</OptimizeReferences>\r
     </Link>\r
+    <Lib>\r
+      <OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>\r
+    </Lib>\r
   </ItemDefinitionGroup>\r
   <ItemGroup>\r
     <None Include="ReadMe.txt" />\r
   </ItemGroup>\r
   <ItemGroup>\r
-    <ClInclude Include="..\interface\SKP_debug.h" />\r
-    <ClInclude Include="SKP_Silk_pitch_est_defines.h" />\r
-    <ClInclude Include="SKP_Silk_Inlines.h" />\r
-    <ClInclude Include="SKP_Silk_MacroCount.h" />\r
-    <ClInclude Include="SKP_Silk_MacroDebug.h" />\r
-    <ClInclude Include="SKP_Silk_macros.h" />\r
-    <ClInclude Include="SKP_Silk_resampler_private.h" />\r
-    <ClInclude Include="SKP_Silk_resampler_rom.h" />\r
-    <ClInclude Include="SKP_Silk_resampler_structs.h" />\r
-    <ClInclude Include="SKP_Silk_SigProc_FIX.h" />\r
-  </ItemGroup>\r
-  <ItemGroup>\r
     <ClCompile Include="SKP_Silk_A2NLSF.c" />\r
     <ClCompile Include="SKP_Silk_ana_filt_bank_1.c" />\r
     <ClCompile Include="SKP_Silk_apply_sine_window.c" />\r
     <ClCompile Include="SKP_Silk_burg_modified.c" />\r
     <ClCompile Include="SKP_Silk_bwexpander.c" />\r
     <ClCompile Include="SKP_Silk_bwexpander_32.c" />\r
+    <ClCompile Include="SKP_Silk_check_control_input.c" />\r
+    <ClCompile Include="SKP_Silk_CNG.c" />\r
+    <ClCompile Include="SKP_Silk_code_signs.c" />\r
+    <ClCompile Include="SKP_Silk_control_audio_bandwidth.c" />\r
+    <ClCompile Include="SKP_Silk_control_codec.c" />\r
+    <ClCompile Include="SKP_Silk_control_SNR.c" />\r
+    <ClCompile Include="SKP_Silk_create_init_destroy.c" />\r
     <ClCompile Include="SKP_Silk_debug.c" />\r
+    <ClCompile Include="SKP_Silk_decoder_set_fs.c" />\r
+    <ClCompile Include="SKP_Silk_decode_core.c" />\r
+    <ClCompile Include="SKP_Silk_decode_frame.c" />\r
+    <ClCompile Include="SKP_Silk_decode_indices.c" />\r
+    <ClCompile Include="SKP_Silk_decode_parameters.c" />\r
     <ClCompile Include="SKP_Silk_decode_pitch.c" />\r
+    <ClCompile Include="SKP_Silk_decode_pulses.c" />\r
+    <ClCompile Include="SKP_Silk_dec_API.c" />\r
+    <ClCompile Include="SKP_Silk_encode_indices.c" />\r
+    <ClCompile Include="SKP_Silk_encode_pulses.c" />\r
+    <ClCompile Include="SKP_Silk_enc_API.c" />\r
+    <ClCompile Include="SKP_Silk_gain_quant.c" />\r
+    <ClCompile Include="SKP_Silk_HP_variable_cutoff.c" />\r
+    <ClCompile Include="SKP_Silk_init_encoder.c" />\r
     <ClCompile Include="SKP_Silk_inner_prod_aligned.c" />\r
+    <ClCompile Include="SKP_Silk_interpolate.c" />\r
     <ClCompile Include="SKP_Silk_k2a.c" />\r
     <ClCompile Include="SKP_Silk_k2a_Q16.c" />\r
     <ClCompile Include="SKP_Silk_lin2log.c" />\r
     <ClCompile Include="SKP_Silk_log2lin.c" />\r
+    <ClCompile Include="SKP_Silk_LPC_analysis_filter.c" />\r
     <ClCompile Include="SKP_Silk_LPC_inv_pred_gain.c" />\r
     <ClCompile Include="SKP_Silk_LPC_stabilize.c" />\r
     <ClCompile Include="SKP_Silk_LPC_synthesis_filter.c" />\r
     <ClCompile Include="SKP_Silk_LPC_synthesis_order16.c" />\r
+    <ClCompile Include="SKP_Silk_LP_variable_cutoff.c" />\r
     <ClCompile Include="SKP_Silk_LSF_cos_table.c" />\r
-    <ClCompile Include="SKP_Silk_LPC_analysis_filter.c" />\r
     <ClCompile Include="SKP_Silk_NLSF2A.c" />\r
+    <ClCompile Include="SKP_Silk_NLSF2A_stable.c" />\r
+    <ClCompile Include="SKP_Silk_NLSF_decode.c" />\r
+    <ClCompile Include="SKP_Silk_NLSF_del_dec_quant.c" />\r
+    <ClCompile Include="SKP_Silk_NLSF_encode.c" />\r
     <ClCompile Include="SKP_Silk_NLSF_stabilize.c" />\r
+    <ClCompile Include="SKP_Silk_NLSF_unpack.c" />\r
+    <ClCompile Include="SKP_Silk_NLSF_VQ.c" />\r
     <ClCompile Include="SKP_Silk_NLSF_VQ_weights_laroia.c" />\r
+    <ClCompile Include="SKP_Silk_NSQ.c" />\r
+    <ClCompile Include="SKP_Silk_NSQ_del_dec.c" />\r
     <ClCompile Include="SKP_Silk_pitch_analysis_core.c" />\r
     <ClCompile Include="SKP_Silk_pitch_est_tables.c" />\r
+    <ClCompile Include="SKP_Silk_PLC.c" />\r
+    <ClCompile Include="SKP_Silk_process_NLSFs.c" />\r
+    <ClCompile Include="SKP_Silk_quant_LTP_gains.c" />\r
     <ClCompile Include="SKP_Silk_resampler.c" />\r
     <ClCompile Include="SKP_Silk_resampler_down2.c" />\r
     <ClCompile Include="SKP_Silk_resampler_down2_3.c" />\r
     <ClCompile Include="SKP_Silk_scale_vector.c" />\r
     <ClCompile Include="SKP_Silk_schur.c" />\r
     <ClCompile Include="SKP_Silk_schur64.c" />\r
+    <ClCompile Include="SKP_Silk_shell_coder.c" />\r
     <ClCompile Include="SKP_Silk_sigm_Q15.c" />\r
     <ClCompile Include="SKP_Silk_sort.c" />\r
+    <ClCompile Include="SKP_Silk_stereo_decode_pred.c" />\r
+    <ClCompile Include="SKP_Silk_stereo_encode_pred.c" />\r
+    <ClCompile Include="SKP_Silk_stereo_find_predictor.c" />\r
+    <ClCompile Include="SKP_Silk_stereo_LR_to_MS.c" />\r
+    <ClCompile Include="SKP_Silk_stereo_MS_to_LR.c" />\r
     <ClCompile Include="SKP_Silk_sum_sqr_shift.c" />\r
+    <ClCompile Include="SKP_Silk_tables_gain.c" />\r
+    <ClCompile Include="SKP_Silk_tables_LTP.c" />\r
+    <ClCompile Include="SKP_Silk_tables_NLSF_CB_NB_MB.c" />\r
+    <ClCompile Include="SKP_Silk_tables_NLSF_CB_WB.c" />\r
+    <ClCompile Include="SKP_Silk_tables_other.c" />\r
+    <ClCompile Include="SKP_Silk_tables_pitch_lag.c" />\r
+    <ClCompile Include="SKP_Silk_tables_pulses_per_block.c" />\r
+    <ClCompile Include="SKP_Silk_VAD.c" />\r
+    <ClCompile Include="SKP_Silk_VQ_WMat_EC.c" />\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <ClInclude Include="..\win32\config.h" />\r
+    <ClInclude Include="float\SKP_Silk_main_FLP.h" />\r
+    <ClInclude Include="SKP_Silk_control.h" />\r
+    <ClInclude Include="SKP_Silk_define.h" />\r
+    <ClInclude Include="SKP_Silk_errors.h" />\r
+    <ClInclude Include="SKP_Silk_Inlines.h" />\r
+    <ClInclude Include="SKP_Silk_MacroCount.h" />\r
+    <ClInclude Include="SKP_Silk_MacroDebug.h" />\r
+    <ClInclude Include="SKP_Silk_macros.h" />\r
+    <ClInclude Include="SKP_Silk_main.h" />\r
+    <ClInclude Include="SKP_Silk_pitch_est_defines.h" />\r
+    <ClInclude Include="SKP_Silk_PLC.h" />\r
+    <ClInclude Include="SKP_Silk_resampler_private.h" />\r
+    <ClInclude Include="SKP_Silk_resampler_rom.h" />\r
+    <ClInclude Include="SKP_Silk_resampler_structs.h" />\r
+    <ClInclude Include="SKP_Silk_SDK_API.h" />\r
+    <ClInclude Include="SKP_Silk_SigProc_FIX.h" />\r
+    <ClInclude Include="SKP_Silk_structs.h" />\r
+    <ClInclude Include="SKP_Silk_tables.h" />\r
+    <ClInclude Include="SKP_Silk_tuning_parameters.h" />\r
+    <ClInclude Include="SKP_Silk_typedef.h" />\r
   </ItemGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />\r
   <ImportGroup Label="ExtensionTargets">\r
similarity index 51%
rename from silk/src_SigProc_FIX.vcxproj.filters
rename to silk/silk_common.vcxproj.filters
index 13a4e13..561e1c0 100644 (file)
     <None Include="ReadMe.txt" />\r
   </ItemGroup>\r
   <ItemGroup>\r
-    <ClInclude Include="SKP_Silk_Inlines.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_MacroCount.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_MacroDebug.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_macros.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_resampler_private.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_resampler_rom.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_resampler_structs.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_SigProc_FIX.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_pitch_est_defines.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="..\interface\SKP_debug.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-  </ItemGroup>\r
-  <ItemGroup>\r
     <ClCompile Include="SKP_Silk_A2NLSF.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
     <ClCompile Include="SKP_Silk_bwexpander_32.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="SKP_Silk_check_control_input.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_CNG.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_code_signs.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_control_audio_bandwidth.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_control_codec.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_control_SNR.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_create_init_destroy.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_debug.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_dec_API.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_decode_core.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_decode_frame.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_decode_indices.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_decode_parameters.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
     <ClCompile Include="SKP_Silk_decode_pitch.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="SKP_Silk_decode_pulses.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_decoder_set_fs.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_enc_API.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_encode_indices.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_encode_pulses.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_gain_quant.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_HP_variable_cutoff.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_init_encoder.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
     <ClCompile Include="SKP_Silk_inner_prod_aligned.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="SKP_Silk_interpolate.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
     <ClCompile Include="SKP_Silk_k2a.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
     <ClCompile Include="SKP_Silk_log2lin.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="SKP_Silk_LP_variable_cutoff.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_LPC_analysis_filter.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
     <ClCompile Include="SKP_Silk_LPC_inv_pred_gain.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
     <ClCompile Include="SKP_Silk_LSF_cos_table.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="SKP_Silk_NLSF_decode.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_NLSF_del_dec_quant.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_NLSF_encode.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
     <ClCompile Include="SKP_Silk_NLSF_stabilize.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="SKP_Silk_NLSF_unpack.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_NLSF_VQ.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
     <ClCompile Include="SKP_Silk_NLSF_VQ_weights_laroia.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
     <ClCompile Include="SKP_Silk_NLSF2A.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="SKP_Silk_NLSF2A_stable.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_NSQ.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_NSQ_del_dec.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
     <ClCompile Include="SKP_Silk_pitch_analysis_core.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
     <ClCompile Include="SKP_Silk_pitch_est_tables.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="SKP_Silk_PLC.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_process_NLSFs.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_quant_LTP_gains.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
     <ClCompile Include="SKP_Silk_resampler.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
     <ClCompile Include="SKP_Silk_schur64.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="SKP_Silk_shell_coder.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
     <ClCompile Include="SKP_Silk_sigm_Q15.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
     <ClCompile Include="SKP_Silk_sort.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="SKP_Silk_stereo_decode_pred.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_stereo_encode_pred.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_stereo_find_predictor.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_stereo_LR_to_MS.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_stereo_MS_to_LR.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
     <ClCompile Include="SKP_Silk_sum_sqr_shift.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_debug.c">\r
+    <ClCompile Include="SKP_Silk_tables_gain.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="SKP_Silk_LPC_analysis_filter.c">\r
+    <ClCompile Include="SKP_Silk_tables_LTP.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_tables_NLSF_CB_NB_MB.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_tables_NLSF_CB_WB.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_tables_other.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_tables_pitch_lag.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_tables_pulses_per_block.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="SKP_Silk_VAD.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="SKP_Silk_VQ_WMat_EC.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+  </ItemGroup>\r
+  <ItemGroup>\r
+    <ClInclude Include="SKP_Silk_typedef.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_control.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_define.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_errors.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_Inlines.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_MacroCount.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_MacroDebug.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_macros.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_main.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_pitch_est_defines.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_PLC.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_resampler_private.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_resampler_rom.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_resampler_structs.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_SDK_API.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_SigProc_FIX.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_structs.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_tables.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="SKP_Silk_tuning_parameters.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="..\win32\config.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="float\SKP_Silk_main_FLP.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
   </ItemGroup>\r
 </Project>
\ No newline at end of file
diff --git a/silk/src_SigProc_FLP.vcxproj b/silk/src_SigProc_FLP.vcxproj
deleted file mode 100644 (file)
index c566243..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>\r
-<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
-  <ItemGroup Label="ProjectConfigurations">\r
-    <ProjectConfiguration Include="Debug|Win32">\r
-      <Configuration>Debug</Configuration>\r
-      <Platform>Win32</Platform>\r
-    </ProjectConfiguration>\r
-    <ProjectConfiguration Include="Release|Win32">\r
-      <Configuration>Release</Configuration>\r
-      <Platform>Win32</Platform>\r
-    </ProjectConfiguration>\r
-  </ItemGroup>\r
-  <PropertyGroup Label="Globals">\r
-    <ProjectGuid>{06D10292-A23C-4C5E-9C0F-28737769206F}</ProjectGuid>\r
-    <Keyword>Win32Proj</Keyword>\r
-    <RootNamespace>src_SigProc_FLP</RootNamespace>\r
-  </PropertyGroup>\r
-  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />\r
-  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
-    <ConfigurationType>StaticLibrary</ConfigurationType>\r
-    <UseDebugLibraries>true</UseDebugLibraries>\r
-    <CharacterSet>Unicode</CharacterSet>\r
-  </PropertyGroup>\r
-  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
-    <ConfigurationType>StaticLibrary</ConfigurationType>\r
-    <UseDebugLibraries>false</UseDebugLibraries>\r
-    <WholeProgramOptimization>true</WholeProgramOptimization>\r
-    <CharacterSet>Unicode</CharacterSet>\r
-  </PropertyGroup>\r
-  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
-  <ImportGroup Label="ExtensionSettings">\r
-  </ImportGroup>\r
-  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">\r
-    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />\r
-  </ImportGroup>\r
-  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">\r
-    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />\r
-  </ImportGroup>\r
-  <PropertyGroup Label="UserMacros" />\r
-  <PropertyGroup />\r
-  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">\r
-    <ClCompile>\r
-      <PrecompiledHeader>\r
-      </PrecompiledHeader>\r
-      <WarningLevel>Level3</WarningLevel>\r
-      <Optimization>Disabled</Optimization>\r
-      <PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>..\..\celt\libcelt;../interface;../src_SigProc_FIX</AdditionalIncludeDirectories>\r
-    </ClCompile>\r
-    <Link>\r
-      <SubSystem>Windows</SubSystem>\r
-      <GenerateDebugInformation>true</GenerateDebugInformation>\r
-    </Link>\r
-  </ItemDefinitionGroup>\r
-  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">\r
-    <ClCompile>\r
-      <WarningLevel>Level3</WarningLevel>\r
-      <PrecompiledHeader>\r
-      </PrecompiledHeader>\r
-      <Optimization>MaxSpeed</Optimization>\r
-      <FunctionLevelLinking>true</FunctionLevelLinking>\r
-      <IntrinsicFunctions>true</IntrinsicFunctions>\r
-      <PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>..\..\celt\libcelt;../interface;../src_SigProc_FIX</AdditionalIncludeDirectories>\r
-    </ClCompile>\r
-    <Link>\r
-      <SubSystem>Windows</SubSystem>\r
-      <GenerateDebugInformation>true</GenerateDebugInformation>\r
-      <EnableCOMDATFolding>true</EnableCOMDATFolding>\r
-      <OptimizeReferences>true</OptimizeReferences>\r
-    </Link>\r
-  </ItemDefinitionGroup>\r
-  <ItemGroup>\r
-    <None Include="ReadMe.txt" />\r
-  </ItemGroup>\r
-  <ItemGroup>\r
-    <ClInclude Include="SKP_Silk_SigProc_FLP.h" />\r
-  </ItemGroup>\r
-  <ItemGroup>\r
-    <ClCompile Include="SKP_Silk_autocorrelation_FLP.c" />\r
-    <ClCompile Include="SKP_Silk_burg_modified_FLP.c" />\r
-    <ClCompile Include="SKP_Silk_bwexpander_FLP.c" />\r
-    <ClCompile Include="SKP_Silk_energy_FLP.c" />\r
-    <ClCompile Include="SKP_Silk_inner_product_FLP.c" />\r
-    <ClCompile Include="SKP_Silk_k2a_FLP.c" />\r
-    <ClCompile Include="SKP_Silk_levinsondurbin_FLP.c" />\r
-    <ClCompile Include="SKP_Silk_LPC_inv_pred_gain_FLP.c" />\r
-    <ClCompile Include="SKP_Silk_pitch_analysis_core_FLP.c" />\r
-    <ClCompile Include="SKP_Silk_scale_copy_vector_FLP.c" />\r
-    <ClCompile Include="SKP_Silk_scale_vector_FLP.c" />\r
-    <ClCompile Include="SKP_Silk_schur_FLP.c" />\r
-    <ClCompile Include="SKP_Silk_sort_FLP.c" />\r
-  </ItemGroup>\r
-  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />\r
-  <ImportGroup Label="ExtensionTargets">\r
-  </ImportGroup>\r
-</Project>
\ No newline at end of file
diff --git a/silk/src_SigProc_FLP.vcxproj.filters b/silk/src_SigProc_FLP.vcxproj.filters
deleted file mode 100644 (file)
index 717b1c2..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>\r
-<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
-  <ItemGroup>\r
-    <Filter Include="Source Files">\r
-      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>\r
-      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>\r
-    </Filter>\r
-    <Filter Include="Header Files">\r
-      <UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>\r
-      <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>\r
-    </Filter>\r
-    <Filter Include="Resource Files">\r
-      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>\r
-      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>\r
-    </Filter>\r
-  </ItemGroup>\r
-  <ItemGroup>\r
-    <None Include="ReadMe.txt" />\r
-  </ItemGroup>\r
-  <ItemGroup>\r
-    <ClInclude Include="SKP_Silk_SigProc_FLP.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-  </ItemGroup>\r
-  <ItemGroup>\r
-    <ClCompile Include="SKP_Silk_autocorrelation_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_burg_modified_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_bwexpander_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_energy_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_inner_product_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_k2a_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_levinsondurbin_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_LPC_inv_pred_gain_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_pitch_analysis_core_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_scale_copy_vector_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_scale_vector_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_schur_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_sort_FLP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-  </ItemGroup>\r
-</Project>
\ No newline at end of file
diff --git a/silk/src_common.vcxproj b/silk/src_common.vcxproj
deleted file mode 100644 (file)
index 3aa7e82..0000000
+++ /dev/null
@@ -1,136 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>\r
-<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
-  <ItemGroup Label="ProjectConfigurations">\r
-    <ProjectConfiguration Include="Debug|Win32">\r
-      <Configuration>Debug</Configuration>\r
-      <Platform>Win32</Platform>\r
-    </ProjectConfiguration>\r
-    <ProjectConfiguration Include="Release|Win32">\r
-      <Configuration>Release</Configuration>\r
-      <Platform>Win32</Platform>\r
-    </ProjectConfiguration>\r
-  </ItemGroup>\r
-  <PropertyGroup Label="Globals">\r
-    <ProjectGuid>{C303D2FC-FF97-49B8-9DDD-467B4C9A0B16}</ProjectGuid>\r
-    <Keyword>Win32Proj</Keyword>\r
-    <RootNamespace>src_common</RootNamespace>\r
-  </PropertyGroup>\r
-  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />\r
-  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">\r
-    <ConfigurationType>StaticLibrary</ConfigurationType>\r
-    <UseDebugLibraries>true</UseDebugLibraries>\r
-    <CharacterSet>Unicode</CharacterSet>\r
-  </PropertyGroup>\r
-  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">\r
-    <ConfigurationType>StaticLibrary</ConfigurationType>\r
-    <UseDebugLibraries>false</UseDebugLibraries>\r
-    <WholeProgramOptimization>true</WholeProgramOptimization>\r
-    <CharacterSet>Unicode</CharacterSet>\r
-  </PropertyGroup>\r
-  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />\r
-  <ImportGroup Label="ExtensionSettings">\r
-  </ImportGroup>\r
-  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">\r
-    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />\r
-  </ImportGroup>\r
-  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">\r
-    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />\r
-  </ImportGroup>\r
-  <PropertyGroup Label="UserMacros" />\r
-  <PropertyGroup />\r
-  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">\r
-    <ClCompile>\r
-      <PrecompiledHeader>\r
-      </PrecompiledHeader>\r
-      <WarningLevel>Level3</WarningLevel>\r
-      <Optimization>Disabled</Optimization>\r
-      <PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>../interface/;../src_SigProc_FIX;../src_SigProc_FLP;../src_FIX;../src_FLP;../../celt/libcelt;../../celt/msvc</AdditionalIncludeDirectories>\r
-    </ClCompile>\r
-    <Link>\r
-      <SubSystem>Windows</SubSystem>\r
-      <GenerateDebugInformation>true</GenerateDebugInformation>\r
-    </Link>\r
-  </ItemDefinitionGroup>\r
-  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">\r
-    <ClCompile>\r
-      <WarningLevel>Level3</WarningLevel>\r
-      <PrecompiledHeader>\r
-      </PrecompiledHeader>\r
-      <Optimization>MaxSpeed</Optimization>\r
-      <FunctionLevelLinking>true</FunctionLevelLinking>\r
-      <IntrinsicFunctions>true</IntrinsicFunctions>\r
-      <PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>../interface/;../src_SigProc_FIX;../src_SigProc_FLP;../src_FIX;../src_FLP;../../celt/libcelt;../../celt/msvc</AdditionalIncludeDirectories>\r
-    </ClCompile>\r
-    <Link>\r
-      <SubSystem>Windows</SubSystem>\r
-      <GenerateDebugInformation>true</GenerateDebugInformation>\r
-      <EnableCOMDATFolding>true</EnableCOMDATFolding>\r
-      <OptimizeReferences>true</OptimizeReferences>\r
-    </Link>\r
-  </ItemDefinitionGroup>\r
-  <ItemGroup>\r
-    <None Include="ReadMe.txt" />\r
-  </ItemGroup>\r
-  <ItemGroup>\r
-    <ClInclude Include="..\interface\SKP_Silk_control.h" />\r
-    <ClInclude Include="..\interface\SKP_Silk_errors.h" />\r
-    <ClInclude Include="SKP_Silk_define.h" />\r
-    <ClInclude Include="SKP_Silk_main.h" />\r
-    <ClInclude Include="SKP_Silk_PLC.h" />\r
-    <ClInclude Include="SKP_Silk_structs.h" />\r
-    <ClInclude Include="SKP_Silk_tables.h" />\r
-    <ClInclude Include="SKP_Silk_tuning_parameters.h" />\r
-  </ItemGroup>\r
-  <ItemGroup>\r
-    <ClCompile Include="SKP_Silk_check_control_input.c" />\r
-    <ClCompile Include="SKP_Silk_CNG.c" />\r
-    <ClCompile Include="SKP_Silk_code_signs.c" />\r
-    <ClCompile Include="SKP_Silk_control_audio_bandwidth.c" />\r
-    <ClCompile Include="SKP_Silk_control_codec.c" />\r
-    <ClCompile Include="SKP_Silk_control_SNR.c" />\r
-    <ClCompile Include="SKP_Silk_create_init_destroy.c" />\r
-    <ClCompile Include="SKP_Silk_decoder_set_fs.c" />\r
-    <ClCompile Include="SKP_Silk_decode_core.c" />\r
-    <ClCompile Include="SKP_Silk_decode_frame.c" />\r
-    <ClCompile Include="SKP_Silk_decode_indices.c" />\r
-    <ClCompile Include="SKP_Silk_decode_parameters.c" />\r
-    <ClCompile Include="SKP_Silk_decode_pulses.c" />\r
-    <ClCompile Include="SKP_Silk_dec_API.c" />\r
-    <ClCompile Include="SKP_Silk_encode_indices.c" />\r
-    <ClCompile Include="SKP_Silk_encode_pulses.c" />\r
-    <ClCompile Include="SKP_Silk_enc_API.c" />\r
-    <ClCompile Include="SKP_Silk_gain_quant.c" />\r
-    <ClCompile Include="SKP_Silk_HP_variable_cutoff.c" />\r
-    <ClCompile Include="SKP_Silk_init_encoder.c" />\r
-    <ClCompile Include="SKP_Silk_interpolate.c" />\r
-    <ClCompile Include="SKP_Silk_LP_variable_cutoff.c" />\r
-    <ClCompile Include="SKP_Silk_NLSF2A_stable.c" />\r
-    <ClCompile Include="SKP_Silk_NLSF_decode.c" />\r
-    <ClCompile Include="SKP_Silk_NLSF_del_dec_quant.c" />\r
-    <ClCompile Include="SKP_Silk_NLSF_encode.c" />\r
-    <ClCompile Include="SKP_Silk_NLSF_unpack.c" />\r
-    <ClCompile Include="SKP_Silk_NLSF_VQ.c" />\r
-    <ClCompile Include="SKP_Silk_NSQ.c" />\r
-    <ClCompile Include="SKP_Silk_NSQ_del_dec.c" />\r
-    <ClCompile Include="SKP_Silk_PLC.c" />\r
-    <ClCompile Include="SKP_Silk_process_NLSFs.c" />\r
-    <ClCompile Include="SKP_Silk_quant_LTP_gains.c" />\r
-    <ClCompile Include="SKP_Silk_shell_coder.c" />\r
-    <ClCompile Include="SKP_Silk_stereo_LR_to_MS.c" />\r
-    <ClCompile Include="SKP_Silk_stereo_MS_to_LR.c" />\r
-    <ClCompile Include="SKP_Silk_tables_gain.c" />\r
-    <ClCompile Include="SKP_Silk_tables_LTP.c" />\r
-    <ClCompile Include="SKP_Silk_tables_NLSF_CB_NB_MB.c" />\r
-    <ClCompile Include="SKP_Silk_tables_NLSF_CB_WB.c" />\r
-    <ClCompile Include="SKP_Silk_tables_other.c" />\r
-    <ClCompile Include="SKP_Silk_tables_pitch_lag.c" />\r
-    <ClCompile Include="SKP_Silk_tables_pulses_per_block.c" />\r
-    <ClCompile Include="SKP_Silk_VAD.c" />\r
-    <ClCompile Include="SKP_Silk_VQ_WMat_EC.c" />\r
-  </ItemGroup>\r
-  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />\r
-  <ImportGroup Label="ExtensionTargets">\r
-  </ImportGroup>\r
-</Project>
\ No newline at end of file
diff --git a/silk/src_common.vcxproj.filters b/silk/src_common.vcxproj.filters
deleted file mode 100644 (file)
index 20d6c17..0000000
+++ /dev/null
@@ -1,183 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>\r
-<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
-  <ItemGroup>\r
-    <Filter Include="Source Files">\r
-      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>\r
-      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>\r
-    </Filter>\r
-    <Filter Include="Header Files">\r
-      <UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>\r
-      <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>\r
-    </Filter>\r
-    <Filter Include="Resource Files">\r
-      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>\r
-      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>\r
-    </Filter>\r
-  </ItemGroup>\r
-  <ItemGroup>\r
-    <None Include="ReadMe.txt" />\r
-  </ItemGroup>\r
-  <ItemGroup>\r
-    <ClInclude Include="SKP_Silk_define.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_main.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_PLC.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_structs.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_tables.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="SKP_Silk_tuning_parameters.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="..\interface\SKP_Silk_control.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-    <ClInclude Include="..\interface\SKP_Silk_errors.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
-  </ItemGroup>\r
-  <ItemGroup>\r
-    <ClCompile Include="SKP_Silk_CNG.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_code_signs.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_create_init_destroy.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_decode_core.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_decode_frame.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_decode_indices.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_decode_parameters.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_decode_pulses.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_decoder_set_fs.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_enc_API.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_encode_pulses.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_gain_quant.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_interpolate.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_LP_variable_cutoff.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_NLSF2A_stable.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_NSQ.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_NSQ_del_dec.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_PLC.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_shell_coder.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_tables_gain.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_tables_LTP.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_tables_other.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_tables_pitch_lag.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_tables_pulses_per_block.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_VAD.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_dec_API.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_control_audio_bandwidth.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_quant_LTP_gains.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_VQ_WMat_EC.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_encode_indices.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_process_NLSFs.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_HP_variable_cutoff.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_NLSF_encode.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_NLSF_decode.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_tables_NLSF_CB_WB.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_NLSF_unpack.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_tables_NLSF_CB_NB_MB.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_NLSF_VQ.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_NLSF_del_dec_quant.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_control_SNR.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_control_codec.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_check_control_input.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_init_encoder.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_stereo_LR_to_MS.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-    <ClCompile Include="SKP_Silk_stereo_MS_to_LR.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
-  </ItemGroup>\r
-</Project>
\ No newline at end of file
index 0077916..1e14f1f 100644 (file)
@@ -9,11 +9,6 @@ silk/SKP_Silk_PLC.h
 silk/SKP_Silk_structs.h
 silk/SKP_Silk_tables.h
 silk/SKP_Silk_tuning_parameters.h
-silk/SKP_Silk_main_FIX.h
-silk/SKP_Silk_structs_FIX.h
-silk/SKP_Silk_assembler_FLP.h
-silk/SKP_Silk_main_FLP.h
-silk/SKP_Silk_structs_FLP.h
 silk/SKP_Silk_Inlines.h
 silk/SKP_Silk_MacroCount.h
 silk/SKP_Silk_MacroDebug.h
@@ -23,4 +18,8 @@ silk/SKP_Silk_resampler_private.h
 silk/SKP_Silk_resampler_rom.h
 silk/SKP_Silk_resampler_structs.h
 silk/SKP_Silk_SigProc_FIX.h
-silk/SKP_Silk_SigProc_FLP.h
+silk/fixed/SKP_Silk_main_FIX.h
+silk/fixed/SKP_Silk_structs_FIX.h
+silk/float/SKP_Silk_main_FLP.h
+silk/float/SKP_Silk_structs_FLP.h
+silk/float/SKP_Silk_SigProc_FLP.h
index f4641d9..4c50b56 100644 (file)
@@ -11,6 +11,7 @@ silk/SKP_Silk_decoder_set_fs.c \
 silk/SKP_Silk_dec_API.c \
 silk/SKP_Silk_enc_API.c \
 silk/SKP_Silk_encode_indices.c \
+silk/SKP_Silk_stereo_encode_pred.c \
 silk/SKP_Silk_encode_pulses.c \
 silk/SKP_Silk_gain_quant.c \
 silk/SKP_Silk_interpolate.c \
@@ -92,21 +93,12 @@ silk/SKP_Silk_schur.c \
 silk/SKP_Silk_sigm_Q15.c \
 silk/SKP_Silk_sort.c \
 silk/SKP_Silk_sum_sqr_shift.c \
-silk/SKP_Silk_autocorrelation_FLP.c \
-silk/SKP_Silk_burg_modified_FLP.c \
-silk/SKP_Silk_bwexpander_FLP.c \
-silk/SKP_Silk_energy_FLP.c \
-silk/SKP_Silk_inner_product_FLP.c \
-silk/SKP_Silk_k2a_FLP.c \
-silk/SKP_Silk_levinsondurbin_FLP.c \
-silk/SKP_Silk_LPC_inv_pred_gain_FLP.c \
-silk/SKP_Silk_pitch_analysis_core_FLP.c \
-silk/SKP_Silk_scale_copy_vector_FLP.c \
-silk/SKP_Silk_scale_vector_FLP.c \
-silk/SKP_Silk_schur_FLP.c \
-silk/SKP_Silk_sort_FLP.c
+silk/SKP_Silk_stereo_decode_pred.c \
+silk/SKP_Silk_stereo_encode_pred.c \
+silk/SKP_Silk_stereo_find_predictor.c
 
-if FIXED_POINT
+
+ifdef FIXED_POINT
 SILK_SOURCES += \
 silk/fixed/SKP_Silk_LTP_analysis_filter_FIX.c \
 silk/fixed/SKP_Silk_LTP_scale_ctrl_FIX.c \
@@ -143,5 +135,18 @@ silk/float/SKP_Silk_regularize_correlations_FLP.c \
 silk/float/SKP_Silk_residual_energy_FLP.c \
 silk/float/SKP_Silk_solve_LS_FLP.c \
 silk/float/SKP_Silk_warped_autocorrelation_FLP.c \
-silk/float/SKP_Silk_wrappers_FLP.c
+silk/float/SKP_Silk_wrappers_FLP.c \
+silk/float/SKP_Silk_autocorrelation_FLP.c \
+silk/float/SKP_Silk_burg_modified_FLP.c \
+silk/float/SKP_Silk_bwexpander_FLP.c \
+silk/float/SKP_Silk_energy_FLP.c \
+silk/float/SKP_Silk_inner_product_FLP.c \
+silk/float/SKP_Silk_k2a_FLP.c \
+silk/float/SKP_Silk_levinsondurbin_FLP.c \
+silk/float/SKP_Silk_LPC_inv_pred_gain_FLP.c \
+silk/float/SKP_Silk_pitch_analysis_core_FLP.c \
+silk/float/SKP_Silk_scale_copy_vector_FLP.c \
+silk/float/SKP_Silk_scale_vector_FLP.c \
+silk/float/SKP_Silk_schur_FLP.c \
+silk/float/SKP_Silk_sort_FLP.c
 endif
similarity index 81%
rename from src/hybrid.vcxproj
rename to src/opus.vcxproj
index d682cbd..fddd0e4 100644 (file)
@@ -46,7 +46,7 @@
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">\r
     <ClCompile>\r
       <PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>../;../silk/interface;../celt/libcelt;../celt/msvc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\r
+      <AdditionalIncludeDirectories>../silk;../libcelt;../win32;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\r
       <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>\r
       <WarningLevel>Level3</WarningLevel>\r
       <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>\r
       <GenerateDebugInformation>true</GenerateDebugInformation>\r
       <SubSystem>Console</SubSystem>\r
       <AdditionalLibraryDirectories>$(SolutionDir)$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
-      <AdditionalDependencies>libcelt.lib;src_common.lib;src_FIX.lib;src_FLP.lib;src_SigProc_FIX.lib;src_SigProc_FLP.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
+      <AdditionalDependencies>libcelt.lib;silk_common.lib;silk_fixed.lib;silk_float.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">\r
     <ClCompile>\r
       <PreprocessorDefinitions>HAVE_CONFIG_H;WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>\r
-      <AdditionalIncludeDirectories>../;../silk/interface;../celt/libcelt;../celt/msvc;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\r
+      <AdditionalIncludeDirectories>../silk;../libcelt;../win32;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>\r
       <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>\r
       <WarningLevel>Level3</WarningLevel>\r
       <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>\r
@@ -74,7 +74,7 @@
       <SubSystem>Console</SubSystem>\r
       <EnableCOMDATFolding>true</EnableCOMDATFolding>\r
       <OptimizeReferences>true</OptimizeReferences>\r
-      <AdditionalDependencies>libcelt.lib;src_common.lib;src_FIX.lib;src_FLP.lib;src_SigProc_FIX.lib;src_SigProc_FLP.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
+      <AdditionalDependencies>libcelt.lib;silk_common.lib;silk_fixed.lib;silk_float.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
       <AdditionalLibraryDirectories>$(SolutionDir)$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
       <LinkStatus>false</LinkStatus>\r
     </Link>\r
@@ -86,6 +86,7 @@
   </ItemGroup>\r
   <ItemGroup>\r
     <ClInclude Include="..\silk\interface\SKP_Silk_SDK_API.h" />\r
+    <ClInclude Include="..\win32\config.h" />\r
     <ClInclude Include="opus.h" />\r
     <ClInclude Include="opus_decoder.h" />\r
     <ClInclude Include="opus_encoder.h" />\r
similarity index 90%
rename from src/hybrid.vcxproj.filters
rename to src/opus.vcxproj.filters
index 7b52605..13c93ee 100644 (file)
@@ -38,5 +38,8 @@
     <ClInclude Include="..\silk\interface\SKP_Silk_SDK_API.h">\r
       <Filter>Header Files</Filter>\r
     </ClInclude>\r
+    <ClInclude Include="..\win32\config.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
   </ItemGroup>\r
 </Project>
\ No newline at end of file
index 7e4b48b..fa9f6b5 100644 (file)
@@ -1,11 +1,12 @@
 #ifndef CONFIG_H\r
 #define CONFIG_H\r
 \r
-#define CELT_BUILD          1\r
+#define CELT_BUILD            1\r
+\r
 #define restrict \r
 #define inline __inline\r
 \r
-#define USE_ALLOCA 1\r
+#define USE_ALLOCA            1\r
 \r
 /* Comment out the next line for floating-point code */\r
 //#define FIXED_POINT           1\r