Skip to content

Commit

Permalink
Merge branch 'release/sora-android-sdk-2022.1.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
miosakuma committed Jan 12, 2022
2 parents 4644098 + 15dcafa commit 125695f
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 6 deletions.
5 changes: 5 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,11 @@
- FIX
- バグ修正

## sora-andoroid-sdk-2022.1.0

- [ADD] シグナリング接続時に送信するメタデータを外部ファイルから設定できるようにする
- @miosakuma

## sora-andoroid-sdk-2021.3

- [UPDATE] システム条件を更新する
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Sora Android SDK の使い方は
## システム条件

- Android 5.0 以降 (エミュレーターでの動作は保証しません)
- Android Studio 4.2 以降
- Android Studio 2020.3.1 以降
- WebRTC SFU Sora 2021.1 以降
- Sora Android SDK 2021.3 以降

Expand All @@ -37,4 +37,4 @@ Sora Android SDK の使い方は

## Copyright

Copyright 2021, Shiguredo Inc. and Lyo Kato <lyo.kato at gmail.com>
Copyright 2022, Shiguredo Inc. and Lyo Kato <lyo.kato at gmail.com>
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apply plugin: "com.github.ben-manes.versions"

buildscript {
ext.kotlin_version = '1.4.31'
ext.sora_android_sdk_version = '2021.3'
ext.sora_android_sdk_version = '2022.1.0'

repositories {
google()
Expand Down
6 changes: 6 additions & 0 deletions gradle.properties.example
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,9 @@ android.useAndroidX=true
# Setting Sora's signaling endpoint and channel_id
signaling_endpoint = wss://sora.example.com/signaling
channel_id = sora

# Setting Signaling Metadata.
# Quotes must be double escaped.
# e.g.) signaling_metadata = {\\"spam\\":\\"egg\\"}
# This setting is required. If you do not want to use it, set it to blank.
signaling_metadata =
3 changes: 3 additions & 0 deletions quickstart/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ android {
// アプリで参照する設定を BuildConfig / resource に書き込む。
buildConfigField("String", "SIGNALING_ENDPOINT", "\"${signaling_endpoint}\"")
buildConfigField("String", "CHANNEL_ID", "\"${channel_id}\"")
buildConfigField("String", "SIGNALING_METADATA", "\"${signaling_metadata}\"")

manifestPlaceholders = [usesCleartextTraffic: usesCleartextTraffic]
}
Expand Down Expand Up @@ -45,6 +46,8 @@ dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:${kotlin_version}"
implementation "org.jetbrains.kotlin:kotlin-reflect:${kotlin_version}"

implementation 'com.google.code.gson:gson:2.8.6'

implementation "androidx.appcompat:appcompat:1.2.0"
implementation "com.google.android.material:material:1.3.0"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,20 @@ import android.content.Context
import android.graphics.Color
import android.media.AudioManager
import android.os.Bundle
import com.google.android.material.snackbar.Snackbar
import android.util.Log
import androidx.appcompat.app.AlertDialog
import androidx.appcompat.app.AppCompatActivity
import android.util.Log
import com.google.android.material.snackbar.Snackbar
import com.google.gson.*
import jp.shiguredo.sora.sdk.camera.CameraCapturerFactory
import jp.shiguredo.sora.sdk.channel.SoraMediaChannel
import jp.shiguredo.sora.sdk.channel.option.SoraMediaOption
import jp.shiguredo.sora.sdk.channel.signaling.message.PushMessage
import jp.shiguredo.sora.sdk.error.SoraErrorReason
import jp.shiguredo.sora.sdk.util.SoraLogger
import kotlinx.android.synthetic.main.activity_main.*
import org.webrtc.*
import permissions.dispatcher.*
import kotlinx.android.synthetic.main.activity_main.*

@RuntimePermissions
class MainActivity : AppCompatActivity() {
Expand Down Expand Up @@ -152,6 +153,7 @@ class MainActivity : AppCompatActivity() {
context = this,
signalingEndpoint = BuildConfig.SIGNALING_ENDPOINT,
channelId = BuildConfig.CHANNEL_ID,
signalingMetadata = Gson().fromJson(BuildConfig.SIGNALING_METADATA, Map::class.java),
mediaOption = option,
listener = channelListener)
mediaChannel!!.connect()
Expand Down

0 comments on commit 125695f

Please # to comment.