Skip to content

Commit c0e84d9

Browse files
[AUTO] Generate code by terra (#973)
Co-authored-by: LichKing-2234 <[email protected]>
1 parent 14656ee commit c0e84d9

File tree

2 files changed

+20
-14
lines changed

2 files changed

+20
-14
lines changed

ts/Private/IAgoraRtcEngine.ts

+7-4
Original file line numberDiff line numberDiff line change
@@ -4804,7 +4804,7 @@ export abstract class IRtcEngine {
48044804
* @ignore
48054805
*/
48064806
abstract startScreenCaptureDesktop(
4807-
type: VideoSourceType,
4807+
sourceType: VideoSourceType,
48084808
config: ScreenCaptureConfiguration
48094809
): number;
48104810

@@ -4836,12 +4836,15 @@ export abstract class IRtcEngine {
48364836
abstract setScreenCaptureScenario(screenScenario: ScreenScenarioType): number;
48374837

48384838
/**
4839-
* Stops screen sharing.
4839+
* Stops the local video preview.
4840+
* After calling startPreview to start the preview, if you want to close the local video preview, call this method.Call this method before joining a channel or after leaving a channel.
4841+
*
4842+
* @param sourceType The type of the video frame, see VideoSourceType .
48404843
*
48414844
* @returns
4842-
* 0: Success.< 0: Failure.
4845+
* < 0: Failure.
48434846
*/
4844-
abstract stopScreenCapture(type?: VideoSourceType): number;
4847+
abstract stopScreenCapture(sourceType?: VideoSourceType): number;
48454848

48464849
/**
48474850
* Retrieves the call ID.

ts/Private/impl/IAgoraRtcEngineImpl.ts

+13-10
Original file line numberDiff line numberDiff line change
@@ -5010,16 +5010,19 @@ export class IRtcEngineImpl implements IRtcEngine {
50105010
}
50115011

50125012
startScreenCaptureDesktop(
5013-
type: VideoSourceType,
5013+
sourceType: VideoSourceType,
50145014
config: ScreenCaptureConfiguration
50155015
): number {
5016-
const apiType = this.getApiTypeFromStartScreenCaptureDesktop(type, config);
5016+
const apiType = this.getApiTypeFromStartScreenCaptureDesktop(
5017+
sourceType,
5018+
config
5019+
);
50175020
const jsonParams = {
5018-
type: type,
5021+
sourceType: sourceType,
50195022
config: config,
50205023
toJSON: () => {
50215024
return {
5022-
type: type,
5025+
sourceType: sourceType,
50235026
config: config,
50245027
};
50255028
},
@@ -5029,7 +5032,7 @@ export class IRtcEngineImpl implements IRtcEngine {
50295032
}
50305033

50315034
protected getApiTypeFromStartScreenCaptureDesktop(
5032-
type: VideoSourceType,
5035+
sourceType: VideoSourceType,
50335036
config: ScreenCaptureConfiguration
50345037
): string {
50355038
return 'RtcEngine_startScreenCaptureDesktop';
@@ -5087,14 +5090,14 @@ export class IRtcEngineImpl implements IRtcEngine {
50875090
}
50885091

50895092
stopScreenCapture(
5090-
type: VideoSourceType = VideoSourceType.VideoSourceScreenPrimary
5093+
sourceType: VideoSourceType = VideoSourceType.VideoSourceScreenPrimary
50915094
): number {
5092-
const apiType = this.getApiTypeFromStopScreenCapture(type);
5095+
const apiType = this.getApiTypeFromStopScreenCapture(sourceType);
50935096
const jsonParams = {
5094-
type: type,
5097+
sourceType: sourceType,
50955098
toJSON: () => {
50965099
return {
5097-
type: type,
5100+
sourceType: sourceType,
50985101
};
50995102
},
51005103
};
@@ -5103,7 +5106,7 @@ export class IRtcEngineImpl implements IRtcEngine {
51035106
}
51045107

51055108
protected getApiTypeFromStopScreenCapture(
5106-
type: VideoSourceType = VideoSourceType.VideoSourceScreenPrimary
5109+
sourceType: VideoSourceType = VideoSourceType.VideoSourceScreenPrimary
51075110
): string {
51085111
return 'RtcEngine_stopScreenCapture';
51095112
}

0 commit comments

Comments
 (0)