Skip to content

Commit

Permalink
Merge branch 'release/2022.3.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
miosakuma committed Aug 9, 2022
2 parents e8243cb + 1ca88b0 commit 41c9780
Show file tree
Hide file tree
Showing 35 changed files with 623 additions and 302 deletions.
10 changes: 4 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
uses: actions/cache@v3
with:
path: _cache\boost
key: windows-boost-${{ steps.versions.outputs.boost_version }}.zip.v5
key: windows-boost-${{ steps.versions.outputs.boost_version }}.zip.v6
# CUDA のインストールバイナリのダウンロードは 3GB ぐらいあって、
# ビルドの度に取得するのはつらいのでキャッシュする
# (インストールする nvcc は解凍後で 100MB 程度なのでキャッシュ可能)
Expand All @@ -47,7 +47,7 @@ jobs:
uses: actions/cache@v3
with:
path: build\windows_x86_64\_install\cuda\nvcc
key: windows-cuda-${{ steps.versions.outputs.wincuda_version }}.v1
key: windows-cuda-${{ steps.versions.outputs.wincuda_version }}.v2
- run: "& .\\build.ps1 -package"
working-directory: build
timeout-minutes: 120
Expand Down Expand Up @@ -80,7 +80,6 @@ jobs:
matrix:
arch:
- arm64
- x86_64
name: Build momo for macOS_${{ matrix.arch }}
runs-on: macos-11.0
steps:
Expand All @@ -95,7 +94,7 @@ jobs:
uses: actions/cache@v3
with:
path: _cache/boost
key: macos-boost-${{ steps.versions.outputs.boost_version }}.tar.gz.v2
key: macos-boost-${{ steps.versions.outputs.boost_version }}.tar.gz.v3
- run: ./build.sh --package macos_${{ matrix.arch }}
working-directory: build
timeout-minutes: 120
Expand Down Expand Up @@ -144,7 +143,7 @@ jobs:
uses: actions/cache@v3
with:
path: _cache/boost
key: ${{ matrix.name }}-boost-${{ steps.versions.outputs.boost_version }}.tar.gz.v2
key: ${{ matrix.name }}-boost-${{ steps.versions.outputs.boost_version }}.tar.gz.v3
- run: ./build.sh --no-tty --no-mount --package ${{ matrix.name }}
working-directory: build
timeout-minutes: 120
Expand Down Expand Up @@ -204,7 +203,6 @@ jobs:
name:
- windows_x86_64
- macos_arm64
- macos_x86_64
- raspberry-pi-os_armv6
- raspberry-pi-os_armv7
- raspberry-pi-os_armv8
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/daily_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ jobs:
matrix:
arch:
- arm64
- x86_64
name: Build momo for macOS_${{ matrix.arch }}
runs-on: macos-11.0
steps:
Expand Down
2 changes: 2 additions & 0 deletions .vscode/c_cpp_properties.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@
"${workspaceFolder}/_build/windows_x86_64"
],
"defines": [
"WIN32_LEAN_AND_MEAN",
"NOMINMAX",
"WEBRTC_WINDOWS",
"USE_NVCODEC_ENCODER=1",
"USE_MMAL_ENCODER=0",
Expand Down
5 changes: 5 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"[cpp]": {
"editor.formatOnSave": true
},
"files.associations": {
"*.cs": "csharp",
"*.txt": "plaintext",
"*.ipp": "cpp"
}
}
24 changes: 24 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,30 @@

## develop

## 2022.3.0

- [CHANGE] `--multistream` のデフォルトを true にする
- @melpon
- [CHANGE] `--role upstream``--role downstream` を削除
- @melpon
- [CHANGE] macos_x86_64 のビルドを削除
- @melpon
- [CHANGE] 音声系オプションの --disable-residual-echo-detector を削除する
- @melpon
- [UPDATE] `libwebrtc``M104.5112@{#8}` に上げる
- @voluntas, @melpon
- [ADD] TURN-TLS 向けの HTTP Proxy サーバの設定を追加する
- `--proxy-url`
- `--proxy-username`
- `--proxy-password`
- @melpon
- [ADD] Sora シグナリング用の WebSocket の HTTP Proxy 対応を追加する
- @melpon
- [ADD] HTTP Proxy サーバの SNI 対応を追加する
- @melpon
- [FIX] Sora の設定によっては `--multistream` オプションに関わらず常に multistream: true になっていたのを修正
- @melpon

