Skip to content

Support webrtc-aec3 on windows#2775

Merged
trengginas merged 2 commits intomasterfrom
webrtc-aec3-win
Jul 28, 2021
Merged

Support webrtc-aec3 on windows#2775
trengginas merged 2 commits intomasterfrom
webrtc-aec3-win

Conversation

@trengginas
Copy link
Copy Markdown
Member

@trengginas trengginas commented Jul 27, 2021

PR #2722 add support for WebRTC AEC3.
This ticket will add the support for Visual Studio (windows).

Requirement:

  • Visual Studio 2015 or later with C++17 support

Changes:

  • Some source files needs to be renamed. Visual Studio will choose one implementation if source code are using the same name, which might lead to linker error.
  • Create new project to Visual Studio solution (libwebrtc_aec3). By default it is not build since it will add considerable time to build. e.g: On my machine it will take ~2 minutes to build the single project. Compared to ~50s to build all the projects (without libwebrtc_aec3) in the solution.
  • Define some build macro specific to building WebRTC-AEC3 on windows.
  • Add echo_webrtc_aec3.c to pjmedia project.

Enabling WebRTC-AEC3 on Visual Studio 2015 or later:

  1. Define PJMEDIA_HAS_WEBRTC_AEC3 on config_site.h file
  2. Change the BuildToolset configuration on build/vs/pjproject-vs14-common-config.props to v142.
     <When Condition="'$(API_Family)'=='WinDesktop'">
       <PropertyGroup>
-        <BuildToolset>v140</BuildToolset>
+        <BuildToolset>v142</BuildToolset>
  1. Enable buildng libwebrtc-aec3 project from solution configuration manager.
  2. Add reference to libwebrtc-aec3 project on libpjproject project. On libpjproject project > References > add libwebrtc-aec3 project.
  3. When building samples project, you need to link with libwebrtc_aec3 library by editing Samples-vc.mak file.
+WEBRTC_AEC3_LIB = ..\..\third_party\lib\libwebrtc_aec3-$(TARGET)$(LIBEXT)
 
 THIRD_PARTY_LIBS = $(GSM_LIB) $(ILBC_LIB) $(RESAMPLE_LIB) \
 		   $(SPEEX_LIB) $(SRTP_LIB) $(G7221_LIB) $(BASECLASSES_LIB) \
-		   $(YUV_LIB) $(WEBRTC_LIB)
+		   $(YUV_LIB) $(WEBRTC_LIB) $(WEBRTC_AEC3_LIB)

@trengginas trengginas added this to the release-2.12 milestone Jul 27, 2021
@trengginas trengginas requested review from nanangizz and sauwming July 27, 2021 15:46
@trengginas trengginas self-assigned this Jul 27, 2021
@sauwming
Copy link
Copy Markdown
Member

Looks okay. Please add the modification to WebRtc's original source in PJSIP_NOTES. Something like this:
master...webrtc-aec3-2#diff-f88a8593b35ff47a063c4fcfadd61ceb5c2fc83b4a411756269b03ebe19a646a

@trengginas trengginas merged commit 115b1db into master Jul 28, 2021
@trengginas trengginas deleted the webrtc-aec3-win branch July 28, 2021 07:40
@austinkottke
Copy link
Copy Markdown
Contributor

Will we support a mingw64/32 compile?

BarryYin pushed a commit to BarryYin/pjproject that referenced this pull request Feb 3, 2026
* Support webrtc-aec3 on windows

* Add modification to PJSIP_NOTES
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants