From 4b1f511080b563d3d1235b48748c1ca8666968ce Mon Sep 17 00:00:00 2001 From: Riza Sulistyo Date: Mon, 29 Aug 2016 08:44:54 +0000 Subject: Re #1954: Add support for VS2005. git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@5433 74dad513-b988-da41-8d7b-12977e46ad98 --- pjmedia/build/pjmedia.vcproj | 1186 +++---- pjproject-vs8.sln | 121 +- third_party/build/webrtc/libwebrtc.vcproj | 3544 ++++++++++++++++++++ third_party/build/webrtc/notes.txt | 6 + .../webrtc/modules/audio_processing/aec/aec_core.c | 4 +- .../webrtc/modules/audio_processing/ns/ns_core.c | 6 +- .../webrtc/modules/audio_processing/ns/nsx_core.c | 6 +- 7 files changed, 4254 insertions(+), 619 deletions(-) create mode 100644 third_party/build/webrtc/libwebrtc.vcproj diff --git a/pjmedia/build/pjmedia.vcproj b/pjmedia/build/pjmedia.vcproj index 32648e9d..7c020185 100644 --- a/pjmedia/build/pjmedia.vcproj +++ b/pjmedia/build/pjmedia.vcproj @@ -10,15 +10,15 @@ - + @@ -60,7 +60,7 @@ /> @@ -93,12 +93,11 @@ /> @@ -133,6 +132,7 @@ /> + + @@ -190,7 +198,7 @@ /> + + @@ -308,6 +322,7 @@ /> + + + + @@ -442,12 +472,11 @@ /> @@ -482,6 +511,7 @@ /> + + @@ -539,6 +577,7 @@ /> + + @@ -655,6 +700,7 @@ /> + + @@ -713,6 +766,7 @@ /> + + @@ -770,7 +832,6 @@ /> - - @@ -821,7 +874,7 @@ @@ -836,7 +889,7 @@ /> @@ -887,7 +940,7 @@ @@ -902,7 +955,7 @@ /> @@ -968,7 +1021,6 @@ /> - - @@ -1019,7 +1063,7 @@ @@ -1061,9 +1105,9 @@ /> @@ -1085,7 +1129,7 @@ @@ -1127,11 +1171,12 @@ /> @@ -1166,7 +1211,6 @@ /> - - - - - - @@ -1364,7 +1388,6 @@ /> - - - - - @@ -1496,7 +1505,6 @@ /> - - @@ -1613,7 +1613,7 @@ @@ -1679,7 +1679,7 @@ @@ -1745,7 +1745,7 @@ @@ -1811,7 +1811,7 @@ @@ -1877,7 +1877,7 @@ @@ -1943,7 +1943,7 @@ @@ -2009,7 +2009,7 @@ @@ -2075,7 +2075,7 @@ @@ -2141,7 +2141,7 @@ @@ -2207,7 +2207,7 @@ @@ -2273,7 +2273,7 @@ @@ -2339,7 +2339,7 @@ @@ -2405,7 +2405,7 @@ @@ -2471,7 +2471,7 @@ @@ -2537,7 +2537,7 @@ @@ -2603,7 +2603,7 @@ @@ -2669,7 +2669,7 @@ @@ -2735,7 +2735,7 @@ @@ -2801,7 +2801,7 @@ @@ -2867,7 +2867,7 @@ @@ -2933,7 +2933,7 @@ @@ -2999,7 +2999,7 @@ @@ -3065,7 +3065,7 @@ @@ -3127,7 +3127,7 @@ /> + + @@ -4275,7 +4279,7 @@ /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/third_party/build/webrtc/notes.txt b/third_party/build/webrtc/notes.txt index dc47aeba..393753fc 100644 --- a/third_party/build/webrtc/notes.txt +++ b/third_party/build/webrtc/notes.txt @@ -1,2 +1,8 @@ Notes: * Source code for webrtc from https://chromium.googlesource.com/external/webrtc circa Oct 2015. + +Modification to original source to build on VS2005 which don't support C99 syntax +(declare all variables at the beginning of a scope block). +- modules\audio_processing\aec\aec_core.c +- modules\audio_processing\ns\ns_core.c +- modules\audio_processing\ns\nsx_core.c \ No newline at end of file diff --git a/third_party/webrtc/src/webrtc/modules/audio_processing/aec/aec_core.c b/third_party/webrtc/src/webrtc/modules/audio_processing/aec/aec_core.c index b2162ac0..9d54b62f 100644 --- a/third_party/webrtc/src/webrtc/modules/audio_processing/aec/aec_core.c +++ b/third_party/webrtc/src/webrtc/modules/audio_processing/aec/aec_core.c @@ -1201,12 +1201,12 @@ static void ProcessBlock(AecCore* aec) { float output[PART_LEN]; float outputH[NUM_HIGH_BANDS_MAX][PART_LEN]; float* outputH_ptr[NUM_HIGH_BANDS_MAX]; + float* xf_ptr = NULL; + for (i = 0; i < NUM_HIGH_BANDS_MAX; ++i) { outputH_ptr[i] = outputH[i]; } - float* xf_ptr = NULL; - // Concatenate old and new nearend blocks. for (i = 0; i < aec->num_bands - 1; ++i) { WebRtc_ReadBuffer(aec->nearFrBufH[i], diff --git a/third_party/webrtc/src/webrtc/modules/audio_processing/ns/ns_core.c b/third_party/webrtc/src/webrtc/modules/audio_processing/ns/ns_core.c index 1d609140..f3e6a105 100644 --- a/third_party/webrtc/src/webrtc/modules/audio_processing/ns/ns_core.c +++ b/third_party/webrtc/src/webrtc/modules/audio_processing/ns/ns_core.c @@ -1204,14 +1204,14 @@ void WebRtcNs_ProcessCore(NoiseSuppressionC* self, float gainTimeDomainHB = 1.0; float avgProbSpeechHB, avgProbSpeechHBTmp, avgFilterGainHB, gainModHB; float sumMagnAnalyze, sumMagnProcess; + const float* const* speechFrameHB = NULL; + float* const* outFrameHB = NULL; + size_t num_high_bands = 0; // Check that initiation has been done. assert(self->initFlag == 1); assert((num_bands - 1) <= NUM_HIGH_BANDS_MAX); - const float* const* speechFrameHB = NULL; - float* const* outFrameHB = NULL; - size_t num_high_bands = 0; if (num_bands > 1) { speechFrameHB = &speechFrame[1]; outFrameHB = &outFrame[1]; diff --git a/third_party/webrtc/src/webrtc/modules/audio_processing/ns/nsx_core.c b/third_party/webrtc/src/webrtc/modules/audio_processing/ns/nsx_core.c index ed6125aa..7e2a94e0 100644 --- a/third_party/webrtc/src/webrtc/modules/audio_processing/ns/nsx_core.c +++ b/third_party/webrtc/src/webrtc/modules/audio_processing/ns/nsx_core.c @@ -1537,6 +1537,9 @@ void WebRtcNsx_ProcessCore(NoiseSuppressionFixedC* inst, int norm32no1, norm32no2; int flag, sign; int q_domain_to_use = 0; + const short* const* speechFrameHB = NULL; + short* const* outFrameHB = NULL; + size_t num_high_bands = 0; // Code for ARMv7-Neon platform assumes the following: assert(inst->anaLen > 0); @@ -1558,9 +1561,6 @@ void WebRtcNsx_ProcessCore(NoiseSuppressionFixedC* inst, assert(inst->initFlag == 1); assert((num_bands - 1) <= NUM_HIGH_BANDS_MAX); - const short* const* speechFrameHB = NULL; - short* const* outFrameHB = NULL; - size_t num_high_bands = 0; if (num_bands > 1) { speechFrameHB = &speechFrame[1]; outFrameHB = &outFrame[1]; -- cgit v1.2.3