## 2022.2.0

- [UPDATE] CLI11 を 2.2.0 に上げる
Expand Down
34 changes: 4 additions & 30 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -68,29 +68,6 @@ elseif(MOMO_PACKAGE_NAME STREQUAL "macos_arm64")
set(CLI11_ROOT_DIR ${_INSTALL_DIR}/CLI11)
set(WEBRTC_INCLUDE_DIR ${_INSTALL_DIR}/webrtc/include)
set(WEBRTC_LIBRARY_DIR ${_INSTALL_DIR}/webrtc/lib)
set(CLANG_ROOT ${_INSTALL_DIR}/llvm/clang)

set(USE_LIBCXX ON)
set(LIBCXX_INCLUDE_DIR ${_INSTALL_DIR}/llvm/libcxx/include)

elseif(MOMO_PACKAGE_NAME STREQUAL "macos_x86_64")

set(_INSTALL_DIR ${CMAKE_CURRENT_SOURCE_DIR}/build/macos_x86_64/_install)

set(TARGET_OS "macos")
set(TARGET_ARCH "x86_64")
set(USE_H264 ON)
set(USE_SDL2 ON)
set(USE_SCREEN_CAPTURER ON)
set(BOOST_ROOT_DIR ${_INSTALL_DIR}/boost)
set(SDL2_ROOT_DIR ${_INSTALL_DIR}/SDL2)
set(CLI11_ROOT_DIR ${_INSTALL_DIR}/CLI11)
set(WEBRTC_INCLUDE_DIR ${_INSTALL_DIR}/webrtc/include)
set(WEBRTC_LIBRARY_DIR ${_INSTALL_DIR}/webrtc/lib)
set(CLANG_ROOT ${_INSTALL_DIR}/llvm/clang)

set(USE_LIBCXX ON)
set(LIBCXX_INCLUDE_DIR ${_INSTALL_DIR}/llvm/libcxx/include)

elseif(MOMO_PACKAGE_NAME STREQUAL "raspberry-pi-os_armv6")

Expand Down Expand Up @@ -287,12 +264,8 @@ if (TARGET_OS STREQUAL "linux")
endif()

if (TARGET_OS STREQUAL "macos")
if (TARGET_ARCH STREQUAL "x86_64")
set(ARCH_NAME x86_64-apple-darwin)
else()
set(ARCH_NAME aarch64-apple-darwin)
set(CMAKE_SYSTEM_PROCESSOR arm64)
endif()
set(ARCH_NAME aarch64-apple-darwin)
set(CMAKE_SYSTEM_PROCESSOR arm64)

set(CMAKE_C_COMPILER_TARGET ${ARCH_NAME})
set(CMAKE_CXX_COMPILER_TARGET ${ARCH_NAME})
Expand Down Expand Up @@ -489,6 +462,7 @@ if ("${TARGET_OS}" STREQUAL "windows")
msdmo.lib
Secur32.lib
wmcodecdspuuid.lib
Dwmapi.lib
)

target_compile_definitions(momo
Expand Down Expand Up @@ -617,7 +591,7 @@ elseif (TARGET_OS STREQUAL "linux")
WEBRTC_POSIX
)
# Linux 系の場合はカスタムされた libc++ を使っているためオプション追加
target_compile_definitions(momo PRIVATE _LIBCPP_ABI_UNSTABLE _LIBCPP_DISABLE_AVAILABILITY)
target_compile_definitions(momo PRIVATE _LIBCPP_ABI_NAMESPACE=Cr _LIBCPP_ABI_VERSION=2 _LIBCPP_DISABLE_AVAILABILITY)

