Migrating from PlanetKit 4.4 to 5.5
This guide provides detailed steps and considerations for migrating from PlanetKit 4.4 to PlanetKit 5.5.
Requirements
Change the SDK distribution channel to the Maven Central Repository
-
Starting with version 5.3.3, PlanetKit Android is distributed through the Maven Central Repository.
-
If the Maven Central Repository is not set up in your project, add the repository as follows:
// Root-level build.gradle
allprojects {
repositories {
mavenCentral()
}
} -
Add dependency to your module
build.gradle
.// module-level build.gradle
dependencies {
...
implementation 'com.linecorp.planetkit:planetkit:5.5.2'
...
}
Permission required for Bluetooth connection on Android 12 or higher
BLUETOOTH_CONNECT
permission is required for Bluetooth connection on Android devices with Android 12 (API level 31) or higher. Refer to Android documentation.- If
BLUETOOTH_CONNECT
permission is not granted on Android 12 or higher, it can cause some problems because it cannot guarantee the operation of the Bluetooth API. - Therefore, in this case, PlanetKit does not switch to Bluetooth even if your device is connected with Bluetooth.
- Request
BLUETOOTH_CONNECT
permission to communicate with a Bluetooth device.
Request permission at runtime
- The protection level of
BLUETOOTH_CONNECT
is defined as dangerous (runtime permission). - Therefore, user consent is required when using Bluetooth and some UX scenarios may be necessary.
- These UX scenario will be determined by your application. For example, the demo app and LINE App show a permission request pop-up when the user selects Bluetooth in the audio route menu.
Code examples
-
This sample code is an example of Bluetooth selection from the audio route menu.
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S) {
if (ContextCompat.checkSelfPermission(
context,
Manifest.permission.BLUETOOTH_CONNECT
) != PackageManager.PERMISSION_GRANTED) {
ActivityCompat.requestPermissions(context, arrayOf(Manifest.permission.BLUETOOTH_CONNECT), 0)
return
}
}
call?.getAudioSwitch()?.setAudioRoute(PlanetKitAudioRoute.BLUETOOTH)
Specify Android permissions required by PlanetKit
-
The permissions required by PlanetKit are specified in the
AndroidManifest.xml
file of PlanetKit. -
If your app's
AndroidManifest.xml
already includes some of these permissions, there may be overlaps, but it should not cause any issues. -
The following is the list of permissions required by PlanetKit.
<!--AndroidManifest.xml of PlanetKit-->
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.VIBRATE" />
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />
<uses-permission android:name="android.permission.BLUETOOTH"
android:maxSdkVersion="30"/>
<uses-permission android:name="android.permission.BLUETOOTH_CONNECT" />
App implementation requirements depending on targetSdkVersion
- The demo app code has been updated to meet the requirements of
targetSdkVersion
34 or higher. - Please refer to the demo app code and update your app.
Type | Affected version | Requirements | Reference |
---|---|---|---|
POST_NOTIFICATIONS | targetSdkVersion 33 or higher | POST_NOTIFICATIONS permission is required for posting notifications on Android devices with Android 13 (API level 33) or higher. | POST_NOTIFICATIONS |
Foreground service types | targetSdkVersion 34 or higher | Implement a foreground service with the necessary permissions. There are many foreground permissions according to your app use cases, such as FOREGROUND_SERVICE_MICROPHONE , FOREGROUND_SERVICE_MEDIA_PLAYBACK , FOREGROUND_SERVICE_MEDIA_PROJECTION , etc. | Foreground service types are required |
Migration
Breaking change Improve PlanetKit initialization
- The initialization of PlanetKit has been changed to be processed by the worker thread for processing such as file I/O, etc.
OnInitializeCompleteListener.onComplete()
is invoked when the initialization is complete.- The
userAgent
andisVideoHwCodecSupport
information is provided byonComplete
, so the relevant API has been deleted.
API changes
Changed
-
PlanetKit
class 1-to-1 callGroup callPrevious PlanetKit 5.5 val userAgent: String
OnInitializeCompleteListener.onComplete(isSuccessful, isVideoHwCodecSupport, userAgent)
val isVideoHwCodecSupport: Boolean
OnInitializeCompleteListener.onComplete(isSuccessful, isVideoHwCodecSupport, userAgent)
fun initialize(config: PlanetKitConfiguration)
fun initialize(config: PlanetKitConfiguration, listener: OnInitializeCompleteListener)
Added
PlanetKit
class 1-to-1 callGroup callfun interface OnInitializeCompleteListener
Code examples
class YourApplication : Application() {
override fun onCreate() {
...
val configBuilder = PlanetKit.PlanetKitConfiguration.Builder(this)
.setServerUrl(planet_base_url)
...
PlanetKit.initialize(configBuilder.build()) { isSuccessful, isVideoHwCodecSupport, userAgent ->
// Add implementation in your app if necessary
}
...
}
}
Breaking change Remove the PlanetKitSession
interface
- The structure where
PlanetKitCall
andPlanetKitConference
were inheriting fromPlanetKitSession
has been removed. - Common functions previously found in
PlanetKitSession
have been added to bothPlanetKitCall
andPlanetKitConference
, respectively.
API changes
Changed
-
PlanetKitSession
interface 1-to-1 callGroup callPrevious PlanetKit 5.5 interface PlanetKitSession
interface PlanetKitCall
,interface PlanetKitConference
-
OnNoVideoSourceListener
interface 1-to-1 callGroup callPrevious PlanetKit 5.5 fun onNoVideoSource(session: PlanetKitSession)
fun onMyVideoNoSourceDetected(call: PlanetKitCall)
,fun onMyVideoNoSourceDetected(conference: PlanetKitConference)
Breaking change Replace DefaultCameraVideoSource
with PlanetKitCameraManager
- The
PlanetKitCameraManager
interface provides a set of methods and properties for managing camera operations within the PlanetKit. It encapsulates the camera functionalities provided by PlanetKit, allowing for configuration of camera settings and subscription to state change events. - Changes to the camera device control policy
- Starting with PlanetKit 5.5, the camera device is turned on when at least one of the following conditions is met, and it is turned off when none of these conditions are satisfied:
- There is at least one
PlanetKitVideoView
rendering a preview viaPlanetKitCameraManager.startPreview()
. - A
PlanetKitCall
orPlanetKitConference
is connected, andPlanetKitMyMediaStatus.myVideoStatus.videoState
isENABLED
.
- There is at least one
- Starting with PlanetKit 5.5, the camera device is turned on when at least one of the following conditions is met, and it is turned off when none of these conditions are satisfied:
API changes
Changed
-
PlanetKit
object 1-to-1 callGroup callPrevious PlanetKit 5.5 fun getDefaultCameraVideoSource(): DefaultCameraVideoSource
fun getCameraManager(): PlanetKitCameraManager
Added
PlanetKitCameraManager
interface 1-to-1 callGroup callval resolution: PlanetKitCameraResolution
var cameraType: PlanetKitCameraType
val isStarted: Boolean
val fps: Int
fun setStateListener(listener: StateListener?)
fun setManualResolution(resolution: PlanetKitCameraResolution)
fun setDefaultResolution()
fun setVirtualBackgroundPlugin(plugin: PlanetKitPluginVirtualBackground) :Boolean
fun addCameraTypeChangedListener(listener: CameraTypeChangedListener)
fun removeCameraTypeChangedListener(listener: CameraTypeChangedListener)
fun setVideoSourceInterceptor(interceptor: PlanetKitVideoInterceptor?)
fun startPreview(view: PlanetKitVideoView): Boolean
fun stopPreview(view: PlanetKitVideoView): Boolean
fun enableDumpFrame(enable: Boolean)
PlanetKitCameraManager.StateListener
interface 1-to-1 callGroup callfun onStart()
fun onStop()
fun onError(@ErrorCode code: Int)
PlanetKitCameraManager.CameraTypeChangedListener
interface 1-to-1 callGroup callfun onChanged(isFrontCamera: Boolean)
PlanetKitCameraResolution
enum class 1-to-1 callGroup callQVGA
VGA
HD
Removed
DefaultCameraVideoSource
class 1-to-1 callGroup call
Code examples
How to obtain the class
-
The handling of camera properties in the previous version is as follows.
fun userFunction() {
PlanetKit.getDefaultCameraVideoSource().cameraType = PlanetKitCameraType.FRONT
//...
} -
Beginning with version 5.5, the handling of camera properties is as follows.
fun userFunction() {
PlanetKit.getCameraManager().cameraType = PlanetKitCameraType.FRONT
//...
}
How to use camera preview
-
The handling of camera preview in the previous version is as follows.
val isCameraUsedByAnotherClass: Boolean
fun startRenderPreviewOnMyVideoView(view: PlanetKitVideoView) {
PlanetKit.getDefaultCameraVideoSource().addMyVideoView(view)
if (!PlanetKit.getDefaultCameraVideoSource()) {
PlanetKit.getDefaultCameraVideoSource().start()
}
}
fun stopRenderPreviewOnMyVideoView(view: PlanetKitVideoView) {
PlanetKit.getDefaultCameraVideoSource().removeMyVideoView(view)
/* Check If Camera should be stopped */
if (isCameraUsedByAnotherClass == false) {
PlanetKit.getDefaultCameraVideoSource().stop()
}
} -
Beginning with version 5.5, the handling of camera preview is as follows.
fun startRenderPreviewOnMyVideoView(view: PlanetKitVideoView) {
PlanetKit.getCameraManager().startPreview(view)
}
fun stopRenderPreviewOnMyVideoView(view: PlanetKitVideoView) {
PlanetKit.getCameraManager().stopPreview(view)
}
Breaking change Deprecate use of API key in APIs
- Use of API key has been deprecated. Use an access token.
- Related APIs have been deprecated.
API changes
Removed
PlanetKitDisconnectReason
enum 1-to-1 callGroup callSERVICE_APIKEY_ERROR
PlanetKitCallParam
class 1-to-1 callval apiKey: String?
PlanetKitCallParam.Builder
class 1-to-1 callfun apiKey(apiKey: String)
PlanetKitConferenceParam
class Group callval apiKey: String?
PlanetKitConferenceParam.Builder
class Group callfun apiKey(apiKey: String)
Breaking change Update log settings
- You can use the appropriate
PlanetKitLogLevel
andPlanetKitLogSizeLimit
depending on your logging policy. - You can set the size of the log file.
- The log levels have been simplified.
- PlanetKit logs have been encrypted.
- The console log output has been removed.
- Related APIs have been changed.
API changes
Changed
-
PlanetKitLogLevel
enum class 1-to-1 callGroup callPrevious PlanetKit 5.5 VERBOSE
DETAILED
DEBUG
DETAILED
INFO
SIMPLE
WARN
SIMPLE
ERROR
SIMPLE
CRITICAL
SIMPLE
NONE
SILENT
Added
PlanetKitLogSizeLimit
enum class 1-to-1 callGroup callPlanetKitConfiguration.Builder
class 1-to-1 callGroup callfun setLogSizeLimit(logSizeLimit: PlanetKitLogSizeLimit)
Removed
-
PlanetKitConfiguration.Builder
class 1-to-1 callGroup callfun logToConsole( isEnabled: Boolean )
-
PlanetKitConfiguration.Builder
class 1-to-1 callGroup callPrevious PlanetKit 5.5 fun serverUrl( serverUrl: String )
fun setServerUrl( serverUrl: String )
fun logToFile( isEnabled: Boolean )
fun enableLog( isEnabled: Boolean )
fun logLevel( logLevel: PlanetKitLogLevel )
fun setLogLevel( logLevel: PlanetKitLogLevel )
Code examples
class YourApplication : Application()
{
override fun onCreate()
{
...
val configBuilder = PlanetKit.PlanetKitConfiguration.Builder(this)
.setServerUrl(planet_base_url)
.enableLog(true)
.setLogLevel(PlanetKitLogLevel.DETAILED)
.setLogSizeLimit(PlanetKitLogSizeLimit.LARGE)
...
PlanetKit.initialize(configBuilder.build()) { isSuccessful, isVideoHwCodecSupport, userAgent ->
...
}
...
}
}
Breaking change Update PlanetKitCall
- The parameter
mediaType
has been removed fromacceptCall()
. - The parameter
pauseRecv
has been removed fromhold()
.
API changes
Changed
-
PlanetKitCall
class 1-to-1 callPrevious PlanetKit 5.5 fun acceptCall(mediaType:PlanetKitMediaType, listener:AcceptCallListener)
fun acceptCall(listener: AcceptCallListener, initialMyVideoState: PlanetKitInitialMyVideoState = PlanetKitInitialMyVideoState.RESUME, useResponderPreparation: Boolean = false, recordOnCloud: Boolean = false)
fun acceptCall(mediaType:PlanetKitMediaType, listener:AcceptCallListener, callInitData:PlanetKitCallInitData = PlanetKitCallInitData())
fun acceptCall(listener: AcceptCallListener, callStartMessage: PlanetKitCallStartMessage, initialMyVideoState: PlanetKitInitialMyVideoState = PlanetKitInitialMyVideoState.RESUME, useResponderPreparation: Boolean = false, recordOnCloud: Boolean = false)
fun hold(pauseRecv:Boolean, reason:String? = null, callback:PlanetKitRequestCallback? = null): Boolean
fun hold(reason: String? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun hold(pauseRecv:Boolean, callback: PlanetKitRequestCallback? = null): Boolean
fun hold(reason:String? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun hold(pauseRecv:Boolean, reason:String? = null): Boolean
fun hold(reason:String? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun hold(pauseRecv:Boolean): Boolean
fun hold(reason:String? = null, callback: PlanetKitRequestCallback? = null): Boolean
Breaking change Add PlanetKitCCParam
PlanetKitCCParam
is a class representing message data received from the cloud server.PlanetKitCCParam
lets you know call information in advance.- Message data is required for creating
PlanetKitCCParam
. - In addition, when performing
verifyCall()
, it has been changed to usePlanetKitCCParam
instead of message data.
API changes
Added
PlanetKitCCParam
class 1-to-1 callval peerId: String
val peerServiceId: String
val mediaType: PlanetKitMediaType
fun create(messageData: String): PlanetKitCCParam?
Changed
-
PlanetKitVerifyCallParam
class 1-to-1 callPrevious PlanetKit 5.5 val messageData: String
val cCParam: PlanetKitCCParam
-
PlanetKitVerifyCallParam.Builder
class 1-to-1 callPrevious PlanetKit 5.5 fun messageData(messageData: String)
fun cCParam(cCParam: PlanetKitCCParam)
Code examples
override fun onMessageReceived(message: RemoteMessage) {
val cCParamStr = message.data["cc_param"]
/// PlanetKit 4.4
val param = PlanetKitVerifyCallParam.Builder().messageData(cCParamStr)
...
/// PlanetKit 5.5
val planetCCParam = PlanetKitCCParam.create(CParamStr)
Log.d("PushMessage", "ccParam{peerId=${planetCCParam.peerId}, peerServiceId=${planetCCParam.peerServiceId}, mediaType=${planetCCParam.mediaType}")
val param = PlanetKitVerifyCallParam.Builder().cCParam(planetCCParam)
...
}
Breaking change Change naming and interface of PlanetKitCallInitData
- It has been changed to a clearer name,
PlanetKitCallStartMessage
, that matches the behavior ofPlanetKitCallInitData
. useResponderPreparation
has been separated fromPlanetKitCallStartMessage
because it is a different feature fromPlanetKitCallStartMessage
.- The maximum size of
PlanetKitCallStartMessage
is limited to 200 bytes. - Related APIs have been changed.
API changes
Added
PlanetKitCall
class 1-to-1 callval myUseResponderPreparation: Boolean
val myCallStartMessage: PlanetKitCallStartMessage?
val peerUseResponderPreparation: Boolean
val peerCallStartMessage: PlanetKitCallStartMessage?
fun acceptCall( listener: AcceptCallListener, useResponderPreparation: Boolean = false )
fun acceptCall( listener: AcceptCallListener, callStartMessage: PlanetKitCallStartMessage, useResponderPreparation: Boolean = false )
PlanetKitCallConnectedParam
data class 1-to-1 callval peerStartMessage: PlanetKitCallStartMessage?
val isInResponderPreparation: Boolean
PlanetKitCallStartMessage
data class 1-to-1 callval data: String
Removed
PlanetKitCall
class 1-to-1 callval myCallInitData: PlanetKitCallInitData?
val peerCallInitData: PlanetKitCallInitData?
fun acceptCall(mediaType: PlanetKitMediaType, listener: AcceptCallListener, callInitData:PlanetKitCallInitData )
fun acceptCall( listener: AcceptCallListener, callInitData: PlanetKitCallInitData = PlanetKitCallInitData() )
PlanetKitCallInitData
class 1-to-1 call
Changed
-
CallListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onVerified(call: PlanetKitCall, callerInitData: PlanetKitCallInitData)
fun onVerified(call: PlanetKitCall, peerStartMessage: PlanetKitCallStartMessage?, peerUseResponderPreparation: Boolean)
fun onConnected(call: PlanetKitCall, calleeInitData: PlanetKitCallInitData)
fun onConnected(call: PlanetKitCall, param: PlanetKitCallConnectedParam)
-
AcceptCallListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onConnected( call:PlanetKitCall, calleeInitData: PlanetKitCallInitData )
fun onConnected( call: PlanetKitCall, param: PlanetKitCallConnectedParam )
-
MakeCallListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onConnected( call:PlanetKitCall, calleeInitData: PlanetKitCallInitData )
fun onConnected( call: PlanetKitCall, param: PlanetKitCallConnectedParam )
-
VerifyListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onVerified(call: PlanetKitCall, callerInitData: PlanetKitCallInitData)
fun onVerified(call: PlanetKitCall, peerStartMessage: PlanetKitCallStartMessage?, peerUseResponderPreparation: Boolean)
-
PlanetKitCallParam
class 1-to-1 callPrevious PlanetKit 5.5 val callInitData: String
val callStartMessage: PlanetKitCallStartMessage?
val isResponderPrepare: Boolean
val useResponderPreparation: Boolean
-
PlanetKitCallParam.Builder
class 1-to-1 callPrevious PlanetKit 5.5 fun callInitData(callInitData: String)
fun callStartMessage(callStartMessage: PlanetKitCallStartMessage)
fun responderPrepare(isResponderPrepare: Boolean)
fun responderPreparation(useResponderPreparation: Boolean)
Code examples
val paramBuilder = PlanetKitCallParam.Builder()
.peerId(targetId)
.responderPreparation(true)
val callStartMessage = PlanetKitCallStartMessage.create("Hello")
if (callStartMessage == null) {
Log.w(TAG, "Could not create call start message.\n"
+ "Plz check data size. The maximum size of data allowed is 200 bytes."
)
return
}
paramBuilder.callStartMessage(callStartMessage)
val callParam = paramBuilder.build()
PlanetKit.makeCall(param, callListener)
Breaking change Change the parameters of onVerified
and onConnected
in CallListener
- Renamed the parameters to clearer names that match the behaviors.
- The changed parameters contain more information.
- Related APIs have been changed.
API changes
Added
PlanetKitCallConnectedParam
data class 1-to-1 callval isDataSessionSupported: Boolean
val isVideoHwCodecEnabled: Boolean
val peerStartMessage: PlanetKitCallStartMessage?
val isInResponderPreparation: Boolean
val shouldFinishPreparation: Boolean
Changed
-
CallListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onConnected(call: PlanetKitCall, calleeInitData: PlanetKitCallInitData)
fun onConnected(call: PlanetKitCall, param: PlanetKitCallConnectedParam)
-
AcceptCallListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onConnected( call:PlanetKitCall, calleeInitData: PlanetKitCallInitData )
fun onConnected( call: PlanetKitCall, param: PlanetKitCallConnectedParam )
-
MakeCallListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onConnected( call:PlanetKitCall, calleeInitData: PlanetKitCallInitData )
fun onConnected( call: PlanetKitCall, param: PlanetKitCallConnectedParam )
-
VerifyListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onVerified(call: PlanetKitCall, callerInitData: PlanetKitCallInitData)
fun onVerified(call: PlanetKitCall, peerStartMessage: PlanetKitCallStartMessage?, peerUseResponderPreparation: Boolean)
Breaking change Remove meaningless API PlanetKitCall.reject()
- Even when rejecting an incoming call, you should use the function
endCall()
instead ofreject()
, soreject()
has been removed.
API changes
Removed
PlanetKitCall
interface 1-to-1 callfun reject()
Breaking change Update PlanetKitConferencePeer
PlanetKitConferencePeer
PlanetKitConferencePeerInfo
, which represented peer information, was integrated intoPlanetKitConferencePeer
.PlanetKitConferencePeerInfo
has been deprecated since 5.0, and has been superseded byPlanetKitConferencePeer
.- All other APIs using
PlanetKitConferencePeerInfo
are superseded by APIs usingPlanetKitConferencePeer
. PlanetKitConferencePeer
has new API added, so please refer to the documentation.
AudioVolumeResult
- Represents the return value for
getAudioVolumeLevelSetting()
HoldStatus
- Represents information about whether this user is holding a call and why the call is on hold
PeerGetFailReason
- Represents the reason for the failure of
getVideoStatus()
,getScreenShareState()
andgetAudioVolumeLevelSetting()
ScreenShareStateResult
- Represents the return value for
getScreenShareState()
VideoStatusResult
- Represents the return value for
getVideoStatus()
getAudioVolumeLevelSetting()
- Gets the volume level of the given user from this subgroup (min: 0, max: 110)
- It replaces
audioVolume
getScreenShareState()
- Returns this member's state of screen share in
PlanetKitSubgroup
- It replaces
screenSharingState
getVideoStatus()
- Returns this member's video status in
PlanetKitSubgroup
- It replaces
videoStatus
audioSubgroupName
- Removed since 5.0
- Changed to get a value through
ConferenceListener.onPeersAudioDescriptionUpdated
. - For more information, refer to Change audio volume polling to events.
audioTaggedSubgroupName
- Removed since 5.0
- Changed to get a value through
ConferenceListener.onPeersAudioDescriptionUpdated
. - For more information, refer to Change audio volume polling to events.
displayName
- It replaces
PlanetKitConferencePeerInfo.displayName
holdStatus
- It replaces
PlanetKitConferencePeerInfo.holdReason
andPlanetKitConferencePeerInfo.isOnHold
isAudioMuted
- It replaces
PlanetKitConferencePeerInfo.isAudioMuted
isDataSessionSupported
- It replaces
PlanetKitConferencePeerInfo.isDataSessionSupport
mediaType
- It replaces
PlanetKitConferencePeerInfo.mediaType
currentScreenShareSubgroupName
- It replaces
var screenSharingSubgroupName: String?
serviceId
- It replaces
PlanetKitConferencePeerInfo.serviceId
sipDeviceInfo
- It replaces
PlanetKitConferencePeerInfo.sipDeviceInfo
sipLocalIP
- It replaces
PlanetKitConferencePeerInfo.sipLocalIP
subgroupNames
- It replaces
PlanetKitConferencePeerInfo.subgroupNames
user
- It replaces
PlanetKitConferencePeerInfo.user
userEquipmentType
- It replaces
PlanetKitConferencePeerInfo.userEquipmentType
userId
- It replaces
PlanetKitConferencePeerInfo.userId
currentVideoSubgroupName
- It replaces
PlanetKitConferencePeerInfo.videoSubgroupName
PlanetKitConferencePeerInfo.videoTaggedSubgroupName
- Deprecated since 5.0
- It is no longer used because it lacks usefulness.
API changes
Changed
-
PlanetKitConferencePeerInfo
class Group callPrevious PlanetKit 5.5 val serviceId: String
PlanetKitConferencePeer::val serviceId: String
val user: PlanetKitUser
PlanetKitConferencePeer::val user: PlanetKitUser
val userId: String
PlanetKitConferencePeer::val userId: String
var videoSubgroupName: String?
PlanetKitConferencePeer::val currentVideoSubgroupName: String?
val mediaType:PlanetKitMediaType
PlanetKitConferencePeer::val mediaType:PlanetKitMediaType
val subgroupNames: Set<String>
PlanetKitConferencePeer::val subgroupNames:Set<String>
val isDataSessionSupport: Boolean
PlanetKitConferencePeer::val isDataSessionSupported: Boolean
val isAudioMuted:Boolean: Boolean
PlanetKitConferencePeer::val isAudioMuted: Boolean
val isOnHold:Boolean
PlanetKitConferencePeer::val holdStatus: HoldStatus
val displayName:String?
PlanetKitConferencePeer::val displayName:String?
val userEquipmentType: PlanetKitUserEquipmentType
PlanetKitConferencePeer::val userEquipmentType: PlanetKitUserEquipmentType
val sipLocalIP: String?
PlanetKitConferencePeer::val sipLocalIP: String?
val sipDeviceInfo:String?
PlanetKitConferencePeer::val sipDeviceInfo:String?
fun isSameMember(member:PlanetKitConferencePeerInfo): Boolean
PlanetKitConferencePeer::fun isSameMember(member:PlanetKitConferencePeer):Boolean
-
PlanetKitConferencePeer
class Group callPrevious PlanetKit 5.5 val videoStatus: PlanetKitVideoStatus
fun getVideoStatus(subgroupName: String?): VideoStatusResult
val audioVolume: Int?
fun getAudioVolumeLevelSetting(subgroupName: String?): AudioVolumeResult
val screenSharingSubgroupName: String?
val currentScreenShareSubgroupName: String?
val isDataSessionSupport: Boolean
val isDataSessionSupported: Boolean
Added
PlanetKitConferencePeer
class Group callval screenShareSubgroupName:String?
enum class PeerGetFailReason
data class VideoStatusResult
data class ScreenShareStateResult
data class AudioVolumeResult
data class HoldStatus
fun getScreenShareState( subgroupName: String? ): ScreenShareStateResult
fun createPeerControl(): PlanetKitPeerControl?
Removed
PlanetKitConferencePeer
class Group callvar audioSubgroupName: String?
var audioTaggedSubgroupName: String?
PlanetKitConferencePeerInfo
class Group callvar videoTaggedSubgroupName: String?
Code examples
audioVolume
-
This API replaces
getAudioVolumeLevelSetting()
-
Please refer to the sample code.
// In your application
val conferencePeer: PlanetKitConferencePeer = ...
// previous version
val audioVolumeSetting = conferencePeer.audioVolume
// PlanetKit 5.0
val result = conferencePeer.getAudioVolumeLevelSetting("Your subscribed Subgroup Name")
if (result.failReason != PeerGetFailReason.NONE) {
Log.w(TAG, "Could not get volume level setting. reason=${result.failReason}")
}
val audioVolumeSetting = result.volume
getScreenShareState()
-
This API replaces
screenSharingState
-
Please refer to the sample code.
// In your application
val conferencePeer: PlanetKitConferencePeer = ...
// previous version
val screenSharingState = conferencePeer.screenSharingState
// PlanetKit 5.0
val result = conferencePeer.getScreenShareState("Your subscribed Subgroup Name")
if (result.failReason != PeerGetFailReason.NONE) {
Log.w(TAG, "Could not get screenShareState. reason=${result.failReason}")
}
val screenShareState = result.screenShareState
getVideoStatus()
-
This API replaces
videoStatus
-
Please refer to the sample code.
// In your application
val conferencePeer: PlanetKitConferencePeer = ...
// previous version
val videoStatus = conferencePeer.videoStatus
// PlanetKit 5.0
val result = conferencePeer.getVideoStatus("Your subscribed Subgroup Name")
if (result.failReason != PeerGetFailReason.NONE) {
Log.w(TAG, "Could not get videoStatus. reason=${result.failReason}")
}
val videoStatus = result.videoStatus
Breaking change Removed multicast and changed the specification of sendShortData()
- If you send data to only a few peers among all peers, the length of data to be sent is affected by the peer list. This can lead to a difficult problem of managing the length of the data to be sent according to the list configuration.
- Short data can be sent to one peer or to all peers.
- Since PlanetKit 5.2, the size of the type must not exceed 100 bytes and the size of short data must not exceed 800 bytes.
API changes
Removed
PlanetKitConference
class Group callfun sendShortData( targetUsers: List<PlanetKitUser>, type: String, shortData: ByteArray): Boolean
fun sendShortData( targetUsers: List<PlanetKitUser>, type: String, shortData: ByteArray, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
Code examples
// Previous 4.4
sendShortData( userList, type, data ) // multicast
// since 5.5
for( user in userList) {
sendShortData( user, type, data ) // unicast by iteration
}
// or
sendShortData( type, data ) // to All users
Breaking change Remove the room attribute in group calls
- Prior to PlanetKit 5.2, if the room type of a group call did not match while joining a group call, the
WRONG_ROOM_ATTRIBUTE
error occurred. - Starting from PlanetKit 5.2, the room type has been removed and is no longer checked, so the
WRONG_ROOM_ATTRIBUTE
disconnect reason has been deprecated accordingly.
API changes
Removed
PlanetKitConferenceRoomType
enum class Group callPlanetKitConferenceParam
data class Group callval roomType: PlanetKitConferenceRoomType
PlanetKitConferenceParam.Builder
class Group callfun roomType(roomType: PlanetKitConferenceRoomType)
PlanetKitConference
class Group callval roomType: PlanetKitConferenceRoomType
PlanetKitDisconnectReason
class 1-to-1 callGroup callWRONG_ROOM_ATTRIBUTE
Breaking change Remove the reason
parameter from disableVideo()
of PlanetKitConference
- The
reason
parameter in thedisableVideo
method ofPlanetKitConference
has been removed because it serves no purpose. - Unused enum values in
PlanetKitMediaDisableReason
have been removed.
API changes
Removed
PlanetKitMediaDisableReason
enum class 1-to-1 callGroup callNOT_SUPPORT
NO_MEDIA_SRC
NO_RECV_MEDIA
Breaking change Change PlanetKit.getConference
- The conference instance is not a singleton, but since only one session is valid,
getConference()
has been added to obtain the conference instance without an instance ID parameter.
API changes
Changed
-
PlanetKit
class 1-to-1 callGroup callPrevious PlanetKit 5.5 fun getConference(sid:Int): PlanetKitConference?
fun getConference(): PlanetKitConference?
Breaking change Add PlanetKitInitialMyVideoState
PlanetKitInitialMyVideoState
is an enum class added to determine the state of the local user's video when a video call is activated.- The default value for a property or parameter of type
PlanetKitInitialMyVideoState
isPlanetKitInitialMyVideoState.RESUME
. - For more information, refer to Setting the initial video state.
API changes
Changed
-
PlanetKitCall
interface 1-to-1 callPrevious PlanetKit 5.5 fun acceptCall(listener: AcceptCallListener, useResponderPreparation: Boolean = false, recordOnCloud: Boolean = false)
fun acceptCall(listener: AcceptCallListener, initialMyVideoState: PlanetKitInitialMyVideoState = PlanetKitInitialMyVideoState.RESUME, useResponderPreparation: Boolean = false, recordOnCloud: Boolean = false)
fun acceptCall(listener: AcceptCallListener, callStartMessage: PlanetKitCallStartMessage, useResponderPreparation: Boolean = false, recordOnCloud: Boolean = false)
fun acceptCall(listener: AcceptCallListener, callStartMessage: PlanetKitCallStartMessage, initialMyVideoState: PlanetKitInitialMyVideoState = PlanetKitInitialMyVideoState.RESUME, useResponderPreparation: Boolean = false, recordOnCloud: Boolean = false)
fun enableVideo(userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun enableVideo(initialMyVideoState: PlanetKitInitialMyVideoState = PlanetKitInitialMyVideoState.RESUME, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
-
PlanetKitConference
interface Group callPrevious PlanetKit 5.5 fun enableVideo(userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun enableVideo(initialMyVideoState: PlanetKitInitialMyVideoState = PlanetKitInitialMyVideoState.RESUME, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
Added
PlanetKitInitialMyVideoState
enum class 1-to-1 callGroup callRESUME(0)
PAUSE(1)
PlanetKitMakeCallParam.Builder
class 1-to-1 callfun setInitialMyVideoState(value: PlanetKitInitialMyVideoState)
PlanetKitConferenceParam.Builder
class Group callfun setInitialMyVideoState(value: PlanetKitInitialMyVideoState)
Code examples
-
1-to-1 call
fun makeCall() {
/* Make a video call with the local user's video state set to PAUSE */
val param = PlanetKitMakeCallParam.Builder()
.mediaType(PlanetKitMediaType.AUDIOVIDEO)
.setInitialMyVideoState(PlanetKitInitialMyVideoState.PAUSE)
/* Set other parameters If you needed */
.build()
val result = PlanetKit.makeCall(param, makeAcceptCallListener)
}
val verifyListener = object: VerifyListener {
override fun onVerified(call: PlanetKitCall,
peerStartMessage: PlanetKitCallStartMessage?,
peerUseResponderPreparation: Boolean) {
/* For a video call, accept the call with the local user's video state set to PAUSE */
call.acceptCall(acceptCallListener, PlanetKitInitialMyVideoState.PAUSE)
}
}
fun enableVideo() {
/* Change a call type as video call with the local user's video state set to PAUSE */
call.enableVideo(PlanetKitInitialMyVideoState.PAUSE)
} -
Group call
fun joinConference() {
/* Join a video group call with the local user's video state set to PAUSE */
val param = PlanetKitConferenceParam.Builder()
.mediaType(PlanetKitMediaType.AUDIOVIDEO)
.setInitialMyVideoState(PlanetKitInitialMyVideoState.PAUSE)
/* Set other parameters If you needed */
.build()
val result = PlanetKit.joinConference(param, conferenceListener)
}
fun enableVideo() {
/* Change to video group call with the local user's video state set to PAUSE */
conference.enableVideo(PlanetKitInitialMyVideoState.PAUSE)
}
Breaking change Change audio volume polling to events
- Audio information including
averageVolumeLevel
is now provided through audio description events. - You need to change the code using timer getter pattern to event driven pattern.
- You can set whether to enable or disable listening to the events.
- You can set the listening interval. The default value is 500 msec and the minimum interval is 200 msec.
API changes
Changed
-
PlanetKitAudioVolume
class 1-to-1 callGroup callPrevious PlanetKit 5.5 class PlanetKitAudioVolume
class PlanetKitAudioDescription
val averageVolume: Int
val averageVolumeLevel: Int
val subgroupName:String?
val sentSubgroupName:String?
Added
PlanetKitConferenceParam.Builder
class Group callfun enableAudioDescription(enable:Boolean)
fun setAudioDescriptionInterval(intervalMS:Long)
PlanetKitVerifyCallParam.Builder
class 1-to-1 callfun enableAudioDescription(enable:Boolean)
fun setAudioDescriptionInterval(intervalMS:Long)
PlanetKitConferenceParam.Builder
class Group callfun enableAudioDescription(enable:Boolean)
fun setAudioDescriptionInterval(intervalMS:Long)
CallListener
class 1-to-1 callfun onMyAudioDescriptionUpdated(call: PlanetKitCall, audioDescription: PlanetKitAudioDescription)
fun onPeerAudioDescriptionUpdated(call: PlanetKitCall, audioDescription: PlanetKitAudioDescription)
ConferenceListener
class Group callfun onMyAudioDescriptionUpdated(conference: PlanetKitConference, audioDescription: PlanetKitAudioDescription)
fun onPeersAudioDescriptionUpdated(conference: PlanetKitConference, peersAudioDescription:PlanetKitAudioDescriptions)
Removed
PlanetKitSession
class 1-to-1 callGroup callval myVolume: PlanetKitAudioVolume
PlanetKitCall
class 1-to-1 callval peerVolume:PlanetKitAudioVolume?
PlanetKitConference
class Group callval memberVolumes: PlanetKitAudioVolumes?
Code examples
1-to-1 call
val param = PlanetKitVerifyCallParam.Builder()
...
.enableAudioDescription( true )
.setAudioDescriptionInterval( userIntervalDependingOnUX )
.build()
val makeCallListener = object : MakeCallListener {
...
override fun onMyAudioDescriptionUpdated(audioDescription: PlanetKitAudioDescription) {
// reflect update of the local user's audio description
}
override fun onPeerAudioDescriptionUpdated(audioDescription: PlanetKitAudioDescription) {
// reflect update of peer audio description
}
}
PlanetKit.makeCall(param, makeCallListener)
Group call
val param = PlanetKitConferenceParam.Builder()
...
.enableAudioDescription( true )
.setAudioDescriptionInterval( userIntervalDependingOnUX )
.build()
private val conferenceListener = object: ConferenceListener {
...
override fun onMyAudioDescriptionUpdated(audioDescription: PlanetKitAudioDescription) {
// reflect update of the local user's audio description
}
override fun onPeersAudioDescriptionUpdated(peersAudioDescription: PlanetKitAudioDescriptions) {
// reflect peers audio description updated
}
}
PlanetKit.joinConference(param, conferenceListener)
Breaking change Migrate PlanetKitDisconnectReason
- Added more information about disconnecting 1-to-1 calls and group calls.
MAX_CALL_TIME_EXCEEDED
is returned when the allowed call time is exceeded.SERVICE_TOO_MANY_REQUESTS
is returned when the allowed number of calls is exceeded within a short period.- When a system shutdown (power-off) occurs, PlanetKit detects it internally and ends the call with
PlanetKitDisconnectReason.APP_DESTROY
. - Added a disconnect reason for call failure due to exceeding the maximum transmission unit (MTU).
- Added a disconnect reason for the case when the Planet Cloud server fails to deliver app server data to the app server.
- Related APIs have been changed.
API changes
Removed
PlanetKitDisconnectReason
enum 1-to-1 callGroup callLOCAL_MIC_NO_SRC
REMOTE_MIC_NO_SRC
LOCAL_INTERNAL_ERROR
REMOTE_INTERNAL_ERROR
LOCAL_USER_ERROR
REMOTE_USER_ERROR
LOCAL_INTERNAL_KIT_ERROR
REMOTE_INTERNAL_KIT_ERROR
BAD_NETWORK_IN_CONFERENCE
UNAVAILABLE_NETWORK_IN_CALL
SERVICE_APIKEY_ERROR
Added
PlanetKitDisconnectReason
enum 1-to-1 callGroup callINTERNAL_ERROR
USER_ERROR
INTERNAL_KIT_ERROR
AUDIO_TX_NO_SRC
UNAVAILABLE_NETWORK
APP_DESTROY
SYSTEM_SLEEP
SYSTEM_LOGOFF
SERVICE_ACCESS_TOKEN_ERROR
MTU_EXCEEDED
APP_SERVER_DATA_ERROR
MAX_CALL_TIME_EXCEEDED
SERVICE_TOO_MANY_REQUESTS
DESKTOP_SCREEN_LOCKED
PlanetKitDisconnectSource
enum 1-to-1 callGroup callUNDEFINED
CALLEE
CALLER
PARTICIPANT
CLOUD_SERVER
APP_SERVER
PlanetKitDisconnectedParam
data class 1-to-1 callGroup callval reason: PlanetKitDisconnectReason
val source: PlanetKitDisconnectSource
val byRemote: Boolean
val userCode: String?
Changed
-
ConferenceListener
interface Group callPrevious PlanetKit 5.5 fun onLeft(conference: PlanetKitConference, reason: PlanetKitDisconnectReason, userRelCode: String?)
fun onDisconnected(conference: PlanetKitConference, param: PlanetKitDisconnectedParam)
-
CallListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onDisconnected(call: PlanetKitCall, reason: PlanetKitDisconnectReason, userCode: String?)
fun onDisconnected(call: PlanetKitCall, param: PlanetKitDisconnectedParam)
-
AcceptCallListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onDisconnected( call:PlanetKitCall, reason:PlanetKitDisconnectReason, userCode:String )
fun onDisconnected( call:PlanetKitCall, param:PlanetKitDisconnectedParam )
-
MakeCallListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onDisconnected( call:PlanetKitCall, reason:PlanetKitDisconnectReason, userCode:String )
fun onDisconnected( call:PlanetKitCall, param:PlanetKitDisconnectedParam )
-
VerifyListener
interface 1-to-1 callPrevious PlanetKit 5.5 override fun onDisconnected(call: PlanetKitCall, reason: PlanetKitDisconnectReason, userCode: String?)
fun onDisconnected(call: PlanetKitCall, param: PlanetKitDisconnectedParam)
Breaking change Apply changes regarding mirror mode of camera
- In previous versions, the mirror mode could be set in the camera module. This has been removed to prevent misunderstandings that the original camera image would be altered.
- As a replacement, this functionality has been incorporated into the video views of PlanetKit.
API changes
Changed
-
DefaultCameraVideoSource
class 1-to-1 callGroup callPrevious PlanetKit 5.5 class DefaultCameraVideoSource
class PlanetKitCameraManager
Added
PlanetKitVideoView
class 1-to-1 callGroup callvar mirroredType: PlanetKitMirroredType
PlanetKitPeerView
class Group callvar mirroredType: PlanetKitMirroredType
PlanetKitPeerScreenShareView
class Group callvar mirroredType: PlanetKitMirroredType
PlanetKitMyView
class 1-to-1 callGroup callvar mirroredType: PlanetKitMirroredType
PlanetKitMirroredType
enum class 1-to-1 callGroup call
Removed
DefaultCameraVideoSource
class 1-to-1 callGroup callvar mirrorMode: Boolean
Code examples
-
Integration with video views based on your app settings is required.
-
The following example demonstrates the usage of a ViewModel.
-
Step 1: Update LiveData in your ViewModel based on your application settings.
// ViewModel
...
private val _myVideoMirroredType: MutableLiveData<PlanetKitMirroredType>
= MutableLiveData(yourSettingsValue)
val myVideoMirroredType: LiveData<PlanetKitMirroredType>
get() = _myVideoMirroredType
fun setMyVideoMirroredType(mirroredType: PlanetKitMirroredType) {
_myVideoMirroredType.value = mirroredType
yourSettingsValue = mirroredType
} -
Step 2: Change the mirror mode of the video views according to the LiveData.
// Fragment
...
observeNotNull(viewModel.myVideoMirroredType) {
binding.myDemoView?.mirroredType = it
}
Breaking change Replace VideoSource
with PlanetKitCustomVideoSource
for custom video source
- The existing
VideoSource
made it difficult for users to customize and integrate the custom video source into 1-to-1 call or group call sessions as necessary. To address this issue, we have introducedPlanetKitCustomVideoSource
, which can be used for customization.
API changes
Changed
-
PlanetKitCall
interface 1-to-1 callPrevious PlanetKit 5.5 fun setVideoSource(videoSource: VideoSource?)
fun setVideoSource(videoSource: PlanetKitCustomVideoSource)
,fun clearVideoSource()
-
PlanetKitConference
interface Group callPrevious PlanetKit 5.5 fun setVideoSource(videoSource: VideoSource?)
fun setVideoSource(videoSource: PlanetKitCustomVideoSource)
,fun clearVideoSource()
Added
PlanetKitCustomVideoSource
abstract class 1-to-1 callGroup callvar maxFps: Int? = null
fun addMyVideoView(view: PlanetKitVideoView)
fun removeMyVideoView(view: PlanetKitVideoView)
protected fun postFrameData(frameData: FrameData): Boolean
protected fun postingFrameDataAvailable(): Boolean
abstract fun onMaxFpsLimitUpdated(isLimitEnabled: Boolean, maxFps: Int)
PlanetKitCustomVideoSource.FrameData
abstract class 1-to-1 callGroup call
Breaking change Improve ScreenCapturerVideoSource
ScreenCapturerVideoSource
previously exposed several unnecessary methods, causing confusion for users. It has been improved to expose only the essential methods.- Since the
ScreenCapturerVideoSource
no longer inherits fromVideoSource
, the methods previously provided byVideoSource
have been removed.
API changes
Removed
ScreenCapturerVideoSource
class 1-to-1 callGroup callfun stop(reason: VideoSource.VideoSourceStopReason): Boolean
fun useDeviceRotation(): Boolean
Breaking change Change interface of SendDataSessionListener
and ReceiveDataSessionListener
- Renamed
SendDataSessionListener
toOutboundDataSessionListener
. - Renamed
ReceiveDataSessionListener
toInboundDataSessionListener
. - Refined the failure information for the data session.
- The
onClosed
event has been added to bothOutboundDataSessionListener
andInboundDataSessionListener
to notify when a data session is closed. - Related APIs have been changed.
API changes
Changed
-
SendDataSessionListener
interface 1-to-1 callGroup callPrevious PlanetKit 5.5 class SendDataSessionListener
class OutboundDataSessionListener
fun onError( exception:PlanetKitException )
fun onError( errReason:PlanetKitDataSessionFailReason )
-
ReceiveDataSessionListener
interface 1-to-1 callGroup callPrevious PlanetKit 5.5 interface ReceiveDataSessionListener
interface InboundDataSessionListener
fun onError( exception:PlanetKitException )
fun onError( errReason:PlanetKitDataSessionFailReason )
Added
PlanetKitDataSessionFailReason
enum 1-to-1 callGroup callNONE
INTERNAL
NOT_INCOMING
ALREADY_EXIST
INVALID_ID
INVALID_TYPE
PlanetKitDataSessionClosedReason
enum class 1-to-1 callGroup callOutboundDataSessionListener
interface 1-to-1 callGroup callvoid onClosed(@NonNull PlanetKitOutboundDataSession dataSession, @NonNull PlanetKitDataSessionClosedReason closedReason)
InboundDataSessionListener
interface 1-to-1 callGroup callvoid onClosed(@NonNull PlanetKitInboundDataSession dataSession, @NonNull PlanetKitDataSessionClosedReason closedReason)
Removed
SendDataSessionListener
interface 1-to-1 callGroup callvoid onUnsupportedDataSession(@NonNull PlanetKitSendDataSession dataSession)
PlanetKitError
enum 1-to-1 callGroup callSESSION_FAIL_REASON_ALREADY_EXIST
SESSION_FAIL_REASON_INVALID_SESSION_TYPE
SESSION_FAIL_REASON_FAILED_TO_MAKE_DATA_SESSION
Code examples
-
The newly added
onClosed
can be implemented as follows. -
The
onClosed
event with the reasonSESSION_END
occurs when a call or conference ends, or when the user unsubscribes from a subgroup.class ExampleOutboundDataSessionListener : OutboundDataSessionListener {
override fun onClosed(dataSession: PlanetKitOutboundDataSession, closedReason: PlanetKitDataSessionClosedReason) {
when (closedReason) {
PlanetKitDataSessionClosedReason.SESSION_END -> println("Session has ended.")
PlanetKitDataSessionClosedReason.INTERNAL -> println("An unexpected internal error occurred.")
PlanetKitDataSessionClosedReason.UNSUPPORTED -> println("Data session ID is unsupported by the peer.")
}
}
// Implement other interface methods as needed
}
class ExampleInboundDataSessionListener : InboundDataSessionListener {
override fun onClosed(dataSession: PlanetKitInboundDataSession, closedReason: PlanetKitDataSessionClosedReason) {
when (closedReason) {
PlanetKitDataSessionClosedReason.SESSION_END -> println("Session has ended.")
PlanetKitDataSessionClosedReason.INTERNAL -> println("An unexpected internal error occurred.")
PlanetKitDataSessionClosedReason.UNSUPPORTED -> println("Data session ID is unsupported by the peer.")
}
}
// Implement other interface methods as needed
}
Breaking change Rename stid
to appServerData
- It has been changed to a clearer name,
appServerData
, that matches the behavior ofstid
. - The size limit of app server data has been changed from 256 bytes to 4096 bytes.
- Related APIs have been changed.
API changes
Changed
-
PlanetKitCallParam
class 1-to-1 callPrevious PlanetKit 5.5 val stid: String
val appServerData: String
-
PlanetKitCallParam.Builder
class 1-to-1 callPrevious PlanetKit 5.5 fun stid(stid: String)
fun appServerData(appServerData: String)
-
PlanetKitConferenceParam
class 1-to-1 callPrevious PlanetKit 5.5 val stid: String
val appServerData: String
-
PlanetKitConferenceParam.Builder
class Group callPrevious PlanetKit 5.5 fun stid(stid: String)
fun appServerData(appServerData: String)
Breaking change Remove unnecessary APIs
isHighPriorityAudio
andsetAudioHighPrioritySend
have been removed.- Related APIs have been removed.
API changes
Removed
PlanetKitConference
class Group callval isHighPriorityAudio: Boolean
fun setAudioHighPrioritySend( isHighPriority: Boolean, userData: Any? = null, callback: PlanetKitRequestCallback? = null ): Boolean
Breaking change Remove PlanetKitIntent
PlanetKitIntent
was implemented depending on thelocalBroadCast
library, but the library is deprecated. Applications can implement the same function by using implementations ofCallListener
andConferenceListener
. The demo app was developed by applying another open source (org.greenrobot.eventbus
) to implement the same function.
API changes
Removed
PlanetKitIntent
class 1-to-1 call
Code examples
1-to-1 call: Migration with EventBus
-
Add the external library dependency into your app's
build.gradle
implementation 'org.greenrobot:eventbus:3.3.1'
-
Create your own message class as below
class PlanetDemoMessageEventDisconnected internal constructor(
session: PlanetKitSession,
val reason: PlanetKitDisconnectReason,
val userCode: String?
): PlanetDemoMessageEvent(session, Type.DISCONNECTED) -
Send event messages
private val verifyCallListener = object : VerifyCallListener {
override fun onDisconnected(call: PlanetKitCall, reason: PlanetKitDisconnectReason, userCode: String?) {
...
EventBus.getDefault().post(PlanetDemoMessageEventDisconnected(call, reason, userCode))
}
} -
Receive events on other modules (such as
NotificationService
)// 1. Prepare PlanetKitMessageEvent Receiver
@Subscribe(threadMode = ThreadMode.MAIN_ORDERED)
fun onMessageEvent(event: PlanetDemoMessageEvent) {
if(event is PlanetDemoMessageEventDisconnected)
{
onClearRequested()
}
}
// 2. Register PlanetKitMessageEvent
override fun onCreate() {
super.onCreate()
EventBus.getDefault().register(this)
}
// 3. Unregister PlanetKitMessageEvent
override fun onDestroy() {
EventBus.getDefault().unregister(this);
super.onDestroy()
}
Spec change Change the range of data session stream ID
- The previous specification for range of data session stream ID was from 100 to 1000, but the upper limit has been changed to 999.
Spec change Add limitation to the display name
- The
myDisplayName
property inPlanetKitConferenceParam
is now limited to 128 bytes, including null termination. - Any trailing part of the string that exceeds the maximum size is discarded.
Enhancement Add PlanetKitPeerView
Refer to the related code example.
Enhancement Add PlanetKitPeerControl
Refer to the related release notes.
Enhancement Add PlanetKitMyView
Refer to the related code example.
Enhancement Add PlanetKitMyMediaStatus
Refer to the related release notes.
Enhancement Add PlanetKitPeerScreenShareView
Refer to the related code example.
Enhancement Improve addPeerVideoView()
/removePeerVideoView()
- The video view you add to the peer should not be shared with other peers. When adding a video view to a new peer, if it has been added to another peer, it is removed from the previous peer and added to the new peer. Additionally, an overloaded function without a peer parameter has been added to
removePeerVideoView
.
API changes
Improve addPeerVideoView()
- The view is added only for the last peer. It is automatically removed from the previous peer.
Added removePeerVideoView(view:PlanetKitVideoView)
- A view can be removed regardless of which peer it was added to.
Code examples
Old style to change a peer for the same video view instance
addPeerVideoView(peerA, videoView)
... // another task
removePeerVideoView(peerA, videoView) // You must remember which peer the view was added to
... // another task
addPeerVideoView(peerB, videoView)
New Style with removePeerVideoView(view:PlanetKitVideoView)
addPeerVideoView(peerA, videoView)
... //another task
removePeerVideoView(videoView) // There's no more need to remember the peer
... //another task
addPeerVideoView(peerB, videoView)
New style for changing peer
addPeerVideoView(peerA, videoView)
... //another task
addPeerVideoView(peerB, videoView) // It can be used without removePeerVideoView
API changes
Changed
-
PlanetKitConference
class Group callPrevious PlanetKit 5.5 fun removePeerVideoView(peer: PlanetKitUser, view: PlanetKitVideoView)
fun removePeerVideoView(view: PlanetKitVideoView)
Enhancement Add isPeerAudioMuted
- Peer's audio mute state getter has been added for 1-to-1 calls.
API changes
Added
PlanetKitCall
class 1-to-1 callval isPeerAudioMuted:Boolean
Code examples
... // somewhere you need to check the peer's mute state
if( call.isPeerAudioMuted )
{
// peer is muted
}
else
{
// peer is not muted
}
Enhancement Add an event about the end of screen share by hold
- If you hold a call during screen share, LINE Planet stops sending screen share. This is an event for this situation.
- When you receive this event, you should update your UI indicator if needed.
API changes
Added
CallListener
class 1-to-1 callfun onMyScreenShareStoppedByHold(call: PlanetKitCall)
ConferenceListener
class Group callfun onMyScreenShareStoppedByHold(conference: PlanetKitConference)
Enhancement Add API to optimize the performance of video frame processing
- Your application might generate more video frames than are actually transmitted. Because these extra frames are processed even though the frames are skipped, they result in processing overhead. If you implement your own
VideoSource
, take advantage of the added API to optimize performance.
API changes
Added
VideoSource
abstract class 1-to-1 callGroup callprotected fun postingFrameDataAvailable(nanoSecondsTimestamp: Long): Boolean
protected val isMaxFpsLimitEnabled: Boolean
protected val maxFpsLimit: Int
protected abstract fun onMaxFpsLimitUpdated(isLimitEnabled: Boolean, maxFps: Int)
Code examples
-
Case 1: Skip processing frames according to
postingFrameDataAvailable()
fun yourFrameCallbackHandler( yourFrame, ... )
{
// when the frame has timestamp
val curTimestamp = yourFrame.timestamp // to nanoseconds
// when the data doesn't have timestamp
val curTimestamp = this.sourceTimestamp // property from VideoSource base class
if ( this.postingFrameDataAvailable( curTimestamp ) )
{
val frameData = YourConcreteFrameData( yourFrame, curTimestamp, ... ) // interface from VideoSource.FrameData base class
this.postFrameData( frameData )
// handle clean-up
...
}
else
{
// handle clean-up
...
}
} -
Case 2: Use the maximum FPS to update frame duration if you implement a custom frame tick generator
override fun onMaxFpsLimitUpdated( isLimitEnabled: Boolean, maxFps: Int )
{
if ( isLimitEnabled )
{
// update tick duration according to maxFps
this.fps = maxFps
frameDuration = (1000 / maxFps ).toLong()
yourFrameTick.updateInterval( frameDuration )
}
else
{
// You may want to set it back to normal FPS
this.fps = defaultFps
yourFrameTick.updateInterval( defaultDuration )
// or you could stop frame
yourFrameTick.stop()
}
}
Enhancement Apply automatic obfuscation
- From PlanetKit 5.2, you don't need to make any changes to the
proguard.rules
file of your Android application in order to use PlanetKit. - You can remove all PlanetKit-related rules from
proguard.rules
if you specified them in a previous version to avoid runtime issues.
Enhancement Provide API for video sharing mode in screen share
- Video sharing mode optimizes screen share for video clip sharing.
- Video sharing mode can be enabled before you start screen share, or during screen share.
- When video sharing mode is enabled, resource usage may increase.
API changes
Changed
-
ConferenceListener
class Group callPrevious PlanetKit 5.5 fun onJoined(conference: PlanetKitConference)
fun onConnected(conference: PlanetKitConference, isVideoHwCodecEnabled: Boolean, isVideoShareModeSupported: Boolean)
Added
PlanetKitCall
class 1-to-1 callfun setMyScreenShareVideoShareMode(videoShareMode: Boolean): Boolean
fun isMyScreenShareVideoShareModeEnabled(): Boolean
PlanetKitCallConnectedParam
data class 1-to-1 callval isVideoShareModeSupported: Boolean
PlanetKitConference
class Group callfun setMyScreenShareVideoShareMode(videoShareMode: Boolean): Boolean
fun isMyScreenShareVideoShareModeEnabled(): Boolean
Enhancement Support recording on the cloud
- Added a feature to record 1-to-1 calls on the cloud.
- To enable this feature, contact the LINE Planet team first.
- For more information, refer to Cloud call recording.
API changes
Changed
-
PlanetKitCall
class 1-to-1 callPrevious PlanetKit 5.5 fun acceptCall(mediaType:PlanetKitMediaType, listener:AcceptCallListener)
fun acceptCall(listener: AcceptCallListener, initialMyVideoState: PlanetKitInitialMyVideoState = PlanetKitInitialMyVideoState.RESUME, useResponderPreparation: Boolean = false, recordOnCloud: Boolean = false)
fun acceptCall(mediaType:PlanetKitMediaType, listener:AcceptCallListener, callInitData:PlanetKitCallInitData = PlanetKitCallInitData())
fun acceptCall(listener: AcceptCallListener, callStartMessage: PlanetKitCallStartMessage, initialMyVideoState: PlanetKitInitialMyVideoState = PlanetKitInitialMyVideoState.RESUME, useResponderPreparation: Boolean = false, recordOnCloud: Boolean = false)
Added
PlanetKitRecordOnCloudDeactivateReason
enum class 1-to-1 callCallListener
class 1-to-1 callfun onRecordOnCloudUpdated(call: PlanetKitCall, activated: Boolean, reason: PlanetKitRecordOnCloudDeactivateReason)
PlanetKitCall
class 1-to-1 callfun isRecordOnCloudActivated(): Boolean
PlanetKitMakeCallParam
data class 1-to-1 callval recordOnCloud: Boolean
PlanetKitMakeCallParam.Builder
class 1-to-1 callfun enableRecordOnCloud(value: Boolean)
Enhancement Add a callback to receive real-time updates on available audio routes
- This API allows you to update the application UI in real time when the connection status of the audio devices changes.
API changes
Added
PlanetKitConference
interface Group callfun setOnAudioRouteAvailableListChangeListener(listener: OnAudioRouteAvailableListChangeListener?)
PlanetKitCall
interface 1-to-1 callfun setOnAudioRouteAvailableListChangeListener(listener: OnAudioRouteAvailableListChangeListener?)
OnAudioRouteAvailableListChangeListener
interface 1-to-1 callGroup call
Code examples
fun joinConference(param: PlanetKitConferenceParam) {
val result = PlanetKit.joinConference(param, conferenceListener)
...
val conference = result.conference
...
conference?.setOnAudioRouteChangeListener { audioRoute ->
...
}
conference?.setOnAudioRouteAvailableListChangeListener { availableList ->
// Update UI status if needed
}
}
Enhancement Add a configuration for playing the end tone regardless of the call state
- To ensure compatibility with versions prior to PlanetKit 5.4, a configuration has been added to play the end tone regardless of the call state.
API changes
Added
PlanetKitMakeCallParam
class 1-to-1 callval playEndToneRegardlessOfCallState: Boolean
PlanetKitMakeCallParam.Builder
class 1-to-1 callfun enablePlayEndToneRegardlessOfCallState(value: Boolean)
PlanetKitVerifyCallParam
class 1-to-1 callval playEndToneRegardlessOfCallState: Boolean
PlanetKitVerifyCallParam.Builder
class Group callfun enablePlayEndToneRegardlessOfCallState(value: Boolean)
PlanetKitConferenceParam
class Group callval playEndToneRegardlessOfConferenceState: Boolean
PlanetKitConferenceParam.Builder
class Group callfun enablePlayEndToneRegardlessOfConferenceState(value: Boolean)
API change list
Changed
-
DefaultCameraVideoSource
class 1-to-1 callGroup callPrevious PlanetKit 5.5 class DefaultCameraVideoSource
class PlanetKitCameraManager
-
PlanetKitVerifyCallParam
class 1-to-1 callPrevious PlanetKit 5.5 val messageData: String
val cCParam: PlanetKitCCParam
val myVideoSendCapability: PlanetKitVideoCapability?
val myVideoSendCapability: PlanetKitVideoCapability
val myVideoReceiveCapability: PlanetKitVideoCapability?
val myVideoReceiveCapability: PlanetKitVideoCapability
-
PlanetKitMakeCallParam
class 1-to-1 callPrevious PlanetKit 5.5 val myVideoSendCapability: PlanetKitVideoCapability?
val myVideoSendCapability: PlanetKitVideoCapability
val myVideoReceiveCapability: PlanetKitVideoCapability?
val myVideoReceiveCapability: PlanetKitVideoCapability
-
PlanetKit
class 1-to-1 callGroup callPrevious PlanetKit 5.5 fun getConference(sid:Int): PlanetKitConference?
fun getConference(): PlanetKitConference?
val userAgent: String
OnInitializeCompleteListener.onComplete(isSuccessful, isVideoHwCodecSupport, userAgent)
val isVideoHwCodecSupport: Boolean
OnInitializeCompleteListener.onComplete(isSuccessful, isVideoHwCodecSupport, userAgent)
fun initialize(config: PlanetKitConfiguration)
fun initialize(config: PlanetKitConfiguration, listener: OnInitializeCompleteListener)
fun makeCall(param: PlanetKitCallParam, makeCallListener: MakeCallListener): PlanetKitCallResult
fun makeCall(param: PlanetKitMakeCallParam, makeCallListener: MakeCallListener): PlanetKitCallResult
fun getDefaultCameraVideoSource(): DefaultCameraVideoSource
fun getCameraManager(): PlanetKitCameraManager
-
PlanetKitLogLevel
enum class 1-to-1 callGroup callPrevious PlanetKit 5.5 VERBOSE
DETAILED
DEBUG
DETAILED
INFO
SIMPLE
WARN
SIMPLE
ERROR
SIMPLE
CRITICAL
SIMPLE
NONE
SILENT
-
PlanetKitVideoPauseReason
enum class 1-to-1 callGroup callPrevious PlanetKit 5.5 UNKNOWN
UNDEFINED
-
AudioSink
abstract class 1-to-1 callGroup callPrevious PlanetKit 5.5 protected fun receiveSpeakerData(sampleRate: Int, format: PlanetKitAudioSampleFormat, sampleCount: Int): AudioFrame
protected fun getFrameData(sampleRate: Int, format: PlanetKitAudioSampleFormat, sampleCount: Int): AudioFrame
protected fun putAECReferenceData(data: AudioFrame): Boolean
protected fun putUserAcousticEchoCancellerReference(data: AudioFrame): Boolean
-
PlanetKitCall
class 1-to-1 callPrevious PlanetKit 5.5 fun acceptCall(mediaType:PlanetKitMediaType, listener:AcceptCallListener)
fun acceptCall(listener: AcceptCallListener, initialMyVideoState: PlanetKitInitialMyVideoState = PlanetKitInitialMyVideoState.RESUME, useResponderPreparation: Boolean = false, recordOnCloud: Boolean = false)
fun acceptCall(mediaType:PlanetKitMediaType, listener:AcceptCallListener, callInitData:PlanetKitCallInitData = PlanetKitCallInitData())
fun acceptCall(listener: AcceptCallListener, callStartMessage: PlanetKitCallStartMessage, initialMyVideoState: PlanetKitInitialMyVideoState = PlanetKitInitialMyVideoState.RESUME, useResponderPreparation: Boolean = false, recordOnCloud: Boolean = false)
fun hold(pauseRecv:Boolean, reason:String? = null, callback:PlanetKitRequestCallback? = null): Boolean
fun hold(reason: String? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun hold(pauseRecv:Boolean, callback: PlanetKitRequestCallback? = null): Boolean
fun hold(reason:String? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun hold(pauseRecv:Boolean, reason:String? = null): Boolean
fun hold(reason:String? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun hold(pauseRecv:Boolean): Boolean
fun hold(reason:String? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun unhold(): Boolean
fun unhold(userData:Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
val isDataSessionSupported: Boolean
CallListener.onConnected
ConferenceListener.onConnected
fun endCallWithNormalUserCode(userCode: String)
fun endCall(userReleasePhrase: String)
fun endCallWithErrorUserCode(userCode: String)
fun endCallWithError(userReleasePhrase: String)
fun unHold(userData:Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun unhold(userData:Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun enableVideo(userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun enableVideo(initialMyVideoState: PlanetKitInitialMyVideoState = PlanetKitInitialMyVideoState.RESUME, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun setVideoSource(videoSource: VideoSource?)
fun setVideoSource(videoSource: PlanetKitCustomVideoSource)
,fun clearVideoSource()
-
PlanetKitConferencePubSubgroupUpdateParam
data class Group callPrevious PlanetKit 5.5 data class UpdatePeerData
data class PlanetKitConferenceSubgroupUpdatedPeer
data class PlanetKitConferencePubSubgroupUpdateParam
data class PlanetKitConferencePublicSubgroupUpdateParam
-
PlanetKitSubgroup
class Group callPrevious PlanetKit 5.5 fun getPeerVolume(user:PlanetKitUser):Int
fun getPeerVolumeLevelSetting(user: PlanetKitUser): Int
val peerUpdateType: PlanetKitSubgroupPeerUpdateType?
val attribute: PlanetKitSubgroupAttribute?
val totalPeerCnt: Int?
val totalPeersCount: Int?
val isEnableVideoUpdate: Boolean?
val attribute: PlanetKitSubgroupAttribute?
val isUsingDataSession: Boolean?
val attribute: PlanetKitSubgroupAttribute?
fun unsupportedReceiveDataSession(streamId: Int): Boolean?
fun unsupportInboundDataSession(streamId: Int): Boolean?
fun makeSendDataSession(@IntRange(from = 100, to = 1000) streamId: Int, type: PlanetKitDataSessionType, listener: SendDataSessionListener)
fun makeOutboundDataSession(@IntRange(from = 100, to = 1000) streamId: Int, type: PlanetKitDataSessionType, listener: OutboundDataSessionListener)
fun makeReceiveDataSession(@IntRange(from = 100, to = 1000) streamId: Int, listener: ReceiveDataSessionListener)
fun makeInboundDataSession(@IntRange(from = 100, to = 1000) streamId: Int, listener: InboundDataSessionListener)
fun getSendDataSession(streamId: Int): PlanetKitSendDataSession?
fun getOutboundDataSession(streamId: Int): PlanetKitOutboundDataSession?
fun getReceiveDataSession(streamId: Int): PlanetKitReceiveDataSession?
fun getInboundDataSession(streamId: Int): PlanetKitInboundDataSession?
val isAutoVolumeFocused: Boolean?
val isPeersAudioAutoVolumeControlFocused: Boolean?
-
PlanetKitSubgroupManager
class Group callPrevious PlanetKit 5.5 boolean setPeerVolume(@NonNull PlanetKitUser peer, @Nullable String subgroupName, @IntRange(from = 0, to = 110) int talkerVolume, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback)
boolean setPeerVolumeLevelSetting(@NonNull PlanetKitUser peer, @Nullable String subgroupName, @IntRange(from = 0, to = 110) int talkerVolume, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback)
boolean setPeerVolume(@NonNull PlanetKitUser peer, int talkerVolume, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback)
boolean setPeerVolumeLevelSetting(@NonNull PlanetKitUser peer, int talkerVolume, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback)
boolean changeSendAudio(@Nullable String subgroupName, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback);
boolean changeMyAudioDestination(@NotNull String subgroupName, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback)
boolean changeMyAudioDestinationToMainRoom(@Nullable Object userData, @Nullable PlanetKitRequestCallback callback)
boolean changeSendVideo(@Nullable String subgroupName, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback);
boolean changeMyVideoDestination(@NotNull String subgroupName, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback)
boolean changeMyVideoDestinationToMainRoom(@Nullable Object userData, @Nullable PlanetKitRequestCallback callback)
boolean tagMainRoomAudioSend(@Nullable String subgroupName, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback);
boolean setTagMyAudioOfMainRoom(@NonNull String subgroupName, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback);
boolean clearTagMyAudioOfMainRoom(@Nullable Object userData, @Nullable PlanetKitRequestCallback callback)
boolean silenceAudio(@Nullable String subgroupName, boolean silence, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback);
PlanetKitSubgroup::fun silencePeersAudio(silence: Boolean, userData: Any?, callback: PlanetKitRequestCallback?): Boolean
boolean disableAutoVolumeControl(@Nullable Object userData, @Nullable PlanetKitRequestCallback callback);
boolean clearPeersAudioAutoVolumeControl(@Nullable Object userData, @Nullable PlanetKitRequestCallback callback)
boolean enableAutoVolumeControl(@NonNull List<String> focusSubgroup, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback);
boolean setPeersAudioAutoVolumeControl(@NonNull List<String> focusSubgroup, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback)
-
PlanetKitReceiveDataSession
class 1-to-1 callGroup callPrevious PlanetKit 5.5 class PlanetKitReceiveDataSession
class PlanetKitInboundDataSession
-
PlanetKitSendDataSession
class 1-to-1 callGroup callPrevious PlanetKit 5.5 class PlanetKitSendDataSession
class PlanetKitOutboundDataSession
-
PlanetKitPeerView.PeerViewListener
class Group callPrevious PlanetKit 5.5 fun onMicUnMuted(peer: PlanetKitConferencePeer)
fun onMicUnmuted(peer: PlanetKitConferencePeer)
fun onHold(peer: PlanetKitConferencePeer, reason: String)
fun onHold(peer: PlanetKitConferencePeer, reason: String?)
fun onUnHold(peer: PlanetKitConferencePeer)
fun onUnhold(peer: PlanetKitConferencePeer)
-
ReceiveDataSessionListener
interface 1-to-1 callGroup callPrevious PlanetKit 5.5 interface ReceiveDataSessionListener
interface InboundDataSessionListener
fun onError( exception:PlanetKitException )
fun onError( errReason:PlanetKitDataSessionFailReason )
-
PlanetKitConferencePeer
class Group callPrevious PlanetKit 5.5 val videoStatus: PlanetKitVideoStatus
fun getVideoStatus(subgroupName: String?): VideoStatusResult
val audioVolume: Int?
fun getAudioVolumeLevelSetting(subgroupName: String?): AudioVolumeResult
val screenSharingSubgroupName: String?
val currentScreenShareSubgroupName: String?
val isDataSessionSupport: Boolean
val isDataSessionSupported: Boolean
-
ConferenceListener
interface Group callPrevious PlanetKit 5.5 fun onLeft(conference: PlanetKitConference, reason: PlanetKitDisconnectReason, userRelCode: String?)
fun onDisconnected(conference: PlanetKitConference, param: PlanetKitDisconnectedParam)
fun onPeersHeld(conference:PlanetKitConference, peerHoldReceivedList: List<PlanetKitConferencePeerHoldReceivedParam>
fun onPeersOnHold(conference: PlanetKitConference, peerHoldReceivedList: List<PlanetKitConferencePeerHoldReceivedParam>)
fun onPeersMicMuted(conference: PlanetKitConference, peers: List<PlanetKitConferencePeerInfo>)
fun onPeersMicMuted(conference: PlanetKitConference, peers: List<PlanetKitConferencePeer>)
fun onPeersMicUnMuted(conference: PlanetKitConference, peers: List<PlanetKitConferencePeerInfo>)
fun onPeersMicUnmuted(conference: PlanetKitConference, peers: List<PlanetKitConferencePeer>)
fun onPeerMyMuteRequested(conference: PlanetKitConference, peer: PlanetKitConferencePeerInfo, isMute:Boolean)
fun onMuteMyAudioRequestedByPeer(conference: PlanetKitConference, peer: PlanetKitConferencePeer, isMute: Boolean)
fun onScreenShareUpdated(peer: PlanetKitConferencePeerInfo, subgroupName: String?, screenSharingState: PlanetKitScreenSharingState)
fun onScreenShareUpdated( peer: PlanetKitConferencePeer, subgroupName: String?, screenShareState: PlanetKitScreenShareState )
fun onPeersSharedContentsUnset(conference: PlanetKitConference, peers:List<PlanetKitConferencePeerInfo>)
fun onPeersSharedContentsUnset(conference: PlanetKitConference, peers: List<PlanetKitConferencePeer>)
fun onPeerExclusivelySharedContentsSet(conference: PlanetKitConference, peer: PlanetKitConferencePeerInfo, data: ByteArray, elapsedTimeAfterSetMs: Long)
fun onPeerExclusivelySharedContentsSet(conference: PlanetKitConference, peer: PlanetKitConferencePeer, data: ByteArray, elapsedTimeAfterSetMs: Long)
fun onPeerExclusivelySharedContentsUnset(<br> conference:PlanetKitConference,<br> peer:PlanetKitConferencePeerInfo<br>)
fun onPeerExclusivelySharedContentsUnset(conference: PlanetKitConference, peer: PlanetKitConferencePeer)
fun onJoined(conference: PlanetKitConference)
fun onConnected(conference: PlanetKitConference, isVideoHwCodecEnabled: Boolean, isVideoShareModeSupported: Boolean)
fun onSubgroupUpdated(param: PlanetKitConferencePubSubgroupUpdateParam)
fun onSubgroupUpdated(param: PlanetKitConferencePublicSubgroupUpdateParam)
fun onPeersUnHold(conference: PlanetKitConference, peers: List<PlanetKitConferencePeer>)
fun onPeersUnhold(conference: PlanetKitConference, peers: List<PlanetKitConferencePeer>)
fun onBadNetworkDetected(conference: PlanetKitConference, disconnectAfterSec: Int)
fun onNetworkUnavailable(conference: PlanetKitConference, disconnectAfterSec: Int)
fun onBadNetworkResolved(conference: PlanetKitConference)
fun onNetworkReavailable(conference: PlanetKitConference)
-
VerifyListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onVerified(call: PlanetKitCall, callerInitData: PlanetKitCallInitData)
fun onVerified(call: PlanetKitCall, peerStartMessage: PlanetKitCallStartMessage?, peerUseResponderPreparation: Boolean)
override fun onDisconnected(call: PlanetKitCall, reason: PlanetKitDisconnectReason, userCode: String?)
fun onDisconnected(call: PlanetKitCall, param: PlanetKitDisconnectedParam)
-
MakeCallListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onConnected( call:PlanetKitCall, calleeInitData: PlanetKitCallInitData )
fun onConnected( call: PlanetKitCall, param: PlanetKitCallConnectedParam )
fun onDisconnected( call:PlanetKitCall, reason:PlanetKitDisconnectReason, userCode:String )
fun onDisconnected( call:PlanetKitCall, param:PlanetKitDisconnectedParam )
-
AcceptCallListener
interface 1-to-1 callPrevious PlanetKit 5.5 fun onConnected( call:PlanetKitCall, calleeInitData: PlanetKitCallInitData )
fun onConnected( call: PlanetKitCall, param: PlanetKitCallConnectedParam )
fun onDisconnected( call:PlanetKitCall, reason:PlanetKitDisconnectReason, userCode:String )
fun onDisconnected( call:PlanetKitCall, param:PlanetKitDisconnectedParam )
-
CallListener
class 1-to-1 callPrevious PlanetKit 5.5 fun onPeerHeld(call: PlanetKitCall, pausedRecv: Boolean, reason: String?)
fun onPeerHold(call: PlanetKitCall, reason: String?)
fun onPeerUnheld(call: PlanetKitCall)
fun onPeerUnhold(call: PlanetKitCall)
fun onVerified(call: PlanetKitCall, callerInitData: PlanetKitCallInitData)
fun onVerified(call: PlanetKitCall, peerStartMessage: PlanetKitCallStartMessage?, peerUseResponderPreparation: Boolean)
fun onConnected(call: PlanetKitCall, calleeInitData: PlanetKitCallInitData)
fun onConnected(call: PlanetKitCall, param: PlanetKitCallConnectedParam)
fun onDisconnected(call: PlanetKitCall, reason: PlanetKitDisconnectReason, userCode: String?)
fun onDisconnected(call: PlanetKitCall, param: PlanetKitDisconnectedParam)
fun onPeerVideoEnabled(call: PlanetKitCall)
fun onVideoEnabledByPeer(call: PlanetKitCall)
fun onPeerVideoDisabled(call: PlanetKitCall, reason: PlanetKitMediaDisableReason)
fun onVideoDisabledByPeer(call: PlanetKitCall, reason: PlanetKitMediaDisableReason)
fun onPeerMyMuteRequested(call: PlanetKitCall, isMute: Boolean)
fun onMuteMyAudioRequestedByPeer(call: PlanetKitCall, isMute: Boolean)
fun onPeerScreenSharingStarted(call: PlanetKitCall)
fun onPeerScreenShareStarted(call: PlanetKitCall)
fun onPeerScreenSharingStopped(call: PlanetKitCall, reason: Int)
fun onPeerScreenShareStopped(call: PlanetKitCall, hasReason: Boolean, reason: Int)
fun onPeerMicUnMuted(call: PlanetKitCall)
fun onPeerMicUnmuted(call: PlanetKitCall)
-
PlanetKitStatistics
class 1-to-1 callGroup callPrevious PlanetKit 5.5 val screenSharingSend:ScreenSharingSend?
val myScreenShare:MyScreenShare?
val screenSharingRecvs: List<ScreenSharingRecv>
val peersScreenShare: List<PeerScreenShare>
data class ScreenSharingSend
data class MyScreenShare
data class ScreenSharingRecv
data class PeerScreenShare
val audioSend: AudioSend
val myAudio: MyAudio
val audioRecv: AudioRecv
val peerAudio: PeerAudio
val videoSend:VideoSend?
val myVideo:MyVideo?
val videoRecvs: List<VideoRecv>
val peersVideo: List<PeerVideo>
data class AudioSend
data class MyAudio
data class AudioRecv
data class PeerAudio
data class VideoSend
data class MyVideo
data class VideoRecv
data class PeerVideo
-
PlanetKitScreenShareState
class 1-to-1 callGroup callPrevious PlanetKit 5.5 class PlanetKitScreenSharingState
class PlanetKitScreenShareState
-
SendDataSessionListener
interface 1-to-1 callGroup callPrevious PlanetKit 5.5 class SendDataSessionListener
class OutboundDataSessionListener
fun onError( exception:PlanetKitException )
fun onError( errReason:PlanetKitDataSessionFailReason )
-
PlanetKitConferenceParam.Builder
class Group callPrevious PlanetKit 5.5 fun stid(stid: String)
fun appServerData(appServerData: String)
fun preferredVideoReceiveHwCodec(isPrefer: Boolean)
fun preferredPeerVideoHwCodec(isPrefer: Boolean)
-
PlanetKitConferenceParam
class 1-to-1 callPrevious PlanetKit 5.5 val stid: String
val appServerData: String
val preferredVideoReceiveHwCodec: Boolean
val preferredPeerVideoHwCodec: Boolean
val myVideoSendCapability: PlanetKitVideoCapability?
val myVideoSendCapability: PlanetKitVideoCapability
-
PlanetKitCallParam
class 1-to-1 callPrevious PlanetKit 5.5 data class PlanetKitCallParam
data class PlanetKitMakeCallParam
val stid: String
val appServerData: String
val callInitData: String
val callStartMessage: PlanetKitCallStartMessage?
val isResponderPrepare: Boolean
val useResponderPreparation: Boolean
-
PlanetKitCallParam.Builder
class 1-to-1 callPrevious PlanetKit 5.5 class PlanetKitCallParam.Builder
class PlanetKitMakeCallParam.Builder
fun stid(stid: String)
fun appServerData(appServerData: String)
fun callInitData(callInitData: String)
fun callStartMessage(callStartMessage: PlanetKitCallStartMessage)
fun responderPrepare(isResponderPrepare: Boolean)
fun responderPreparation(useResponderPreparation: Boolean)
-
PlanetKitConfiguration.Builder
class 1-to-1 callGroup callPrevious PlanetKit 5.5 fun audioDefaultAttributes( audioDefaultAttributes: AudioDefaultAttributes )
fun setAudioDefaultAttributes( audioDefaultAttributes: AudioDefaultAttributes )
fun serverUrl( serverUrl: String )
fun setServerUrl( serverUrl: String )
fun logToFile( isEnabled: Boolean )
fun enableLog( isEnabled: Boolean )
fun logLevel( logLevel: PlanetKitLogLevel )
fun setLogLevel( logLevel: PlanetKitLogLevel )
-
PlanetKitConference
class Group callPrevious PlanetKit 5.5 fun removePeerVideoView(peer: PlanetKitUser, view: PlanetKitVideoView)
fun removePeerVideoView(view: PlanetKitVideoView)
fun setPeerVolume(peer: PlanetKitUser, @IntRange(from = 0, to = 110) talkerVolume: Int, userData:Any? = null, callback: PlanetKitRequestCallback? = null :Boolean
PlanetKitSubgroupManager::boolean setPeerVolumeLevelSetting(@NonNull PlanetKitUser peer, @IntRange(from = 0, to = 110) int talkerVolume, @Nullable Object userData, @Nullable PlanetKitRequestCallback callback)
fun leave()
fun leaveConference()
val maxPeerVideoReceiveCount : Int
val peersVideoMaxCount : Int
val maxPeerScreenShareReceiveCount : Int
val peersScreenShareMaxCount : Int
fun unHold(userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun unhold(userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun changeMyScreenShareGroup(toSubgroupName: String?, userData:Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun changeMyScreenShareDestination(toSubgroupName: String, userData:Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun changeMyScreenShareDestinationToMainRoom(userData:Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun enableVideo(userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun enableVideo(initialMyVideoState: PlanetKitInitialMyVideoState = PlanetKitInitialMyVideoState.RESUME, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun setVideoSource(videoSource: VideoSource?)
fun setVideoSource(videoSource: PlanetKitCustomVideoSource)
,fun clearVideoSource()
-
PlanetKitSession
interface 1-to-1 callGroup callPrevious PlanetKit 5.5 interface PlanetKitSession
interface PlanetKitCall
,interface PlanetKitConference
sid: Int
instanceId: Int
val isMicMuted: Boolean
val isMyAudioMuted: Boolean
val isAllPeersAudioPlayoutSilenced: Boolean
PlanetKitCall::val isPeerAudioSilenced: Boolean
PlanetKitConference::val isPeersAudioSilenced: Boolean
val isSendVideoHwCodecEnabled: Boolean
CallListener.onConnected
ConferenceListener.onConnected
fun setMicMute(isMute: Boolean, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun muteMyAudio(isMute: Boolean, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun startAECReferenceData(userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun startUserAcousticEchoCancellerReference(userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun stopAECReferenceData(userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun stopUserAcousticEchoCancellerReference(userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun requestPeerMute(isMute: Boolean, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
PlanetKitCall::fun requestPeerMute(isMute: Boolean, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
PlanetKitConference::fun requestPeersMute(isMute: Boolean, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun requestPeerMute(isMute: Boolean): Boolean
PlanetKitCall::fun requestPeerMute(isMute: Boolean): Boolean
PlanetKitConference::fun requestPeersMute(isMute: Boolean): Boolean
fun silenceAllPeersAudioPlayout(isSilence: Boolean, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
PlanetKitCall::fun silencePeerAudio(isSilence: Boolean, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
PlanetKitConference::fun silencePeersAudio(isSilence: Boolean, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun makeSendDataSession(@IntRange(from = 100, to = 1000) streamId: Int, type: PlanetKitDataSessionType, listener: SendDataSessionListener)
fun makeOutboundDataSession(@IntRange(from = 100, to = 1000) streamId: Int, type: PlanetKitDataSessionType, listener: OutboundDataSessionListener)
fun makeReceiveDataSession(@IntRange(from = 100, to = 1000) streamId: Int, listener: ReceiveDataSessionListener)
fun makeInboundDataSession(@IntRange(from = 100, to = 1000) streamId: Int, listener: InboundDataSessionListener)
fun unsupportedReceiveDataSession(streamId: Int): Boolean
fun unsupportInboundDataSession(streamId: Int): Boolean
fun getReceiveDataSession(@IntRange(from = 100, to = 1000) streamId: Int): PlanetKitReceiveDataSession?
fun getInboundDataSession(@IntRange(from = 100, to = 1000) streamId: Int): PlanetKitInboundDataSession?
fun getSendDataSession(@IntRange(from = 100, to = 1000) streamId: Int): PlanetKitSendDataSession?
fun getOutboundDataSession(@IntRange(from = 100, to = 1000) streamId: Int): PlanetKitOutboundDataSession?
-
PlanetKitAudioVolume
class 1-to-1 callGroup callPrevious PlanetKit 5.5 class PlanetKitAudioVolume
class PlanetKitAudioDescription
val averageVolume: Int
val averageVolumeLevel: Int
val subgroupName:String?
val sentSubgroupName:String?
-
PlanetKitAudioVolumes
class 1-to-1 callGroup callPrevious PlanetKit 5.5 class PlanetKitAudioVolumes
class PlanetKitAudioDescriptions
-
PlanetKitVerifyCallParam.Builder
class 1-to-1 callPrevious PlanetKit 5.5 fun messageData(messageData: String)
fun cCParam(cCParam: PlanetKitCCParam)
-
PlanetKitConferencePeerInfo
class Group callPrevious PlanetKit 5.5 val serviceId: String
PlanetKitConferencePeer::val serviceId: String
val user: PlanetKitUser
PlanetKitConferencePeer::val user: PlanetKitUser
val userId: String
PlanetKitConferencePeer::val userId: String
var videoSubgroupName: String?
PlanetKitConferencePeer::val currentVideoSubgroupName: String?
val mediaType:PlanetKitMediaType
PlanetKitConferencePeer::val mediaType:PlanetKitMediaType
val subgroupNames: Set<String>
PlanetKitConferencePeer::val subgroupNames:Set<String>
val isDataSessionSupport: Boolean
PlanetKitConferencePeer::val isDataSessionSupported: Boolean
val isAudioMuted:Boolean: Boolean
PlanetKitConferencePeer::val isAudioMuted: Boolean
val isOnHold:Boolean
PlanetKitConferencePeer::val holdStatus: HoldStatus
val displayName:String?
PlanetKitConferencePeer::val displayName:String?
val userEquipmentType: PlanetKitUserEquipmentType
PlanetKitConferencePeer::val userEquipmentType: PlanetKitUserEquipmentType
val sipLocalIP: String?
PlanetKitConferencePeer::val sipLocalIP: String?
val sipDeviceInfo:String?
PlanetKitConferencePeer::val sipDeviceInfo:String?
fun isSameMember(member:PlanetKitConferencePeerInfo): Boolean
PlanetKitConferencePeer::fun isSameMember(member:PlanetKitConferencePeer):Boolean
-
PlanetKitConferenceExceptionMessage
class Group callPrevious PlanetKit 5.5 val peer: PlanetKitConferencePeerInfo
val peer: PlanetKitConferencePeer
-
PlanetKitConferencePeerHoldReceivedParam
class Group callPrevious PlanetKit 5.5 val peer:PlanetKitConferencePeerInfo
val peer:PlanetKitConferencePeer
-
PlanetKitConferencePeerSetSharedContentsParam
class Group callPrevious PlanetKit 5.5 val peer:PlanetKitConferencePeerInfo
val peer:PlanetKitConferencePeer
-
OnNoVideoSourceListener
class 1-to-1 callGroup callPrevious PlanetKit 5.5 fun onNoVideoSource(session: PlanetKitSession)
fun onMyVideoNoSourceDetected(call: PlanetKitCall)
,fun onMyVideoNoSourceDetected(conference: PlanetKitConference)
Added
ConferenceListener
class Group callfun onMyAudioDescriptionUpdated(conference: PlanetKitConference, audioDescription: PlanetKitAudioDescription)
fun onPeersAudioDescriptionUpdated(conference: PlanetKitConference, peersAudioDescription:PlanetKitAudioDescriptions)
fun onMyScreenShareStoppedByHold(conference: PlanetKitConference)
fun removePeerVideoView(view: PlanetKitVideoView)
PlanetKitCCParam
class 1-to-1 callval peerId: String
val peerServiceId: String
val mediaType: PlanetKitMediaType
fun create(messageData: String): PlanetKitCCParam?
PlanetKitConferencePeer
class Group callval screenShareSubgroupName:String?
enum class PeerGetFailReason
data class VideoStatusResult
data class ScreenShareStateResult
data class AudioVolumeResult
data class HoldStatus
fun createPeerControl(): PlanetKitPeerControl?
PlanetKitPeerView
class Group callPlanetKitMyMediaStatusListener
interface 1-to-1 callGroup callfun onMyAudioDescriptionUpdated(audioDescription: PlanetKitAudioDescription)
fun onVideoStatusUpdated(videoStatus: PlanetKitVideoStatus)
fun onVideoSubgroupUpdated(subgroupName: String?)
fun onScreenShareStateUpdated(state: PlanetKitScreenShareState)
fun onScreenShareSubgroupUpdated(subgroupName: String?)
fun onMyAudioMuted()
fun onMyAudioUnmuted()
PlanetKitDisconnectedParam
data class 1-to-1 callGroup callval reason: PlanetKitDisconnectReason
val source: PlanetKitDisconnectSource
val byRemote: Boolean
val userCode: String?
PlanetKitStartFailReason
enum 1-to-1 callGroup callTOO_LONG_APP_SERVER_DATA
NOT_INITIALIZED
PlanetKitDisconnectReason
enum 1-to-1 callGroup callINTERNAL_ERROR
USER_ERROR
INTERNAL_KIT_ERROR
AUDIO_TX_NO_SRC
UNAVAILABLE_NETWORK
APP_DESTROY
SYSTEM_SLEEP
SYSTEM_LOGOFF
SERVICE_ACCESS_TOKEN_ERROR
MTU_EXCEEDED
APP_SERVER_DATA_ERROR
MAX_CALL_TIME_EXCEEDED
SERVICE_TOO_MANY_REQUESTS
DESKTOP_SCREEN_LOCKED
PlanetKitDisconnectSource
enum 1-to-1 callGroup callUNDEFINED
CALLEE
CALLER
PARTICIPANT
CLOUD_SERVER
APP_SERVER
PlanetKitCall
class 1-to-1 callval isPeerAudioMuted:Boolean
val myUseResponderPreparation: Boolean
val myCallStartMessage: PlanetKitCallStartMessage?
val peerUseResponderPreparation: Boolean
val peerCallStartMessage: PlanetKitCallStartMessage?
fun acceptCall( listener: AcceptCallListener, useResponderPreparation: Boolean = false )
fun acceptCall( listener: AcceptCallListener, callStartMessage: PlanetKitCallStartMessage, useResponderPreparation: Boolean = false )
fun setMyScreenShareVideoShareMode(videoShareMode: Boolean): Boolean
fun isMyScreenShareVideoShareModeEnabled(): Boolean
fun isRecordOnCloudActivated(): Boolean
fun setOnAudioRouteAvailableListChangeListener(listener: OnAudioRouteAvailableListChangeListener?)
fun getMyMediaStatus() : PlanetKitMyMediaStatus?
PlanetKitCallConnectedParam
data class 1-to-1 callval isDataSessionSupported: Boolean
val isVideoHwCodecEnabled: Boolean
val peerStartMessage: PlanetKitCallStartMessage?
val isInResponderPreparation: Boolean
val shouldFinishPreparation: Boolean
val isVideoShareModeSupported: Boolean
PlanetKitCallStartMessage
data class 1-to-1 callval data: String
PlanetKitConference
class Group callfun getConferencePeer(peerUser: PlanetKitUser): PlanetKitConferencePeer?
fun getConferencePeer(peerId: String, peerServiceId: String): PlanetKitConferencePeer?
fun removePeerScreenShareView(view: PlanetKitVideoView)
val isOnHold: Boolean
fun setMyScreenShareVideoShareMode(videoShareMode: Boolean): Boolean
fun isMyScreenShareVideoShareModeEnabled(): Boolean
fun setOnAudioRouteAvailableListChangeListener(listener: OnAudioRouteAvailableListChangeListener?)
fun getMyMediaStatus() : PlanetKitMyMediaStatus?
PlanetKitMyView
class 1-to-1 callGroup callfun fillColor(@ColorInt color : Int)
fun setMe(conference: PlanetKitConference, myViewListener: MyViewListener? =null, userData:Any? =null, ) : Boolean
fun setMe(call: PlanetKitCall, myViewListener: MyViewListener? =null, userData:Any?=null): Boolean
var scaleType : PlanetKitViewScaleType
var blurFactor : Int
val myVideoStatus: PlanetKitVideoStatus
val myVideoSubgroupName: String?
val myScreenShareState: PlanetKitScreenShareState
val myScreenShareSubgroupName: String?
val myDisplayName: String?
val myEquipmentType: PlanetKitUserEquipmentType
val isOnHold: Boolean?
val isMyAudioMuted: Boolean?
val me:PlanetKitUser?
fun clearMe()
fun resetFirstFrameRendered()
interface MyViewListener
var mirroredType: PlanetKitMirroredType
PlanetKitMyView.MyViewListener
interface 1-to-1 callGroup callfun onInitialized(userData: Any?)
fun onRenderFirstFrame()
fun onAudioDescriptionUpdated(audioDescription:PlanetKitAudioDescription)
fun onVideoStatusUpdated(videoStatus: PlanetKitVideoStatus)
fun onVideoSubgroupUpdated(subgroupName: String?)
fun onMyAudioMuted()
fun onMyAudioUnmuted()
fun onScreenShareStateUpdated(state: PlanetKitScreenShareState)
fun onScreenShareSubgroupUpdated(subgroupName: String?)
fun onHold()
fun onUnHold()
PlanetKitPeerScreenShareView
class Group callval isScreenShareStarted : Boolean
var scaleType : PlanetKitViewScaleType
var blurFactor : Int
var mirroredType: PlanetKitMirroredType
val peer : PlanetKitConferencePeer?
fun fillColor(@ColorInt color : Int)
fun setPeer( session: PlanetKitConference, newConferencePeer: PlanetKitConferencePeer, peerScreenShareViewListener: PeerScreenShareViewListener? =null, userData:Any?=null, ) : Boolean
fun clearPeer()
fun startScreenShare( subgroupName: String? = null, callback: PlanetKitVideoRequestCallback?= null, userData: Any?=null, ) : Boolean
fun stopScreenShare(userData: Any?=null, callback: PlanetKitVideoRequestCallback?=null) : Boolean
interface PeerScreenShareViewListener
PlanetKitPeerScreenShareView.PeerScreenShareViewListener
interface Group callfun onInitialized(peer: PlanetKitConferencePeer, userData: Any?)
fun onRenderFirstFrame(peer: PlanetKitConferencePeer)
fun onScreenShareUpdated(peer: PlanetKitConferencePeer, state: PlanetKitScreenShareState, subgroupName: String?)
fun onDisconnected(peer: PlanetKitConferencePeer)
PlanetKitDataSessionFailReason
enum 1-to-1 callGroup callNONE
INTERNAL
NOT_INCOMING
ALREADY_EXIST
INVALID_ID
INVALID_TYPE
PlanetKitConferenceParam
class Group callval playEndToneRegardlessOfConferenceState: Boolean
val enableAudioDescription: Boolean
val audioDescriptionInterval:Long
PlanetKitConferenceParam.Builder
class Group callfun enableAudioDescription(enable:Boolean)
fun setAudioDescriptionInterval(intervalMS:Long)
fun enablePlayEndToneRegardlessOfConferenceState(value: Boolean)
fun setInitialMyVideoState(value: PlanetKitInitialMyVideoState)
CallListener
class 1-to-1 callfun onMyAudioDescriptionUpdated(call: PlanetKitCall, audioDescription: PlanetKitAudioDescription)
fun onPeerAudioDescriptionUpdated(call: PlanetKitCall, audioDescription: PlanetKitAudioDescription)
fun onMyScreenShareStoppedByHold(call: PlanetKitCall)
fun onRecordOnCloudUpdated(call: PlanetKitCall, activated: Boolean, reason: PlanetKitRecordOnCloudDeactivateReason)
PlanetKitSubgroup
class Group callval attribute: PlanetKitSubgroupAttribute?
val isSendingScreenShare: Boolean
PlanetKit
class 1-to-1 callGroup callfun interface OnInitializeCompleteListener
VideoSource
abstract class 1-to-1 callGroup callprotected fun postingFrameDataAvailable(nanoSecondsTimestamp: Long): Boolean
protected val isMaxFpsLimitEnabled: Boolean
protected val maxFpsLimit: Int
protected abstract fun onMaxFpsLimitUpdated(isLimitEnabled: Boolean, maxFps: Int)
PlanetKitSubgroupAttribute
data class Group callPlanetKitMakeCallParam
data class 1-to-1 callval enableAudioDescription: Boolean
val audioDescriptionInterval:Long
val recordOnCloud: Boolean
val playEndToneRegardlessOfCallState: Boolean
PlanetKitMakeCallParam.Builder
class 1-to-1 callfun enableAudioDescription(enable:Boolean)
fun setAudioDescriptionInterval(intervalMS:Long)
fun enableRecordOnCloud(value: Boolean)
fun enablePlayEndToneRegardlessOfCallState(value: Boolean)
fun setInitialMyVideoState(value: PlanetKitInitialMyVideoState)
PlanetKitRecordOnCloudDeactivateReason
enum class 1-to-1 callPlanetKitLogSizeLimit
enum class 1-to-1 callGroup callPlanetKitConfiguration.Builder
class 1-to-1 callGroup callfun setLogSizeLimit(logSizeLimit: PlanetKitLogSizeLimit)
PlanetKitVerifyCallParam
class 1-to-1 callval enableAudioDescription: Boolean
val audioDescriptionInterval:Long
val playEndToneRegardlessOfCallState: Boolean
PlanetKitVerifyCallParam.Builder
class 1-to-1 callfun enableAudioDescription(enable:Boolean)
fun setAudioDescriptionInterval(intervalMS:Long)
fun enablePlayEndToneRegardlessOfCallState(value: Boolean)
PlanetKitVideoView
class 1-to-1 callGroup callvar mirroredType: PlanetKitMirroredType
PlanetKitMirroredType
enum class 1-to-1 callGroup callPlanetKitDataSessionClosedReason
enum class 1-to-1 callGroup callOutboundDataSessionListener
interface 1-to-1 callGroup callvoid onClosed(@NonNull PlanetKitOutboundDataSession dataSession, @NonNull PlanetKitDataSessionClosedReason closedReason)
InboundDataSessionListener
interface 1-to-1 callGroup callvoid onClosed(@NonNull PlanetKitInboundDataSession dataSession, @NonNull PlanetKitDataSessionClosedReason closedReason)
PlanetKitPeerControl
class Group callval peer: PlanetKitConferencePeer
fun startScreenShare(subgroupName: String? = null, callback: PlanetKitVideoRequestCallback?= null, userData: Any?=null) : Boolean
fun stopScreenShare(userData: Any?=null, callback: PlanetKitVideoRequestCallback?=null) : Boolean
fun startVideo(resolution: PlanetKitVideoResolution, subgroupName: String? = null, callback: PlanetKitVideoRequestCallback?= null, resolutionCallback: PlanetKitPeerVideoResolutionCallback?=null, userData: Any?=null) : Boolean
fun stopVideo(userData: Any?=null, callback: PlanetKitVideoRequestCallback?=null) : Boolean
fun register(peerControlListener: PeerControlListener, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun unregister(userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
PlanetKitPeerControl.PeerControlListener
interface Group callfun onVideoUpdated(peer: PlanetKitConferencePeer, videoStatus: PlanetKitVideoStatus, subgroupName: String?)
fun onMicMuted(peer: PlanetKitConferencePeer)
fun onMicUnmuted(peer: PlanetKitConferencePeer)
fun onScreenShareUpdated(peer: PlanetKitConferencePeer, state: PlanetKitScreenShareState, subgroupName: String?)
fun onSubscribed(peer: PlanetKitConferencePeer, subgroup: PlanetKitSubgroup)
fun onUnsubscribed(peer: PlanetKitConferencePeer, subgroupName: String?)
fun onSharedContentsSet(peer: PlanetKitConferencePeer, param: PlanetKitConferencePeerSetSharedContentsParam)
fun onSharedContentsUnSet(peer: PlanetKitConferencePeer)
fun onHold(peer: PlanetKitConferencePeer, reason:String?)
fun onUnhold(peer: PlanetKitConferencePeer)
fun onAudioDescriptionUpdated(peer: PlanetKitConferencePeer, audioDescription: PlanetKitAudioDescription)
fun onDisconnected(peer: PlanetKitConferencePeer)
PlanetKitMyMediaStatus
class 1-to-1 callGroup callval myVideoStatus: PlanetKitVideoStatus
val myVideoSubgroupName: String?
val myScreenShareState: PlanetKitScreenShareState
val myScreenShareSubgroupName: String?
val isMyAudioMuted: Boolean
fun addHandler(listener: PlanetKitMyMediaStatusListener, userData:Any?, callback: PlanetKitRequestCallback)
fun removeHandler(listener: PlanetKitMyMediaStatusListener, userData:Any?, callback: PlanetKitRequestCallback)
OnAudioRouteAvailableListChangeListener
interface 1-to-1 callGroup callfun onAudioRouteAvailableListChanged(connectedList: List<PlanetKitAudioRoute>)
PlanetKitCameraManager
interface 1-to-1 callGroup callval resolution: PlanetKitVideoResolution
var cameraType: PlanetKitCameraType
val isStarted: Boolean
val fps: Int
fun setStateListener(listener: StateListener?)
fun setManualResolution(resolution: PlanetKitVideoResolution)
fun setDefaultResolution()
fun setVirtualBackgroundPlugin(plugin: PlanetKitPluginVirtualBackground) :Boolean
fun addCameraTypeChangedListener(listener: CameraTypeChangedListener)
fun removeCameraTypeChangedListener(listener: CameraTypeChangedListener)
fun setVideoSourceInterceptor(interceptor: PlanetKitVideoInterceptor?)
fun startPreview(view: PlanetKitVideoView): Boolean
fun stopPreview(view: PlanetKitVideoView): Boolean
fun enableDumpFrame(enable: Boolean)
PlanetKitCameraManager.StateListener
interface 1-to-1 callGroup callfun onStart()
fun onStop()
fun onError(@ErrorCode code: Int)
PlanetKitCameraManager.CameraTypeChangedListener
interface 1-to-1 callGroup callfun onChanged(isFrontCamera: Boolean)
PlanetKitPluginVirtualBackground
interface 1-to-1 callGroup callfun getCurrentVirtualBackgroundType(): VirtualBackgroundType
fun setVirtualBackgroundWithBlur(@IntRange(from = 1, to = 25) radius: Int)
fun setVirtualBackgroundWithImage(inputImage: Bitmap)
fun clearVirtualBackground()
PlanetKitPluginVirtualBackground.VirtualBackgroundType
enum class 1-to-1 callGroup callNONE(0)
BLUR(1)
IMAGE(2)
PlanetKitPluginProviderVirtualBackground
class 1-to-1 callGroup callfun getPlugin(): PlanetKitPluginVirtualBackground
PlanetKitInitialMyVideoState
enum class 1-to-1 callGroup callRESUME(0)
PAUSE(1)
PlanetKitCustomVideoSource
abstract class 1-to-1 callGroup callvar maxFps: Int? = null
fun addMyVideoView(view: PlanetKitVideoView)
fun removeMyVideoView(view: PlanetKitVideoView)
protected fun postFrameData(frameData: FrameData): Boolean
protected fun postingFrameDataAvailable(): Boolean
abstract fun onMaxFpsLimitUpdated(isLimitEnabled: Boolean, maxFps: Int)
PlanetKitCustomVideoSource.FrameData
abstract class 1-to-1 callGroup callPlanetKitCameraResolution
enum class 1-to-1 callGroup callQVGA
VGA
HD
Removed
ScreenCapturerVideoSource
class 1-to-1 callGroup callfun stop(reason: VideoSource.VideoSourceStopReason): Boolean
fun useDeviceRotation(): Boolean
PlanetKitMediaDisableReason
enum class 1-to-1 callGroup callNOT_SUPPORT
NO_MEDIA_SRC
NO_RECV_MEDIA
CameraVideoSource
class 1-to-1 callGroup callPlanetKitVideoView
class 1-to-1 callGroup calloverride fun getRenderView(): AndromedaRenderView
PlanetKitVerifyCallParam.Builder
class 1-to-1 callfun myScreenShareSendCapability(capability: PlanetKitVideoCapability)
PlanetKitVerifyCallParam
data class 1-to-1 callval myScreenShareSendCapability: PlanetKitVideoCapability?
PlanetKitConferenceRoomType
enum class Group callPlanetKitMakeCallParam.Builder
class 1-to-1 callfun myScreenShareSendCapability(capability: PlanetKitVideoCapability)
PlanetKitMakeCallParam
data class 1-to-1 callval myScreenShareSendCapability: PlanetKitVideoCapability?
SendDataSessionListener
interface 1-to-1 callGroup callvoid onUnsupportedDataSession(@NonNull PlanetKitSendDataSession dataSession)
PlanetKitConferenceParam
class Group callval apiKey: String?
val roomType: PlanetKitConferenceRoomType
val myScreenShareSendCapability: PlanetKitVideoCapability?
val disconnectOnBadNetwork: Boolean
PlanetKitConferenceParam.Builder
class Group callfun apiKey(apiKey: String)
fun roomType(roomType: PlanetKitConferenceRoomType)
fun myScreenShareSendCapability(capability: PlanetKitVideoCapability)
fun disconnectOnBadNetwork(disconnectOnBadNetwork: Boolean)
PlanetKitCallParam.Builder
class 1-to-1 callfun apiKey(apiKey: String)
PlanetKitCallParam
class 1-to-1 callval apiKey: String?
PlanetKitCallInitData
class 1-to-1 callPlanetKitError
enum 1-to-1 callGroup callSESSION_FAIL_REASON_ALREADY_EXIST
SESSION_FAIL_REASON_INVALID_SESSION_TYPE
SESSION_FAIL_REASON_FAILED_TO_MAKE_DATA_SESSION
PlanetKitConfiguration.Builder
class 1-to-1 callGroup callfun logToConsole( isEnabled: Boolean )
PlanetKitConference
class Group callfun initialize(context: Context)
val memberVolumes: PlanetKitAudioVolumes?
val isHighPriorityAudio: Boolean
fun sendShortData( targetUsers: List<PlanetKitUser>, type: String, shortData: ByteArray, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
fun sendShortData( targetUsers: List<PlanetKitUser>, type: String, shortData: ByteArray): Boolean
fun setAudioHighPrioritySend( isHighPriority: Boolean, userData: Any? = null, callback: PlanetKitRequestCallback? = null): Boolean
val roomType: PlanetKitConferenceRoomType
PlanetKitCall
class 1-to-1 callval myCallInitData: PlanetKitCallInitData?
val peerCallInitData: PlanetKitCallInitData?
fun acceptCall(mediaType: PlanetKitMediaType, listener: AcceptCallListener, callInitData:PlanetKitCallInitData )
fun acceptCall( listener: AcceptCallListener, callInitData: PlanetKitCallInitData = PlanetKitCallInitData() )
val peerVolume:PlanetKitAudioVolume?
fun initialize(context: Context)
fun reject()
PlanetKitLogStorage
class 1-to-1 callGroup callPlanetKitLogStorageType
enum 1-to-1 callGroup callPlanetKitConferencePeer
class Group callvar audioSubgroupName: String?
var audioTaggedSubgroupName: String?
PlanetKitSession
class 1-to-1 callGroup callval myVolume: PlanetKitAudioVolume
PlanetKitIntent
class 1-to-1 callPlanetKitStartFailReason
enum 1-to-1 callGroup callKIT_CALL_INIT_DATA_INVALID_SIZE
PlanetKitDisconnectReason
enum 1-to-1 callGroup callLOCAL_MIC_NO_SRC
REMOTE_MIC_NO_SRC
LOCAL_INTERNAL_ERROR
REMOTE_INTERNAL_ERROR
LOCAL_USER_ERROR
REMOTE_USER_ERROR
LOCAL_INTERNAL_KIT_ERROR
REMOTE_INTERNAL_KIT_ERROR
BAD_NETWORK_IN_CONFERENCE
UNAVAILABLE_NETWORK_IN_CALL
SERVICE_APIKEY_ERROR
WRONG_ROOM_ATTRIBUTE
PlanetKitSubgroupManager
class Group callboolean tagMainRoomVideoSend(@Nullable String subgroupName, @Nullable java.lang.Object userData, @Nullable PlanetKitRequestCallback callback)
PlanetKitSubgroup getMyTagVideoSubgroup()
PlanetKitConferencePeerInfo
class Group callvar videoTaggedSubgroupName: String?
DefaultCameraVideoSource
class 1-to-1 callGroup call