Skip to content

Commit

Permalink
Merge branch 'develop' of github.com:shiguredo/sora-unity-sdk into de…
Browse files Browse the repository at this point in the history
…velop
  • Loading branch information
voluntas committed Nov 18, 2019
2 parents f25fdea + f1a1852 commit e53309f
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 6 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

[![GitHub tag](https://img.shields.io/github/tag/shiguredo/sora-unity-sdk.svg)](https://github.com/shiguredo/sora-unity-sdk)
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
[![Actions Status](https://github.com/shiguredo/sora-unity-sdk/workflows/build/badge.svg)](https://github.com/shiguredo/sora-unity-sdk/actions)

Sora Unity SDK は [WebRTC SFU Sora](https://sora.shiguredo.jp/) の Unity クライアントアプリケーションを開発するためのライブラリです。

Expand Down Expand Up @@ -44,6 +45,7 @@ Sora Unity SDK に対する有償のサポートについては現在提供し
- マイクから音声を取得し Unity アプリに出力
- Unity アプリで Sora からの音声を受信
- Unity アプリで Sora からの映像を受信
- Unity アプリで Sora からの音声を再生
- Sora から受信した音声を Unity アプリに出力
- Sora から受信した映像を Unity アプリに出力
- マルチストリームへの対応
Expand Down
2 changes: 2 additions & 0 deletions cmake.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/bash

set -ex

INSTALL_DIR="`pwd`/_install"
MODULE_PATH="`pwd`/cmake"

Expand Down
13 changes: 7 additions & 6 deletions src/unity_audio_device.h
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,8 @@ class UnityAudioDevice : public webrtc::AudioDeviceModule {
}
}
virtual bool PlayoutIsInitialized() const override {
auto result = adm_playout_ ? adm_->PlayoutIsInitialized() : is_playing_;
auto result =
adm_playout_ ? adm_->PlayoutIsInitialized() : (bool)is_playing_;
RTC_LOG(LS_INFO) << "PlayoutIsInitialized: result=" << result;
return result;
}
Expand All @@ -224,7 +225,8 @@ class UnityAudioDevice : public webrtc::AudioDeviceModule {
}
}
virtual bool RecordingIsInitialized() const override {
return adm_recording_ ? adm_->RecordingIsInitialized() : is_recording_;
return adm_recording_ ? adm_->RecordingIsInitialized()
: (bool)is_recording_;
}

// Audio transport control
Expand Down Expand Up @@ -256,8 +258,7 @@ class UnityAudioDevice : public webrtc::AudioDeviceModule {
}
}
virtual bool Playing() const override {
return adm_playout_ ? adm_->Playing() : is_playing_;
;
return adm_playout_ ? adm_->Playing() : (bool)is_playing_;
}
virtual int32_t StartRecording() override {
return adm_recording_ ? adm_->StartRecording() : 0;
Expand All @@ -266,7 +267,7 @@ class UnityAudioDevice : public webrtc::AudioDeviceModule {
return adm_recording_ ? adm_->StopRecording() : 0;
}
virtual bool Recording() const override {
return adm_recording_ ? adm_->Recording() : is_recording_;
return adm_recording_ ? adm_->Recording() : (bool)is_recording_;
}

// Audio mixer initialization
Expand Down Expand Up @@ -346,7 +347,7 @@ class UnityAudioDevice : public webrtc::AudioDeviceModule {
} else {
// 今はステレオには対応しない
//*available = true;
available = false;
*available = false;
return 0;
}
}
Expand Down

0 comments on commit e53309f

Please sign in to comment.