set_target_properties(momo PROPERTIES POSITION_INDEPENDENT_CODE ON)
target_link_libraries(momo
Expand Down
15 changes: 5 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ https://momo.shiguredo.jp/
- [Raspberry Pi](https://www.raspberrypi.org/) の GPU に積まれている H.264 ハードウェアエンコーダー機能を利用することが可能です
- Apple macOS に搭載されている H.264 ハードウェアアクセラレーター機能を [VideoToolbox](https://developer.apple.com/documentation/videotoolbox) 経由で利用することが可能です
- NVIDIA グラフィックスカードに搭載されているハードウェアアクセラレーター機能を [NVIDIA VIDEO CODEC SDK](https://developer.nvidia.com/nvidia-video-codec-sdk) 経由で利用することが可能です
- [Intel Quick Sync Video](https://www.intel.co.jp/content/www/jp/ja/architecture-and-technology/quick-sync-video/quick-sync-video-general.html)[Intel Media SDK](https://www.intel.com/content/www/us/en/developer/tools/media-sdk/overview.html) 経由で Windows x86_64 と Ubuntu x86_64 にて VP8 / VP9 / H.264 ハードウェアアクセラレーター機能を利用することが可能です
- [Intel Quick Sync Video](https://www.intel.co.jp/content/www/jp/ja/architecture-and-technology/quick-sync-video/quick-sync-video-general.html)[Intel Media SDK](https://www.intel.com/content/www/us/en/developer/tools/media-sdk/overview.html) 経由で Windows x86_64 と Ubuntu x86_64 にて VP9 / H.264 ハードウェアアクセラレーター機能を利用することが可能です

### 4K 30fps での配信

Expand Down Expand Up @@ -81,7 +81,6 @@ https://github.com/shiguredo/momo/releases

## 動作環境


- Raspberry Pi OS (64bit) ARMv8
- Raspberry Pi 4
- Raspberry Pi 3
Expand All @@ -90,24 +89,22 @@ https://github.com/shiguredo/momo/releases
- Raspberry Pi 4
- Raspberry Pi 3
- Raspberry Pi 2
- Raspberry Pi Zero 2
- Raspberry Pi OS (32bit) ARMv6
- Raspberry Pi Zero
- Raspberry Pi 1
- Ubuntu 18.04 x86_64
- 2023 年 4 月末にて終了
- Ubuntu 20.04 x86_64
- Ubuntu 18.04 ARMv8 Jetson
- 2023 年 4 月末にて終了
- [NVIDIA Jetson Nano](https://www.nvidia.com/ja-jp/autonomous-machines/embedded-systems/jetson-nano/)
- [NVIDIA Jetson Xavier NX](https://www.nvidia.com/ja-jp/autonomous-machines/embedded-systems/jetson-xavier-nx/)
- [NVIDIA Jetson AGX Xavier](https://www.nvidia.com/ja-jp/autonomous-machines/embedded-systems/jetson-agx-xavier/)
- Ubuntu 20.04 ARMv8 Jetson
- JetPack 5 がリリースされ次第対応予定
- [NVIDIA Jetson AGX Orin](https://www.nvidia.com/ja-jp/autonomous-machines/embedded-systems/jetson-orin/)
- [NVIDIA Jetson Orin NX](https://www.nvidia.com/ja-jp/autonomous-machines/embedded-systems/jetson-orin/)
- [NVIDIA Jetson Xavier NX](https://www.nvidia.com/ja-jp/autonomous-machines/embedded-systems/jetson-xavier-nx/)
- [NVIDIA Jetson AGX Xavier](https://www.nvidia.com/ja-jp/autonomous-machines/embedded-systems/jetson-agx-xavier/)
- macOS 11 x86_64 以降
- 2021 年末にて終了
- macOS 11 arm64 以降
- macOS 12 arm64 以降
- Windows 10.1809 x86_64 以降

## 使ってみる
Expand Down Expand Up @@ -169,8 +166,6 @@ limitations under the License.
**詳細は Discord やメールなどでお気軽にお問い合わせください**

- Jetson AGX Orin 対応
- AV1 ハードウェアエンコーダー対応
- AV1 ハードウェアデコーダー対応
- H.265 ハードウェアエンコーダー対応
- H.265 ハードウェアデコーダー対応
- Jetson AGX Xavier 対応
Expand Down
6 changes: 3 additions & 3 deletions VERSION
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
MOMO_VERSION=2022.2.0
WEBRTC_BUILD_VERSION=102.5005.1.0
MOMO_VERSION=2022.3.0
WEBRTC_BUILD_VERSION=104.5112.8.0
BOOST_VERSION=1.79.0
CLI11_VERSION=2.2.0
SDL2_VERSION=2.0.20
SDL2_VERSION=2.0.22
CMAKE_VERSION=3.23.1
CUDA_VERSION=11.0.2-1
WINCUDA_VERSION=10.2
Expand Down
3 changes: 1 addition & 2 deletions build/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ PROGRAM="$0"
_PACKAGES=" \
windows \
macos_arm64 \
macos_x86_64 \
raspberry-pi-os_armv6 \
raspberry-pi-os_armv7 \
raspberry-pi-os_armv8 \
Expand Down Expand Up @@ -94,7 +93,7 @@ case "$PACKAGE" in
echo "Windows では build.bat を利用してください。"
exit 1
;;
macos_* )
macos_arm64 )
if [ $FLAG_CLEAN -eq 1 ]; then
rm -rf ../_build/$PACKAGE
rm -rf $PACKAGE/_source
Expand Down
11 changes: 6 additions & 5 deletions build/macos_arm64/install_deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -66,13 +66,16 @@ if [ ! -e $BOOST_VERSION_FILE -o "$BOOST_VERSION" != "`cat $BOOST_VERSION_FILE`"
BOOST_CHANGED=1
fi

CLANG="`xcodebuild -find clang`"
CLANGPP="`xcodebuild -find clang++`"

if [ $BOOST_CHANGED -eq 1 -o ! -e $INSTALL_DIR/boost/lib/libboost_filesystem.a ]; then
rm -rf $SOURCE_DIR/boost
rm -rf $BUILD_DIR/boost
rm -rf $INSTALL_DIR/boost
../../script/setup_boost.sh $BOOST_VERSION $SOURCE_DIR/boost $CACHE_DIR/boost
pushd $SOURCE_DIR/boost/source
echo "using clang : : $INSTALL_DIR/llvm/clang/bin/clang++ : ;" > project-config.jam
echo "using clang : : $CLANGPP : ;" > project-config.jam
SYSROOT="`xcrun --sdk macosx --show-sdk-path`"
./b2 \
cxxstd=17 \
Expand All @@ -84,8 +87,6 @@ if [ $BOOST_CHANGED -eq 1 -o ! -e $INSTALL_DIR/boost/lib/libboost_filesystem.a ]
cxxflags=" \
-target $ARCH_NAME \
-mmacosx-version-min=11.0 \
-isystem $INSTALL_DIR/llvm/libcxx/include \
-nostdinc++ \
--sysroot=$SYSROOT \
" \
toolset=clang \
Expand Down Expand Up @@ -122,8 +123,8 @@ if [ $SDL2_CHANGED -eq 1 -o ! -e $INSTALL_DIR/SDL2/lib/libSDL2.a ]; then
# SDL2 の CMakeLists.txt は Metal をサポートしてくれてないので、configure でビルドする
# ref: https://bugzilla.libsdl.org/show_bug.cgi?id=4617
SYSROOT="`xcrun --sdk macosx --show-sdk-path`"
CC="$INSTALL_DIR/llvm/clang/bin/clang -target $ARCH_NAME -mmacosx-version-min=11.0 --sysroot=$SYSROOT" \
CXX="$INSTALL_DIR/llvm/clang/bin/clang++ -target $ARCH_NAME -mmacosx-version-min=11.0 --sysroot=$SYSROOT -nostdinc++" \
CC="$CLANG -target $ARCH_NAME -mmacosx-version-min=11.0 --sysroot=$SYSROOT" \
CXX="$CLANGPP -target $ARCH_NAME -mmacosx-version-min=11.0 --sysroot=$SYSROOT" \
$SOURCE_DIR/SDL2/source/configure --host=$ARCH_NAME --disable-shared --prefix=$INSTALL_DIR/SDL2
make -j$JOBS
make install
Expand Down
Loading

0 comments on commit 41c9780

Please sign in to comment.