Skip to content

Commit a7e9df1

Browse files
Migrate to version 1.40.0
1 parent 26fad4a commit a7e9df1

File tree

4 files changed

+28
-4
lines changed

4 files changed

+28
-4
lines changed

app/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ dependencies {
6363

6464
// Banuba Video Editor SDK dependencies
6565

66-
def banubaSdkVersion = '1.39.1'
66+
def banubaSdkVersion = '1.40.0'
6767
implementation "com.banuba.sdk:ffmpeg:5.1.3"
6868
implementation "com.banuba.sdk:camera-sdk:${banubaSdkVersion}"
6969
implementation "com.banuba.sdk:camera-ui-sdk:${banubaSdkVersion}"

app/src/main/java/com/banuba/example/integrationapp/MainActivity.kt

+14-2
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import android.widget.Toast
99
import androidx.activity.result.contract.ActivityResultContracts
1010
import androidx.appcompat.app.AlertDialog
1111
import androidx.appcompat.app.AppCompatActivity
12+
import androidx.core.os.bundleOf
1213
import androidx.lifecycle.lifecycleScope
1314
import com.banuba.example.integrationapp.SampleApp.Companion.ERR_LICENSE_REVOKED
1415
import com.banuba.example.integrationapp.SampleApp.Companion.ERR_SDK_NOT_INITIALIZED
@@ -25,6 +26,11 @@ import com.banuba.sdk.ve.flow.VideoExportResultContract
2526

2627
class MainActivity : AppCompatActivity() {
2728

29+
// Bundle with Editor UI V2 configuration
30+
private val extras = bundleOf(
31+
"EXTRA_USE_EDITOR_V2" to true
32+
)
33+
2834
// Handle Video Editor export results
2935
private val videoEditorExportResult =
3036
registerForActivityResult(VideoExportResultContract()) { result ->
@@ -188,16 +194,22 @@ class MainActivity : AppCompatActivity() {
188194
// setup data that will be acceptable during export flow
189195
additionalExportData = null,
190196
// set TrackData object if you open VideoCreationActivity with preselected music track
191-
audioTrackData = null
197+
audioTrackData = null,
198+
// set Bundle to enable Editor V2
199+
extras = extras
192200
)
193201
startVideoEditor(videoCreationIntent)
194202
}
195203

196204
private fun openVideoEditorDrafts() {
197-
startVideoEditor(VideoCreationActivity.startFromDrafts(this))
205+
startVideoEditor(VideoCreationActivity.startFromDrafts(
206+
this,
207+
extras = extras
208+
))
198209
}
199210

200211
private fun openVideoEditorTrimmerWithSlideShow(videos: List<Uri>) {
212+
// Editor V2 is not available from Trimmer screen
201213
startVideoEditor(
202214
VideoCreationActivity.startFromTrimmer(
203215
this,

mddocs/advanced_integration.md

+12
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ This guide is aimed to help you complete advanced integration of Video Editor SD
99
- [Add audio content](#Add-audio-content)
1010
- [Drafts](#Drafts)
1111
- [Launch methods](#Launch-methods)
12+
- [Editor V2](#editor-v2)
1213

1314
## Video recording
1415
Video editor supports functionality allowing to record video using Android camera. There are many features, configurations and styles
@@ -81,4 +82,15 @@ Video editor will not open in PIP mode if your license token does not support PI
8182
)
8283
```
8384

85+
## Editor V2
86+
87+
To keep up with the latest developments and best practices, our team has completely redesigned the Video Editor SDK to be as convenient and enjoyable as possible.
88+
89+
Create ```Bundle``` with Editor UI V2 configuration and pass ```extras``` to any Video Editor start method.
90+
91+
```kotlin
92+
val extras = bundleOf(
93+
"EXTRA_USE_EDITOR_V2" to true
94+
)
95+
```
8496

mddocs/quickstart.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ android {
7070
Specify a list of dependencies in [gradle](../app/build.gradle#L63) file.
7171

7272
```groovy
73-
def banubaSdkVersion = '1.39.1'
73+
def banubaSdkVersion = '1.40.0'
7474
7575
implementation "com.banuba.sdk:ffmpeg:5.1.3"
7676
implementation "com.banuba.sdk:camera-sdk:${banubaSdkVersion}"

0 commit comments

Comments
 (0)