Skip to content

Commit 2fe4cdc

Browse files
committed
Merge branch 'develop'
2 parents 41d67dd + 08d811f commit 2fe4cdc

File tree

314 files changed

+15203
-26164
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

314 files changed

+15203
-26164
lines changed

.github/workflows/app-distribute.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,11 @@ jobs:
3030
uses: actions/upload-artifact@v2
3131
with:
3232
name: dogfooding-release
33-
path: dogfooding/build/outputs/apk/release/
33+
path: dogfooding/build/outputs/apk/dogfooding/release/
3434
- name: Upload artifact to Firebase App Distribution
3535
uses: wzieba/Firebase-Distribution-Github-Action@v1.5.0
3636
with:
3737
appId: ${{secrets.FIREBASE_DOGFOODING_SAMPLE_APP_ID}}
3838
serviceCredentialsFileContent: ${{ secrets.CREDENTIAL_FILE_CONTENT }}
3939
groups: stream-testers
40-
file: dogfooding/build/outputs/apk/release/dogfooding-release.apk
40+
file: dogfooding/build/outputs/apk/dogfooding/release/dogfooding-dogfooding-release.apk

.github/workflows/publish-snapshot.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121

2222
- name: Release build
2323
# assembleRelease for all modules, excluding non-library modules: samples, docs
24-
run: ./gradlew assembleRelease -x :app:assembleRelease -x :dogfooding:assembleRelease -x :demo:assembleRelease
24+
run: ./gradlew assembleRelease -x :app:assembleRelease -x :dogfooding:assembleRelease
2525

2626
- name: Source jar and dokka
2727
run: ./gradlew androidSourcesJar javadocJar

.github/workflows/publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424

2525
- name: Release build
2626
# assembleRelease for all modules, excluding non-library modules: samples, docs
27-
run: ./gradlew assembleRelease -x :app:assembleRelease -x :dogfooding:assembleRelease -x :demo:assembleRelease -x :tutorials:tutorial-video:assembleRelease -x :tutorials:tutorial-audio:assembleRelease
27+
run: ./gradlew assembleRelease -x :app:assembleRelease -x :dogfooding:assembleRelease -x :tutorials:tutorial-video:assembleRelease -x :tutorials:tutorial-audio:assembleRelease
2828

2929
- name: Source jar and dokka
3030
run: ./gradlew androidSourcesJar javadocJar

README.md

Lines changed: 35 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,17 @@ Most users start with the Compose UI components and fall back to the lower-level
1919

2020
Stream allows developers to rapidly deploy scalable feeds, chat messaging and video with an industry leading 99.999% uptime SLA guarantee.
2121

22+
Stream provides UI components and state handling that make it easy to build video calling for your app. All calls run on Stream's network of edge servers around the world, ensuring optimal latency and reliability.
23+
24+
## 📕 Tutorials
25+
2226
With Stream's video components, you can use their SDK to build in-app video calling, audio rooms, audio calls, or live streaming. The best place to get started is with their tutorials:
2327

