Skip to content

Commit

Permalink
HoloLens 2 対応
Browse files Browse the repository at this point in the history
  • Loading branch information
melpon committed Jul 24, 2023
1 parent 2c3f09c commit 52706fa
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 20 deletions.
11 changes: 6 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE NEVER)

find_package(WebRTC REQUIRED)
find_package(Boost REQUIRED COMPONENTS json filesystem)
find_package(Lyra REQUIRED)
# find_package(Lyra REQUIRED)
find_package(Threads REQUIRED)

set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
Expand All @@ -92,9 +92,9 @@ target_include_directories(sora PRIVATE ${CMAKE_CURRENT_BINARY_DIR})
target_sources(sora
PRIVATE
src/aligned_encoder_adapter.cpp
src/audio_decoder_lyra.cpp
# src/audio_decoder_lyra.cpp
src/audio_device_module.cpp
src/audio_encoder_lyra.cpp
# src/audio_encoder_lyra.cpp
src/camera_device_capturer.cpp
src/data_channel.cpp
src/default_video_formats.cpp
Expand Down Expand Up @@ -137,7 +137,7 @@ endif()

target_link_libraries(sora
PUBLIC
Lyra::lyra
# Lyra::lyra
WebRTC::webrtc
Boost::json
Boost::filesystem
Expand Down Expand Up @@ -259,6 +259,7 @@ if (SORA_TARGET_OS STREQUAL "windows")
PUBLIC
WEBRTC_WIN
_ITERATOR_DEBUG_LEVEL=0
_ALLOW_COROUTINE_ABI_MISMATCH
)

if (SORA_TARGET_ARCH STREQUAL "hololens2")
Expand Down Expand Up @@ -624,7 +625,7 @@ install(
cmake/FindWebRTC.cmake
cmake/FindLibdrm.cmake
cmake/FindLibva.cmake
cmake/FindLyra.cmake
# cmake/FindLyra.cmake
DESTINATION ${CMAKE_INSTALL_DATADIR}/cmake
)
install(FILES LICENSE NOTICE.md
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
SORA_CPP_SDK_VERSION=2023.7.2-hololens2.0
WEBRTC_BUILD_VERSION=m114.5735.2.0-hololens2.0
WEBRTC_BUILD_VERSION=m114.5735.2.1-hololens2.0
BOOST_VERSION=1.82.0
CMAKE_VERSION=3.26.4
BAZEL_VERSION=5.3.2
Expand Down
18 changes: 9 additions & 9 deletions run.py
Original file line number Diff line number Diff line change
Expand Up @@ -1405,7 +1405,7 @@ def install_deps(platform: Platform, source_dir, build_dir, install_dir, debug,
# run.py の引数から拾ってくるのが面倒なので環境変数を使う
'temp_dir': os.environ.get('SORA_CPP_SDK_TEMP_DIR'),
}
install_lyra(**install_lyra_args)
# install_lyra(**install_lyra_args)


AVAILABLE_TARGETS = ['windows_x86_64', 'windows_hololens2', 'macos_x86_64', 'macos_arm64', 'ubuntu-20.04_x86_64',
Expand Down Expand Up @@ -1716,14 +1716,14 @@ def main():

# Lyra テストのビルド先のディレクトリに
# Lyra のモデル係数ファイルをコピーする
model_src = os.path.join(install_dir, 'lyra', 'share', 'model_coeffs')
if platform.target.os == 'windows':
model_dst = os.path.join(test_build_dir, configuration, 'model_coeffs')
else:
model_dst = os.path.join(test_build_dir, 'model_coeffs')
rm_rf(model_dst)
mkdir_p(os.path.dirname(model_dst))
shutil.copytree(model_src, model_dst)
# model_src = os.path.join(install_dir, 'lyra', 'share', 'model_coeffs')
# if platform.target.os == 'windows':
# model_dst = os.path.join(test_build_dir, configuration, 'model_coeffs')
# else:
# model_dst = os.path.join(test_build_dir, 'model_coeffs')
# rm_rf(model_dst)
# mkdir_p(os.path.dirname(model_dst))
# shutil.copytree(model_src, model_dst)

if args.run:
if platform.target.os == 'windows':
Expand Down
4 changes: 2 additions & 2 deletions src/sora_audio_decoder_factory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <api/audio_codecs/opus/audio_decoder_multi_channel_opus.h>
#include <api/audio_codecs/opus/audio_decoder_opus.h>

#include "sora/audio_decoder_lyra.h"
// #include "sora/audio_decoder_lyra.h"

namespace sora {

Expand Down Expand Up @@ -43,7 +43,7 @@ CreateBuiltinAudioDecoderFactory() {
webrtc::AudioDecoderOpus,
NotAdvertised<webrtc::AudioDecoderMultiChannelOpus>,
webrtc::AudioDecoderG722, webrtc::AudioDecoderG711,
NotAdvertised<webrtc::AudioDecoderL16>, sora::AudioDecoderLyra>();
NotAdvertised<webrtc::AudioDecoderL16>>();
}

} // namespace sora
4 changes: 2 additions & 2 deletions src/sora_audio_encoder_factory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <api/audio_codecs/opus/audio_encoder_multi_channel_opus.h>
#include <api/audio_codecs/opus/audio_encoder_opus.h>

#include "sora/audio_encoder_lyra.h"
// #include "sora/audio_encoder_lyra.h"

namespace sora {

Expand Down Expand Up @@ -49,7 +49,7 @@ CreateBuiltinAudioEncoderFactory() {
webrtc::AudioEncoderOpus,
NotAdvertised<webrtc::AudioEncoderMultiChannelOpus>,
webrtc::AudioEncoderG722, webrtc::AudioEncoderG711,
NotAdvertised<webrtc::AudioEncoderL16>, sora::AudioEncoderLyra>();
NotAdvertised<webrtc::AudioEncoderL16>>();
}

} // namespace sora
2 changes: 1 addition & 1 deletion test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ endif()

find_package(Boost REQUIRED COMPONENTS json filesystem)
find_package(WebRTC REQUIRED)
find_package(Lyra REQUIRED)
# find_package(Lyra REQUIRED)
find_package(Sora REQUIRED)
find_package(Threads REQUIRED)
find_package(Libdrm)
Expand Down

0 comments on commit 52706fa

Please sign in to comment.