24-
- Video & Audio Calling Tutorial
25-
- Audio Rooms Tutorial
26-
- Livestreaming Tutorial
28+
- **[Video & Audio Calling Tutorial](https://getstream.io/video/docs/android/tutorials/video-calling/)**
29+
- **[Audio Rooms Tutorial](https://getstream.io/video/docs/android/tutorials/audio-room/)**
30+
- **[Livestreaming Tutorial](https://getstream.io/video/docs/android/tutorials/livestream/)**
2731

28-
Stream provides UI components and state handling that make it easy to build video calling for your app. All calls run on Stream's network of edge servers around the world, ensuring optimal latency and reliability.
32+
If you're interested in customizing the UI components for the Video SDK, check out the **[UI Cookbook](https://getstream.io/video/docs/android/ui-cookbook/overview/)**.
2933

3034
## 📱 Previews
3135

@@ -73,46 +77,53 @@ Video roadmap and changelog is available [here](https://github.com/GetStream/pro
7377

7478
### 0.2.0 milestone
7579

76-
- [ ] Deeplink support for video call demo & dogfooding app (skip auth for the video demo, keep it for dogfooding) (Daniel)
77-
- [ ] Chat Integration (Jaewoong)
78-
- [ ] XML version of VideoRenderer (Jaewoong)
79-
- [ ] Local Video disconnects sometimes (ICE restarts issue for the publisher. we're waiting for the backend support) (Thierry)
80-
- [ ] Call Analytics stateflow (Thierry)
81-
- [ ] Automatically handle pagination and sorting on > 6 participants
82-
- [ ] Ringing: Make it easy to test
83-
- [ ] Ringing: Make a list of what needs to be configurable
8480
- [ ] Publish app on play store
85-
- [ ] Report version number of SDK on all API calls (Daniel)
86-
- [ ] Bug: java.net.UnknownHostException: Unable to resolve host "hint.stream-io-video.com" isn't throw but instead logged as INFO (Daniel)
87-
- [ ] Bug: screensharing is broken. android doesn’t receive/render (not sure) the screenshare. video shows up as the gray avatar
81+
- [ ] Bug: Screensharing on Firefox has some issues when rendering on android (Daniel)
82+
- [X] Example Button to switch speakerphone/earpiece (Jaewoong)
83+
- [X] Chat Integration (Jaewoong)
84+
- [X] Automatically handle pagination and sorting on > 6 participants in the sample app (Daniel)
85+
- [X] Buttons to simulate ice restart and SFU switching (Jaewoong)
86+
- [X] Bug: java.net.UnknownHostException: Unable to resolve host "hint.stream-io-video.com" isn't throw but instead logged as INFO (Daniel)
87+
- [X] Bug: Call.join will throw an exception if error is other than HttpException
88+
- [X] Report version number of SDK on all API calls (Daniel)
89+
- [X] Bug: screensharing is broken. android doesn’t receive/render (not sure) the screenshare. video shows up as the gray avatar
90+
- [X] support settings.audio.default_device (Daniel)
91+
- [X] Bug: Sample app has a bug where we don't subscribe to call changes, we need to use call.get in the preview screen so we know the number of participants (Daniel)
92+
- [X] Buttons to simulate ice restart and SFU switching (Jaewoong)
93+
- [X] Local Video disconnects sometimes (ICE restarts issue for the publisher. we're waiting for the backend support) (Thierry)
94+
- [X] Deeplink support for video call demo & dogfooding app (skip auth for the video demo, keep it for dogfooding) (Jaewoong)
95+
- [X] XML version of VideoRenderer (Jaewoong)
96+
- [X] sortedParticipants stateflow doesn't update accurately (Thierry)
8897
- [X] Reactions
89-
- [X] bug: screenshare is not removed after it stops when a participant leaves the call (Thierry) (probably just dont update the state when the participant leaves)
98+
- [X] Bug: screenshare is not removed after it stops when a participant leaves the call (Thierry) (probably just dont update the state when the participant leaves)
9099

91100
### 0.3.0 milestone
92101

93-
- [ ] Setting to default to speakerphone or earpiece
94-
- [ ] Button to switch speakerphone/earpiece
102+
- [ ] Ringing: Make it easy to test
103+
- [ ] Ringing: Make a list of what needs to be configurable
104+
- [ ] Ringing: Sounds for incoming, outgoing, call timed out. Sound for someone joining a call (Disabled by default). Docs on how to change them
105+
- [ ] Call Analytics stateflow (Thierry)
106+
- [ ] Pagination on query members & query channel endpoints (Daniel)
107+
- [ ] Audio & Video filters. Support (Daniel)
95108
- [ ] Livestream tutorial (depends on RTMP support)
96109
- [ ] H264 workaround on Samsung 23 (see https://github.com/livekit/client-sdk-android/blob/main/livekit-android-sdk/src/main/java/io/livekit/android/webrtc/SimulcastVideoEncoderFactoryWrapper.kt#L34 and
97110
- https://github.com/react-native-webrtc/react-native-webrtc/issues/983#issuecomment-975624906)
98-
- [ ] Bluetooth reliability
99111
- [ ] Dynascale 2.0 (codecs, f resolution switches, resolution webrtc handling)
100112
- [ ] Test coverage
101113
- [ ] Testing on more devices
102-
- [ ] Speaking while muted stateflow
114+
- [ ] local version of audioLevel(s) for lower latency audio visualizations(Daniel)
103115
- [ ] Android SDK development.md cleanup (Daniel)
104116
- [ ] Logging is too verbose (rtc is very noisy), clean it up to focus on the essential for info and higher
117+
- [X] Speaking while muted stateflow (Daniel)
118+
- [X] Bluetooth reliability
105119
- [X] Cleanup the retry behaviour in the RtcSession
106120
- [X] SDK development guide for all teams
107121

108122
### 0.4.0 milestone
109123

110-
- [ ] Pagination on query members & query channels
111-
- [ ] Analytics integration
112124
- [ ] Screensharing from mobile
113125
- [ ] Tap to focus
114126
- [ ] Camera controls
115-
- [ ] Audio & Video filters
116127
- [ ] Picture of the video stream at highest resolution
117128
- [ ] Review foreground service vs backend for some things like screensharing etc
118129

@@ -138,4 +149,4 @@ distributed under the License is distributed on an "AS IS" BASIS,
138149
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
139150
See the License for the specific language governing permissions and
140151
limitations under the License.
141-
```
152+
```

app/src/main/AndroidManifest.xml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,25 @@
4848
<category android:name="android.intent.category.LAUNCHER" />
4949
</intent-filter>
5050
</activity>
51+
52+
<activity
53+
android:name=".DeeplinkingActivity"
54+
android:exported="true"
55+
android:launchMode="singleTask">
56+
<tools:validation testUrl="https://stream-video-demo.vercel.app/?id=civil-ff49b5e0" />
57+
<intent-filter
58+
android:autoVerify="true"
59+
android:label="@string/filter_call_link">
60+
61+
<action android:name="android.intent.action.VIEW" />
62+
63+
<category android:name="android.intent.category.DEFAULT" />
64+
<category android:name="android.intent.category.BROWSABLE" />
65+
66+
<data android:scheme="https" />
67+
<data android:host="stream-video-demo.vercel.app" />
68+
</intent-filter>
69+
</activity>
5170
</application>
5271

5372
</manifest>
Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
/*
2+
* Copyright (c) 2014-2022 Stream.io Inc. All rights reserved.
3+
*
4+
* Licensed under the Stream License;
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* https://github.com/GetStream/stream-video-android/blob/main/LICENSE
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*/
16+
17+
package io.getstream.video.android.app
18+
19+
import android.content.Intent
20+
import android.net.Uri
21+
import android.os.Bundle
22+
import androidx.activity.ComponentActivity
23+
import androidx.activity.compose.setContent
24+
import androidx.compose.foundation.background
25+
import androidx.compose.foundation.layout.Box
26+
import androidx.compose.foundation.layout.fillMaxSize
27+
import androidx.compose.material.CircularProgressIndicator
28+
import androidx.compose.ui.Alignment
29+
import androidx.compose.ui.Modifier
30+
import io.getstream.log.taggedLogger
31+
import io.getstream.video.android.app.ui.MainActivity
32+
import io.getstream.video.android.compose.theme.VideoTheme
33+
import io.getstream.video.android.model.StreamCallId
34+
35+
class DeeplinkingActivity : ComponentActivity() {
36+
37+
private val logger by taggedLogger("Call:DeeplinkView")
38+
39+
override fun onCreate(savedInstanceState: Bundle?) {
40+
logger.d { "[onCreate] savedInstanceState: $savedInstanceState" }
41+
super.onCreate(savedInstanceState)
42+
43+
setContent {
44+
VideoTheme {
45+
Box(
46+
modifier = Modifier
47+
.fillMaxSize()
48+
.background(VideoTheme.colors.appBackground)
49+
) {
50+
CircularProgressIndicator(
51+
modifier = Modifier.align(Alignment.Center),
52+
color = VideoTheme.colors.primaryAccent
53+
)
54+
}
55+
}
56+
}
57+
58+
val data: Uri = intent?.data ?: return
59+
val callId = data.toString().split("id=").lastOrNull() ?: return
60+
61+
logger.d { "Action: ${intent?.action}" }
62+
logger.d { "Data: ${intent?.data}" }
63+
64+
joinCall(callId)
65+
}
66+
67+
private fun joinCall(cid: String) {
68+
val callId = StreamCallId(type = "default", id = cid)
69+
val intent = MainActivity.createIntent(
70+
context = this@DeeplinkingActivity, callId = callId
71+
).apply {
72+
flags = Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_CLEAR_TASK
73+
}
74+
startActivity(intent)
75+
finish()
76+
}
77+
}

app/src/main/kotlin/io/getstream/video/android/app/ui/MainActivity.kt

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616

1717
package io.getstream.video.android.app.ui
1818

19+
import android.content.Context
20+
import android.content.Intent
1921
import android.os.Bundle
2022
import androidx.activity.ComponentActivity
2123
import androidx.activity.compose.setContent
@@ -33,6 +35,7 @@ import io.getstream.result.Result
3335
import io.getstream.video.android.compose.theme.VideoTheme
3436
import io.getstream.video.android.core.Call
3537
import io.getstream.video.android.core.call.RtcSession
38+
import io.getstream.video.android.model.StreamCallId
3639
import io.getstream.video.android.model.User
3740

3841
class MainActivity : ComponentActivity() {
@@ -50,7 +53,8 @@ class MainActivity : ComponentActivity() {
5053
)
5154

5255
// step 2 - join a call
53-
vm.joinCall(context = this, user = user)
56+
val callId = intent.getParcelableExtra<StreamCallId>(EXTRA_CID)
57+
vm.joinCall(context = this, user = user, callId = callId)
5458

5559
// step 3 - build a call screen
5660
setContent {
@@ -62,6 +66,20 @@ class MainActivity : ComponentActivity() {
6266
}
6367
}
6468
}
69+
70+
companion object {
71+
const val EXTRA_CID: String = "EXTRA_CID"
72+
73+
@JvmStatic
74+
fun createIntent(
75+
context: Context,
76+
callId: StreamCallId,
77+
): Intent {
78+
return Intent(context, MainActivity::class.java).apply {
79+
putExtra(EXTRA_CID, callId)
80+
}
81+
}
82+
}
6583
}
6684

6785
@Composable

app/src/main/kotlin/io/getstream/video/android/app/ui/MainViewModel.kt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ import io.getstream.video.android.app.videoApp
2727
import io.getstream.video.android.core.Call
2828
import io.getstream.video.android.core.call.RtcSession
2929
import io.getstream.video.android.core.logging.LoggingLevel
30+
import io.getstream.video.android.model.StreamCallId
3031
import io.getstream.video.android.model.User
3132
import kotlinx.coroutines.flow.MutableStateFlow
3233
import kotlinx.coroutines.flow.StateFlow
@@ -40,7 +41,7 @@ class MainViewModel : ViewModel() {
4041
private val _result: MutableStateFlow<Result<RtcSession>?> = MutableStateFlow(null)
4142
val result: StateFlow<Result<RtcSession>?> = _result
4243

43-
fun joinCall(context: Context, user: User) {
44+
fun joinCall(context: Context, user: User, callId: StreamCallId?) {
4445
viewModelScope.launch {
4546
val response = StreamVideoNetwork.tokenService.fetchToken(
4647
userId = user.id,
@@ -55,7 +56,8 @@ class MainViewModel : ViewModel() {
5556
loggingLevel = LoggingLevel(priority = Priority.DEBUG)
5657
)
5758

58-
val call = streamVideo.call(type = "default", id = "1egoN4tKm4w2")
59+
val cid = callId ?: StreamCallId(type = "default", id = "1egoN4tKm4w2")
60+
val call = streamVideo.call(type = cid.type, id = cid.id)
5961
val result = call.join(create = true)
6062
_result.value = result
6163

buildSrc/src/main/kotlin/io/getstream/video/android/Configuration.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ object Configuration {
55
const val targetSdk = 33
66
const val minSdk = 24
77
const val majorVersion = 0
8-
const val minorVersion = 1
8+
const val minorVersion = 2
99
const val patchVersion = 0
1010
const val versionName = "$majorVersion.$minorVersion.$patchVersion"
1111
const val versionCode = 1

demo/.gitignore

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)