MeiCam SDK For iOS
3.11.2
|
Streaming context. More...
#import <NvsStreamingContext.h>
Instance Methods | |
(BOOL) | - preloadEffectResources |
Preload effect resources. More... | |
(EAGLSharegroup *) | - getEAGLSharegroup |
Gets the EAGLSharegroup object used by the engine from the streaming context. More... | |
(float) | - detectEngineRenderFramePerSecond |
Get the current rendering speed of the engine from the streaming context that it's only valid after startCapturePreview and playbackTimeline. More... | |
(NvsAVFileInfo *) | - getAVFileInfo: |
Gets audio and video informations of a file. More... | |
(NvsAVFileInfo *) | - getAVFileInfoExtra:extraFlag: |
Gets audio and video information of a file. More... | |
(NvsAVFileInfo *) | - getAVFileInfo:extraFlag:withError: |
Gets detailed information of the audio/video file. More... | |
(int) | - detectVideoFileKeyframeInterval: |
Detects the I frame interval of video files. More... | |
(BOOL) | - setDefaultThemeEndingLogoImageFilePath: |
Sets the default theme logo image path. More... | |
(NSString *) | - getDefaultThemeEndingLogoImageFilePath |
Gets the default theme logo image path. More... | |
(BOOL) | - setThemeEndingEnabled: |
Sets whether the logo effect at the end of the theme is displayed or not. More... | |
(int) | - getEngineHDRCaps |
Get HDR capability. More... | |
(void) | - setAudioVUMeterEnabled: |
Enable DB value of audio output. More... | |
(void) | - setEnableAudioSampleNotify: |
Enable DB value of audio output. More... | |
(NSString *) | - registerFontByFilePath: |
Gets the fontFamily of the font file. More... | |
(NSArray *) | - getFontInfoByFilePath: |
Gets font file's font information. More... | |
(void) | - setColorGainForSDRToHDR: |
Sets the color gain during SDR to HDR conversion. More... | |
(float) | - getColorGainForSDRToHDR |
gets the color gain during SDR to HDR conversion. More... | |
(BOOL) | - exportTemplateInfo:timeline:requestedAspectRatio: |
Export template information. More... | |
(BOOL) | - generateTemplatePackage:innerAssetDir:templateOutputDir: |
Generate template asset package. More... | |
(void) | - setTemplate:customResourceDir: |
set templates custom resource folders More... | |
(BOOL) | - exportProjectInfo:timeline:requestedAspectRatio: |
Export project information. More... | |
(BOOL) | - generateProjectPackage:innerAssetDir:projectOutputDir: |
Generate project asset package. More... | |
(NvsTimeline *) | - createTimeline:videoFps:audioEditRes: |
Creates timeline. More... | |
(NvsTimeline *) | - createTimeline:videoFps:audioEditRes:flags: |
Creates timeline. More... | |
(NvsTimeline *) | - createTimeline:videoFps:audioEditRes:bitDepth:flags: |
Creates timeline. More... | |
(NvsTimeline *) | - createTimeline:templateFootages: |
Creates timeline. More... | |
(NvsTimeline *) | - createTimeline:templateFootages:flags: |
Creates timeline. More... | |
(NvsTimeline *) | - createTimeline:templateFootages:flags:videoFps:audioEditRes: |
Creates timeline. More... | |
(NvsTimeline *) | - loadProject:resourceDir: |
Creates timeline. More... | |
(BOOL) | - removeTimeline: |
Removes timeline. More... | |
(NvsStreamingEngineState) | - getStreamingEngineState |
Gets the engine state. More... | |
(int64_t) | - getTimelineCurrentPosition: |
Gets the current position of the timeline (in microseconds). More... | |
(BOOL) | - compileTimeline:startTime:endTime:outputFilePath:videoResolutionGrade:videoBitrateGrade:flags: |
Compiles the video files by the timeline. More... | |
(BOOL) | - compileTimeline:startTime:endTime:outputFilePath:videoResolutionGrade:videoBitrateGrade:compileConfigurations:flags: |
Compiles the video files by the timeline. More... | |
(BOOL) | - compilePassthroughTimeline:outputFilePath:compileConfigurations:flags: |
Compile passthrough the video clips on video track 0 in the timeline into a file without processing filter, multi track and nested timeline. If there are photos, it will fail. More... | |
(BOOL) | - pauseCompiling |
Pause compiling timeline. More... | |
(BOOL) | - resumeCompiling |
Resume compiling timeline. More... | |
(BOOL) | - isCompilingPaused |
Check if compiling timeline is paused. More... | |
(BOOL) | - pausePlayback |
Pause playback timeline. More... | |
(BOOL) | - resumePlayback |
Resume playback timeline. More... | |
(BOOL) | - isPlaybackPaused |
Check if playback timeline is paused. More... | |
(void) | - setCustomCompileVideoHeight: |
Sets the customized height for video. When compiling videos, set the bitrate grade for compiled video to COMPILE_VIDEO_RESOLUTION_GRADE_CUSTOM. Plesae note, to make sure the file is compiled successfully, Meishe SDK would calibrate the height accordingly, thus the final output file may not necessarily be the height set here. More... | |
(unsigned int) | - getCustomCompileVideoHeight |
Gets the custom video height. More... | |
(BOOL) | - connectTimeline:withLiveWindow: |
Connects timeline with live window. More... | |
(BOOL) | - connectTimeline:withVideoFrameReceiver: |
Connects timeline with video frame receiver. More... | |
(BOOL) | - seekTimeline:timestamp:videoSizeMode:flags: |
Seeks to a certain timestamp of images. More... | |
(BOOL) | - seekTimeline:timestamp:proxyScale:flags: |
Seeks to a certain timestamp of images. More... | |
(UIImage *) | - grabImageFromTimeline:timestamp:proxyScale: |
Gets the image in the timeline of a certain timestamp. For details, refer to The Topic of Video Frame Image Extraction. More... | |
(UIImage *) | - grabImageFromTimeline:timestamp:proxyScale:flags: |
Gets the image in the timeline of a certain timestamp. For details, refer to The Topic of Video Frame Image Extraction. More... | |
(BOOL) | - grabImageFromTimelineAsync:timestamp:proxyScale:flags: |
Gets the specific frame in timeline with a specific timestamp. For details please refer to The video frame retriever. This function is an internal asynchronous call. It is necessary to ensure that SeekTimeline () will not be invoked before getting the image. If the function that calls SeekTimeline after calling this function may not get the callback of the image, it can call Stop after this function to ensure that the Grab image can be executed successfully. More... | |
(BOOL) | - playbackTimeline:startTime:endTime:videoSizeMode:preload:flags: |
Playback timeline. More... | |
(BOOL) | - playbackTimeline:startTime:endTime:proxyScale:preload:flags: |
Playback timeline. More... | |
(void) | - stop |
Stops the engine. More... | |
(void) | - stop: |
tops the engine More... | |
(void) | - clearCachedResources: |
Clears the cached resources. More... | |
(void) | - clearCachedResources:flags: |
Clears the cached resources. More... | |
(unsigned int) | - captureDeviceCount |
Count of captureing devices. More... | |
(BOOL) | - isCaptureDeviceBackFacing: |
Whether it's a rear capturing device. More... | |
(NvsCaptureDeviceCapability *) | - getCaptureDeviceCapability: |
Obtains the capability description object of the capture device. More... | |
(BOOL) | - connectCapturePreviewWithLiveWindow: |
Connects the captured preview with live window. More... | |
(BOOL) | - connectCapturePreviewWithVideoFrameReceiver: |
Connects the captured preview with video frame receiver. More... | |
(void) | - setUserWatermarkForCapture:displayWidth:displayHeight:opacity:position:marginX:marginY: |
Adds a custom watermark for capturing video. More... | |
(void) | - removeUserWatermarkForCapture |
Removes custom watermark which added for capturing video. More... | |
(BOOL) | - startCapturePreview:videoResGrade:flags:aspectRatio: |
Starts the capture preview. More... | |
(BOOL) | - startBufferCapturePreview:height:fps:rotation:flipHorizontally: |
Starts the capture preview with inputting buffer mode. More... | |
(BOOL) | - sendBufferToCapturePreview: |
Transfers the input buffer to capture preivew. More... | |
(BOOL) | - sendAudioSamplesToCapturePreview: |
Transfers the input buffer to capture preivew. More... | |
(NvsSize) | - getCapturePreviewVideoSize: |
Gets the capture preview resolution. More... | |
(NvsColor) | - sampleColorFromCapturedVideoFrame: |
Samples the capture device's video frame. More... | |
(void) | - startAutoFocus: |
Starts autofocus. More... | |
(void) | - cancelAutoFocus |
Cancels the ongoing autofocus. More... | |
(void) | - startContinuousFocus |
Starts continuous focus. More... | |
(void) | - startAutoExposure: |
Starts automatic exposure adjustment. More... | |
(void) | - setZoomFactor: |
Sets the zoom factor. More... | |
(float) | - getZoomFactor |
Gets the zoom factor. More... | |
(void) | - toggleFlash: |
Sets which the flash light is on/off. More... | |
(BOOL) | - isFlashOn |
get state of the flash light. More... | |
(void) | - toggleFlashMode: |
Sets the flash mode. More... | |
(NvsCameraFlashMode) | - getFlashMode |
get state of the flash light. More... | |
(VideoStabilizationFlag) | - getVideoStabilization |
Gets the current video’s stabilization flag. More... | |
(void) | - setVideoStabilization: |
Sets video stabilization. More... | |
(void) | - setExposureBias: |
Set exposure compensation. More... | |
(float) | - getExposureBias |
Gets exposure compensation. More... | |
(NvsCaptureVideoFx *) | - appendBuiltinCaptureVideoFx: |
Appends a built-in capture video effect. More... | |
(NvsCaptureVideoFx *) | - insertBuiltinCaptureVideoFx:withInsertPosition: |
Inserts a built-in video capture effect. More... | |
(NvsCaptureVideoFx *) | - appendPackagedCaptureVideoFx: |
Appends a package capture effectx. More... | |
(NvsCaptureVideoFx *) | - insertPackagedCaptureVideoFx:withInsertPosition: |
Inserts a package capture effect. More... | |
(NvsCaptureVideoFx *) | - appendCustomCaptureVideoFx: |
Appends a custom capture video effect. More... | |
(NvsCaptureVideoFx *) | - insertCustomCaptureVideoFx:withInsertPosition: |
Inserts a custom capture video effect. More... | |
(NvsCaptureVideoFx *) | - appendBeautyCaptureVideoFx |
Appends a beauty effect. More... | |
(NvsCaptureVideoFx *) | - insertBeautyCaptureVideoFx: |
Inserts a skin beauty video effect. More... | |
(BOOL) | - removeCaptureVideoFx: |
Removes a certain capture video effect indicated by its index. More... | |
(void) | - removeAllCaptureVideoFx |
Removes all capture video effects. More... | |
(unsigned int) | - getCaptureVideoFxCount |
Gets the count of video effects. More... | |
(NvsCaptureVideoFx *) | - getCaptureVideoFxByIndex: |
Gets a certain capture video effect. More... | |
(NvsCaptureAudioFx *) | - appendBuiltinCaptureAudioFx: |
Appends a built-in capture audio effect. More... | |
(NvsCaptureAudioFx *) | - insertBuiltinCaptureAudioFx:withInsertPosition: |
Inserts a built-in audio capture effect. More... | |
(BOOL) | - removeCaptureAudioFx: |
Removes a certain capture audio effect indicated by its index. More... | |
(void) | - removeAllCaptureAudioFx |
Removes all capture audio effects. More... | |
(unsigned int) | - getCaptureAudioFxCount |
Gets the count of audio effects. More... | |
(NvsCaptureAudioFx *) | - getCaptureAudioFxByIndex: |
Gets a certain capture audio effect. More... | |
(NvsCaptureAnimatedSticker *) | - appendCaptureAnimatedSticker:duration:animatedStickerPackageId: |
Appends a animated sticker. More... | |
(NvsCaptureAnimatedSticker *) | - insertCaptureAnimatedSticker:duration:animatedStickerPackageId:insertPosition: |
Appends a animated sticker. More... | |
(NvsCaptureAnimatedSticker *) | - addCustomCaptureAnimatedSticker:duration:animatedStickerPackageId:customImagePath: |
Add a custom animated sticker on capture. More... | |
(NvsCaptureAnimatedSticker *) | - insertCustomCaptureAnimatedSticker:duration:animatedStickerPackageId:customImagePath:insertPosition: |
Insert a animated sticker. More... | |
(BOOL) | - removeCaptureAnimatedSticker: |
Removes a certain capture animated sticker indicated by its index. More... | |
(void) | - removeAllCaptureAnimatedSticker |
Removes all capture animated sticker. More... | |
(unsigned int) | - getCaptureAnimatedStickerCount |
Gets the count of capture animated sticker. More... | |
(NvsCaptureAnimatedSticker *) | - getCaptureAnimatedStickerByIndex: |
Gets a certain capture animated sticker. More... | |
(NvsCaptureCompoundCaption *) | - appendCaptureCompoundCaption:duration:compoundCaptionPackageId: |
Appends a compound caption. More... | |
(NvsCaptureCompoundCaption *) | - insertCaptureCompoundCaption:duration:compoundCaptionPackageId:insertPosition: |
Insert a compound caption. More... | |
(BOOL) | - removeCaptureCompoundCaption: |
Removes a certain capture compound caption indicated by its index. More... | |
(void) | - removeAllCaptureCompoundCaption |
Removes all capture compound caption. More... | |
(unsigned int) | - getCaptureCompoundCaptionCount |
Gets the count of capture compound caption. More... | |
(NvsCaptureCompoundCaption *) | - getCaptureCompoundCaptionByIndex: |
Gets a certain capture compound caption. More... | |
(NvsCaptureCaption *) | - appendCaptureCaption:offsetTime:duration:captionStylePackageId: |
Appends a caption. More... | |
(NvsCaptureCaption *) | - insertCaptureCaption:offsetTime:duration:captionStylePackageId:insertPosition: |
Insert a caption. More... | |
(NvsCaptureCaption *) | - appendCaptureModularCaption:offsetTime:duration: |
Appends a modular caption. More... | |
(NvsCaptureCaption *) | - insertCaptureModularCaption:offsetTime:duration:insertPosition: |
Insert a modular caption. More... | |
(BOOL) | - removeCaptureCaption: |
Removes a certain capture caption indicated by its index. More... | |
(void) | - removeAllCaptureCaption |
Removes all capture caption. More... | |
(unsigned int) | - getCaptureCaptionCount |
Gets the count of capture caption. More... | |
(NvsCaptureCaption *) | - getCaptureCaptionByIndex: |
Gets a certain capture caption. More... | |
(BOOL) | - applyCaptureScene: |
Apply a capture scene resource package to the capture device. More... | |
(BOOL) | - applyCaptureScene:captureSceneInfo: |
Apply a capture scene resource package to the capture device. More... | |
(NSString *) | - getCurrentCaptureSceneId |
Gets the ID of the current capture scene resource package. More... | |
(void) | - removeCurrentCaptureScene |
Removes the current capture scene. More... | |
(BOOL) | - startRecording: |
Starts recording. Please refer to Method of Recording Video. More... | |
(BOOL) | - startRecording:withFlags: |
Starts recording. Please refer to Method of Recording Video. More... | |
(BOOL) | - startRecording:withFlags:withRecordConfigurations: |
Starts recording. Please refer to Method of Recording Video. More... | |
(BOOL) | - startRecordingWithFx: |
Starts to record, and the recorded content contains all the special effects which applied. More... | |
(BOOL) | - startRecordingWithFx:withFlags: |
Starts to record, and the recorded content contains all the special effects which applied. More... | |
(BOOL) | - startRecordingWithFx:withFlags:withRecordConfigurations: |
Starts recording. Please refer to Method of Recording Video. More... | |
(void) | - setAudioSampleInfoForCallback: |
Set audio sample information for callback of capturing. More... | |
(void) | - stopRecording |
Stops recording. More... | |
(BOOL) | - pauseRecording |
Pause to record. Resuming recording after a pause will output the recorded video to the same file. Note: Recording can only be paused without using the built-in recorder! More... | |
(BOOL) | - resumeRecording |
Continues to record. Continuing recording will output the recorded video to the same media file, to which the recording before suspend outputs contents. More... | |
(BOOL) | - isRecordingPaused |
Checks if the recording has been paused. More... | |
(BOOL) | - takePicture: |
take a picture with the max resolution of camera which matches the preview resolution best More... | |
(NSArray *) | - getAllBuiltinVideoFxNames |
Gets the list of all built-in video effect names. More... | |
(NSArray *) | - getAllBuiltinAudioFxNames |
Gets the list of all built-in audio effect names. More... | |
(NSArray *) | - getAllBuiltinVideoTransitionNames |
Gets the list of all built-in video transitions’ names. More... | |
(NSArray *) | - getAllBuiltinCaptureVideoFxNames |
Gets the list of all built-in capture video effects’ names. More... | |
(NSString *) | - getBeautyVideoFxName |
Gets the name of beauty effect. More... | |
(NSString *) | - getDefaultVideoTransitionName |
Gets the default video transition’s name. More... | |
(void) | - setDefaultAudioTransitionName: |
Sets the default audio transition’s name. More... | |
(NvsFxDescription *) | - getVideoFxDescription: |
Gets the description of a video effect. More... | |
(NvsFxDescription *) | - getAudioFxDescription: |
Gets the description of an audio effect. More... | |
(NvsVideoFrameRetriever *) | - createVideoFrameRetriever: |
Creates an object of video frame retriever. More... | |
(NvsStreamingContext *) | - createAuxiliaryStreamingContext: |
Creates an object of auxiliary streaming context. More... | |
(void) | - destoryAuxiliaryStreamingContext: |
destory auxiliary streaming context. More... | |
(void) | - setAudioOutputDeviceVolume: |
set volume to audio output device. More... | |
(void) | - setCaptureFps: |
set camera device capture fps. More... | |
(void) | - setImageReaderCount: |
set image reader count. More... | |
(void) | - setDefaultImageClipDuration: |
Sets the default image clip duration. More... | |
(long) | - calcDurationAfterCurvesVariableSpeed: |
calc the duration after use curves variable speed.note: the origin duration is the curves's last endpoint.x-first endpoint.x More... | |
(BOOL) | - isBlackFrame: |
check the image is a black image or not. More... | |
(BOOL) | - getAECEnabled |
Get whether AEC(Acoustic Echo Cancellation) is enabled. More... | |
(void) | - setAECEnabled: |
Set whether to enable AEC(Acoustic Echo Cancellation).Note: Each time you startCapturePreview, this will be set to off, which means that if you want to use echo cancellation, you will need to enable it again after each preview. More... | |
Class Methods | |
(void) | + getSdkVersion:minorVersion:revisionNumber: |
Gets the version information of Meishe SDK. More... | |
(void) | + setDebugLevel: |
Sets Debug level. More... | |
(void) | + setSaveDebugMessagesToFile: |
Sets whether to write debugging information of the SDK to the file. More... | |
(BOOL) | + verifySdkLicenseFile: |
Verifies the SDK license file. Note: The license file interface must be called before the NvsStreamingContext is initialized. More... | |
(NvsStreamingContext *) | + sharedInstance |
Gets a unique instance of the streaming context. More... | |
(NvsStreamingContext *) | + sharedInstanceWithFlags: |
Gets a unique instance of the streaming context. For details, please refer to 4k Video Editing. More... | |
(void) | + destroyInstance |
Destroys the streaming context instance. More... | |
(int) | + hasARModule |
Checks if the current SDK contains an AR module. More... | |
(BOOL) | + initHumanDetection:licenseFilePath:features: |
Initializes the human body detection mechanism.Only once needed. More... | |
(BOOL) | + initHumanDetectionExt:licenseFilePath:features: |
Human detection initialization extension. must called after initHumanDetection. More... | |
(BOOL) | + setupHumanDetectionData:dataFilePath: |
Initializes human detection data packets. More... | |
(void) | + closeHumanDetection |
Close the human detection mechanism. More... | |
(NSString *) | + getLogFileDirectory |
Gets the directory path of log file. More... | |
(BOOL) | + functionalityAuthorised: |
Verifies whether a feature is available or not. More... | |
(void) | + setSpecialCameraDeviceType: |
set special camera device type to sdk. More... | |
(void) | + setMaxCafCacheMemorySize: |
set the maximum cache for CAF. More... | |
(void) | + setMaxImageReaderCount: |
set max image reader count. More... | |
(void) | + setFxPluginBundlePathList: |
set the path of the effects plug-in. More... | |
(void) | + setMaxAudioReaderCount: |
set max audio reader count. More... | |
(void) | + setMaxReaderCount: |
set max file reader count. More... | |
(void) | + setMaxSoftReaderCount: |
set max soft file reader count. More... | |
(void) | + setMaxIconReaderCount: |
set max icon reader count. More... | |
(void) | + setStreamingPoolSizeInByte: |
set max image reader count. More... | |
(void) | + setMaxEditCaptionCachedContextCount: |
Set the maximum number of caption context cached during editing. More... | |
(void) | + setMaxCompileCaptionCachedContextCount: |
Set the maximum number of caption context cached during compile. More... | |
Properties | |
id< NvsStreamingContextDelegate > | delegate |
NvsAssetPackageManager * | assetPackageManager |
Package manager. More... | |
float | compileVideoBitrateMultiplier |
Bitrate multiplier of compiling video. More... | |
float | recordVideoBitrateMultiplier |
Bitrate multiplier of recording video. More... | |
BOOL | defaultCaptionFade |
Whether the default caption effect is fade in and out. More... | |
id< NvsImageGrabberDelegate > | imageGrabberDelegate |
NSMutableDictionary * | compileConfigurations |
Sets the timeline configurations, which stay valid once set. For key values in NSMutableDictionary, please refer to Configuration of Compilation Timeline For instance: NSMutableDictionary *config = [[NSMutableDictionary alloc] init]; [config setValue:[NSNumber numberWithInteger:15] forKey:NVS_COMPILE_GOP_SIZE]; //If set to 1 then a I-frame-only video is compiled. [config setValue:[NSNumber numberWithInteger:10000000] forKey:NVS_COMPILE_BITRATE]; // 10M bps [config setValue:[NSNumber numberWithInteger:256000] forKey:NVS_COMPILE_AUDIO_BITRATE]; // Sets the audio bitrate to 256Kbps [config setValue:[NSNumber numberWithBool:YES] forKey:NVS_COMPILE_LOSSLESS_AUDIO]; //Sets to generate lossless audio [config setValue:[NSNumber numberWithBool:YES] forKey:NVS_COMPILE_OPTIMIZE_FOR_NETWORK_USE]; //Sets index table to prepose _streamingContext.compileConfigurations = config; Cancels configurations and returns to default settings:[_streamingContext.compileConfigurations setValue:nil forKey:NVS_COMPILE_GOP_SIZE];. More... | |
Streaming context.
The streaming context class is considered as the entry of the entire SDK framework. During development, the NvsStreamingContext class uses the static sharedInstance (NvsStreamingContext) interface to create an unique streaming context instance. Through this instantce object, we can turn on the recording device to record videos, adding effects to recorded videos, set various parameters for recording, which include autofocus, automatic exposure adjustment, swtiching on/off of the light supplement and so on. Meanwhile, this instance can also create timelines, connecting timelines to the real-time preview window which view the recorded videos in real-time. When the whole video has been produced completely, please destroy the instances of streaming context. When recording with special effects,users have to first install the package and obtain packageID after installation,before adding resources packages (recording effects package, scene resources package and so on),. For built-in special effects, users only need to obtain the name of the effect when using it.
In SDK interfaces, users need to use the full pathway when importing resources or authorizations.
- (NvsCaptureAnimatedSticker *) addCustomCaptureAnimatedSticker: | (int64_t) | inPoint | |
duration: | (int64_t) | duration | |
animatedStickerPackageId: | (NSString *) | animatedStickerPackageId | |
customImagePath: | (NSString *) | customImagePath | |
Add a custom animated sticker on capture.
inPoint | The in point of custom animated sticker on the timeline (in microseconds) |
duration | The duration of custom animation sticker which displayed (in microseconds) |
animatedStickerPackageId | Animated sticker package Id |
customImagePath | Path of custom animated sticker image(It can be a jpg, png image, or a dynamic caf format image supported by Meishe sdk) |
- (NvsCaptureVideoFx *) appendBeautyCaptureVideoFx |
Appends a beauty effect.
- (NvsCaptureAudioFx *) appendBuiltinCaptureAudioFx: | (NSString *) | audioFxName |
Appends a built-in capture audio effect.
audioFxName | audio effect name. To get the audio effect name, please refer to getAllBuiltinCaptureAudioFxNames() or The List of Built-in Effect Name. |
- (NvsCaptureVideoFx *) appendBuiltinCaptureVideoFx: | (NSString *) | videoFxName |
Appends a built-in capture video effect.
videoFxName | Video effect name. To get the video effect name, please refer to getAllBuiltinCaptureVideoFxNames() or The List of Built-in Effect Name. |
- (NvsCaptureAnimatedSticker *) appendCaptureAnimatedSticker: | (int64_t) | offsetTime | |
duration: | (int64_t) | duration | |
animatedStickerPackageId: | (NSString *) | animatedStickerPackageId | |
Appends a animated sticker.
offsetTime | animated sticker's offset time. |
duration | animated sticker's duration. |
animatedStickerPackageId | Animated sticker package Id. |
- (NvsCaptureCaption *) appendCaptureCaption: | (NSString *) | captionText | |
offsetTime: | (int64_t) | offsetTime | |
duration: | (int64_t) | duration | |
captionStylePackageId: | (NSString *) | captionStylePackageId | |
Appends a caption.
captionText | Text of caption |
offsetTime | catpion's offset time. |
duration | catpion's duration. |
captionStylePackageId | Caption style package Id.If it does not exist, you can pass an empty string or null. |
- (NvsCaptureCompoundCaption *) appendCaptureCompoundCaption: | (int64_t) | offsetTime | |
duration: | (int64_t) | duration | |
compoundCaptionPackageId: | (NSString *) | compoundCaptionPackageId | |
Appends a compound caption.
offsetTime | compound catpion's offset time. |
duration | compound catpion's duration. |
compoundCaptionPackageId | Caption style package Id.If it does not exist, you can pass an empty string or null. |
- (NvsCaptureCaption *) appendCaptureModularCaption: | (NSString *) | captionText | |
offsetTime: | (int64_t) | offsetTime | |
duration: | (int64_t) | duration | |
Appends a modular caption.
captionText | Text of caption |
offsetTime | catpion's offset time. |
duration | catpion's duration. |
- (NvsCaptureVideoFx *) appendCustomCaptureVideoFx: | (id< NvsCustomVideoFxRenderer >) | customVideoFxRender |
Appends a custom capture video effect.
customVideoFxRender | Interface of user-implemented custom video effect renderer |
- (NvsCaptureVideoFx *) appendPackagedCaptureVideoFx: | (NSString *) | videoFxPackageId |
Appends a package capture effectx.
videoFxPackageId | Video effect package ID |
- (BOOL) applyCaptureScene: | (NSString *) | captureSceneId |
Apply a capture scene resource package to the capture device.
captureSceneId | The ID of capture scene resource package |
- (BOOL) applyCaptureScene: | (NSString *) | captureSceneId | |
captureSceneInfo: | (NvsCaptureSceneInfo *) | info | |
Apply a capture scene resource package to the capture device.
captureSceneId | The ID of capture scene resource package |
info | Resource information to be replaced |
- (long) calcDurationAfterCurvesVariableSpeed: | (NSString *) | curvesString |
calc the duration after use curves variable speed.note: the origin duration is the curves's last endpoint.x-first endpoint.x
curvesString | description of the variable speed curves. \string foramt : (endpoint1)(endpoint1.backward)(endpoint1.frontward)(endpoint2)(endpoint2.backward)(endpoint2.frontward)…… \coords foramt : (x,y) \note1 : the y coords means the multiple speed. the range of y is 0.1 to 10 \note2 : all x coord values cannot be repeated. endpoint1.backward.x < endpoint1.x < endpoint1.frontward.x < endpoint2.backward.x <endpoint2.x…… \note3 : if you set an empty curvesString,it means you want to disable curves variable speed,the clip will back to const speed. \eg : curvesString = "(0,1)(-3,1)(3,1)(7,5)(6,5)(8,5)(10,0.4)(9,0.4)(11,0.4)(17,0.4)(16,0.4)(18,0.4)(20,5)(19,5)(21,5)(27,1)(24,1)(30,1)" curvesString included 6 group end point info . |
返回经过曲线变速后的时长。注:原始时长为曲线段中尾端点与首端点X坐标值之差
curvesString | 贝塞尔曲线描述字符串 \字符串格式:(端点1坐标)(端点1后控制点坐标)(端点1前控制点坐标)(端点2坐标)(端点2后控制点坐标)(端点2前控制点坐标)(端点3坐标)(端点3后控制点坐标)(端点3前控制点坐标)…… \坐标格式:(坐标X值,坐标Y值) \注1:Y坐标为播放倍速值,范围在0.1-10之间。 \注2:每个端点及控制点的X坐标必须不能相等。大小规定为:端点1后控制点的X坐标 < 端点1的X坐标 <端点1的前控制点的X坐标 < 端点2后控制点的X坐标 < 端点2的X坐标…… \注3:如果设置的curvesString为空字符串,则表示对该片段取消之前的曲线变速,恢复到匀速状态。 \例如:curvesString = "(0,1)(-3,1)(3,1)(7,5)(6,5)(8,5)(10,0.4)(9,0.4)(11,0.4)(17,0.4)(16,0.4)(18,0.4)(20,5)(19,5)(21,5)(27,1)(24,1)(30,1)"包含了6组端点及其控制点坐标信息。 |
- (void) cancelAutoFocus |
Cancels the ongoing autofocus.
- (unsigned int) captureDeviceCount |
Count of captureing devices.
- (void) clearCachedResources: | (BOOL) | asynchronous |
Clears the cached resources.
asynchronous | Whether it's Asynchronous or not. |
- (void) clearCachedResources: | (BOOL) | asynchronous | |
flags: | (int) | flags | |
Clears the cached resources.
asynchronous | Whether it's Asynchronous or not. |
+ (void) closeHumanDetection |
Close the human detection mechanism.
- (BOOL) compilePassthroughTimeline: | (NvsTimeline *) | timeline | |
outputFilePath: | (NSString *) | outputFilePath | |
compileConfigurations: | (NSMutableDictionary *) | configurations | |
flags: | (int) | flags | |
Compile passthrough the video clips on video track 0 in the timeline into a file without processing filter, multi track and nested timeline. If there are photos, it will fail.
timeline | Timeline |
outputFilePath | The path of output file. |
configurations | the timeline configurations,only supports NVS_COMPILE_CREATION_TIME, NVS_COMPILE_OPTIMIZE_FOR_NETWORK_USE, NVS_COMPILE_METADATADESCRIPTION |
flags | Special flags for output file. If there is no special requirements please input 0. |
- (BOOL) compileTimeline: | (NvsTimeline *) | timeline | |
startTime: | (int64_t) | startTime | |
endTime: | (int64_t) | endTime | |
outputFilePath: | (NSString *) | outputFilePath | |
videoResolutionGrade: | (NvsCompileVideoResolutionGrade) | videoResolutionGrade | |
videoBitrateGrade: | (NvsCompileVideoBitrateGrade) | videoBitrateGrade | |
compileConfigurations: | (NSMutableDictionary *) | compileConfigurations | |
flags: | (int) | flags | |
Compiles the video files by the timeline.
timeline | Timeline |
startTime | Start time (in microseconds). The start time value ranges from [0, timeline.duration - 1], and other values are invalid. |
endTime | End time (in microseconds). The value of endTime is in (startTime, timeline.duration], and the other values are invalid. |
outputFilePath | The output video file path. Note: Currently only .mov format is supported. |
videoResolutionGrade | Resolution level of video output. |
videoBitrateGrade | The bitrate of the video output. The video output bitrate level is divided into low bitrate, medium bitrate, and high bitrate. The specific bitrate of video compiled is correlated with compiled file's resolution. Taking a 1280*720 pixels video for example, the approximate bitrates are as follows: Bitrates for NvsCompileBitrateGradeLow, NvsCompileBitrateGradeMedium, NvsCompileBitrateGradeHigh are 2.2Mbps, 3.3Mbps and 6Mbps separately.s |
configurations | the timeline configurations. For key values in NSMutableDictionary please refer to Configuration of compiling timeline |
flags | Special flag for video output (temporarily set to 0 only).Please refer to NvsStreamingEngineCompileFlag] (NvsStreamingEngineCompileFlag). |
- (BOOL) compileTimeline: | (NvsTimeline *) | timeline | |
startTime: | (int64_t) | startTime | |
endTime: | (int64_t) | endTime | |
outputFilePath: | (NSString *) | outputFilePath | |
videoResolutionGrade: | (NvsCompileVideoResolutionGrade) | videoResolutionGrade | |
videoBitrateGrade: | (NvsCompileVideoBitrateGrade) | videoBitrateGrade | |
flags: | (int) | flags | |
Compiles the video files by the timeline.
timeline | Timeline |
startTime | Start time (in microseconds). The start time value ranges from [0, timeline.duration - 1], and other values are invalid. |
endTime | End time (in microseconds). The value of endTime is in (startTime, timeline.duration], and the other values are invalid. |
outputFilePath | The output video file path. Note: Currently only .mov format is supported. |
videoResolutionGrade | Resolution level of video output. |
videoBitrateGrade | The bitrate of the video output. The video output bitrate level is divided into low bitrate, medium bitrate, and high bitrate. The specific bitrate of video compiled is correlated with compiled file's resolution. Taking a 1280*720 pixels video for example, the approximate bitrates are as follows: Bitrates for NvsCompileBitrateGradeLow, NvsCompileBitrateGradeMedium, NvsCompileBitrateGradeHigh are 2.2Mbps, 3.3Mbps and 6Mbps separately.s |
flags | Special flag for video output (temporarily set to 0 only).Please refer to NvsStreamingEngineCompileFlag] (NvsStreamingEngineCompileFlag). |
- (BOOL) connectCapturePreviewWithLiveWindow: | (NvsLiveWindow *) | liveWindow |
Connects the captured preview with live window.
liveWindow | Live window for previewing |
- (BOOL) connectCapturePreviewWithVideoFrameReceiver: | (NvsVideoFrameReceiver *) | receiver |
Connects the captured preview with video frame receiver.
receiver | Video frame receiver |
- (BOOL) connectTimeline: | (NvsTimeline *) | timeline | |
withLiveWindow: | (NvsLiveWindow *) | liveWindow | |
Connects timeline with live window.
timeline | Timeline |
liveWindow | Live window |
- (BOOL) connectTimeline: | (NvsTimeline *) | timeline | |
withVideoFrameReceiver: | (NvsVideoFrameReceiver *) | receiver | |
Connects timeline with video frame receiver.
timeline | Timeline |
receiver | Video frame receiver |
- (NvsStreamingContext *) createAuxiliaryStreamingContext: | (int) | flags |
Creates an object of auxiliary streaming context.
lags | Flag field. If there is no special requirement, please fill in 0. |
- (NvsTimeline *) createTimeline: | (NSString *) | templateId | |
templateFootages: | (NSArray< NvsTemplateFootageInfo * > *) | templateFootages | |
Creates timeline.
templateId | template uuid |
templateFootages | footage information in the template asset |
- (NvsTimeline *) createTimeline: | (NSString *) | templateId | |
templateFootages: | (NSArray< NvsTemplateFootageInfo * > *) | templateFootages | |
flags: | (int) | flags | |
Creates timeline.
templateId | template uuid |
templateFootages | footage information in the template asset |
flags | Special flags for create timeline. If there is no special requirements please input 0. Please refer to NvsCreateTimelineTypeFlag. |
- (NvsTimeline *) createTimeline: | (NSString *) | templateId | |
templateFootages: | (NSArray< NvsTemplateFootageInfo * > *) | templateFootages | |
flags: | (int) | flags | |
videoFps: | (NvsRational *) | videoFps | |
audioEditRes: | (NvsAudioResolution *) | audioEditRes | |
Creates timeline.
templateId | template uuid,template must be installed firstly |
templateFootages | footage information in the template asset |
flags | Special flags for create timeline. If there is no special requirements please input 0. Please refer to create timeline flag. |
videoFps | Frame rate |
audioEditRes | Audio file's resolution(specified file sampling rate, sampling format and number of channels. For audio editting resolution, imported audio only supports two types of sampling rate, 44100 or 48000.) |
- (NvsTimeline *) createTimeline: | (NvsVideoResolution *) | videoEditRes | |
videoFps: | (NvsRational *) | videoFps | |
audioEditRes: | (NvsAudioResolution *) | audioEditRes | |
Creates timeline.
videoEditRes | Video file's resolution (specify the width,height and ratio). For video editting resolution, when importing corresponding params, the imported image's width has to be a multiple of 4, the height has to be a multiple of 2. Note: if one creates NvsStreamingContext's instance that supports 4K video editting, then video editting's resolution cannot be higher then 3840*2160(imageWidth*imageHeight), otherwise the imageWidth*imageHeight cannot exceed 1920* 1080 pixels. |
videoFps | Video frame rate, max fps is 60 |
audioEditRes | Audio editing resolution (specify the sampling rate, sampling format, and count of channels). For audio editing resolution, the incoming sample rate values support two types: 44100 and 48000.and support mono&stereo |
- (NvsTimeline *) createTimeline: | (NvsVideoResolution *) | videoEditRes | |
videoFps: | (NvsRational *) | videoFps | |
audioEditRes: | (NvsAudioResolution *) | audioEditRes | |
bitDepth: | (NvsVideoResolutionBitDepth) | depth | |
flags: | (int) | flags | |
Creates timeline.
videoEditRes | Video file's resolution (specify the width,height and ratio). For video editting resolution, when importing corresponding params, the imported image's width has to be a multiple of 4, the height has to be a multiple of 2. Note: if one creates NvsStreamingContext's instance that supports 4K video editting, then video editting's resolution cannot be higher then 3840*2160(imageWidth*imageHeight), otherwise the imageWidth*imageHeight cannot exceed 1920* 1080 pixels. |
videoFps | Video frame rate, max fps is 60 |
audioEditRes | Audio editing resolution (specify the sampling rate, sampling format, and count of channels). For audio editing resolution, the incoming sample rate values support two types: 44100 and 48000.and support mono&stereo |
flags | Special flags for create timeline. If there is no special requirements please input 0. Please refer to NvsCreateTimelineTypeFlag. |
- (NvsTimeline *) createTimeline: | (NvsVideoResolution *) | videoEditRes | |
videoFps: | (NvsRational *) | videoFps | |
audioEditRes: | (NvsAudioResolution *) | audioEditRes | |
flags: | (int) | flags | |
Creates timeline.
videoEditRes | Video file's resolution (specify the width,height and ratio). For video editting resolution, when importing corresponding params, the imported image's width has to be a multiple of 4, the height has to be a multiple of 2. Note: if one creates NvsStreamingContext's instance that supports 4K video editting, then video editting's resolution cannot be higher then 3840*2160(imageWidth*imageHeight), otherwise the imageWidth*imageHeight cannot exceed 1920* 1080 pixels. |
videoFps | Video frame rate, max fps is 60 |
audioEditRes | Audio editing resolution (specify the sampling rate, sampling format, and count of channels). For audio editing resolution, the incoming sample rate values support two types: 44100 and 48000.and support mono&stereo |
flags | Special flags for create timeline. If there is no special requirements please input 0. Please refer to NvsCreateTimelineTypeFlag. |
- (NvsVideoFrameRetriever *) createVideoFrameRetriever: | (NSString *) | videoFilePath |
Creates an object of video frame retriever.
videoFilePath | Path of the original video |
- (void) destoryAuxiliaryStreamingContext: | (NvsStreamingContext *) | auxContext |
destory auxiliary streaming context.
NvsStreamingContext. | destoryed auxiliary streaming context |
+ (void) destroyInstance |
Destroys the streaming context instance.
- (float) detectEngineRenderFramePerSecond |
Get the current rendering speed of the engine from the streaming context that it's only valid after startCapturePreview and playbackTimeline.
- (int) detectVideoFileKeyframeInterval: | (NSString *) | videoFilePath |
Detects the I frame interval of video files.
videoFilePath | Video file path |
- (BOOL) exportProjectInfo: | (NSString *) | projectUuid | |
timeline: | (NvsTimeline *) | timeline | |
requestedAspectRatio: | (int) | requestedAspectRatio | |
Export project information.
projectUuid | Project resource package ID |
timeline | Timeline Object |
requestedAspectRatio | Aspect ratio of project according to timeline。please refer to Aspect ratio supported by the resource package |
- (BOOL) exportTemplateInfo: | (NSString *) | templateUuid | |
timeline: | (NvsTimeline *) | timeline | |
requestedAspectRatio: | (int) | requestedAspectRatio | |
Export template information.
templateUuid | Template resource package ID |
timeline | Timeline Object |
requestedAspectRatio | Aspect ratio of template according to timeline。please refer to Aspect ratio supported by the resource package |
+ (BOOL) functionalityAuthorised: | (NSString *) | sdkFunctionName |
Verifies whether a feature is available or not.
sdkFunctionName | The name of the SDK’s function |
- (BOOL) generateProjectPackage: | (NSString *) | projectUuid | |
innerAssetDir: | (NSString *) | innerAssetDir | |
projectOutputDir: | (NSString *) | projectOutputDir | |
Generate project asset package.
projectUuid | project resource package ID |
innerAssetDir | Path of internal assets of project |
projectOutputDir | Output path of project asset package |
- (BOOL) generateTemplatePackage: | (NSString *) | templateUuid | |
innerAssetDir: | (NSString *) | innerAssetDir | |
templateOutputDir: | (NSString *) | templateOutputDir | |
Generate template asset package.
templateUuid | Template resource package ID |
innerAssetDir | Path of internal assets of template |
templateOutputDir | Output path of template asset package |
- (BOOL) getAECEnabled |
Get whether AEC(Acoustic Echo Cancellation) is enabled.
- (NSArray *) getAllBuiltinAudioFxNames |
Gets the list of all built-in audio effect names.
- (NSArray *) getAllBuiltinCaptureVideoFxNames |
Gets the list of all built-in capture video effects’ names.
- (NSArray *) getAllBuiltinVideoFxNames |
Gets the list of all built-in video effect names.
- (NSArray *) getAllBuiltinVideoTransitionNames |
Gets the list of all built-in video transitions’ names.
- (NvsFxDescription *) getAudioFxDescription: | (NSString *) | fxName |
Gets the description of an audio effect.
fxName | Audio effect’s name |
- (NvsAVFileInfo *) getAVFileInfo: | (NSString *) | avFilePath |
Gets audio and video informations of a file.
avFilePath | File path |
- (NvsAVFileInfo *) getAVFileInfo: | (NSString *) | avFilePath | |
extraFlag: | (int) | extraFlag | |
withError: | (NSMutableString *) | errString | |
Gets detailed information of the audio/video file.
avFilePath | File path of the audio/video file |
extraFlag | Get extra information of the audio/video file. please refer to AV_FILEINFO_EXTRA |
errString | Output param for error description is valid if current function return null. |
- (NvsAVFileInfo *) getAVFileInfoExtra: | (NSString *) | avFilePath | |
extraFlag: | (int) | extraFlag | |
Gets audio and video information of a file.
avFilePath | File path |
extraFlag | Special flag for Audio and video information. Please refer to Special identifier when acquiring audio and video information.. |
- (NSString *) getBeautyVideoFxName |
Gets the name of beauty effect.
- (NvsCaptureAnimatedSticker *) getCaptureAnimatedStickerByIndex: | (unsigned int) | captureStikcerIndex |
Gets a certain capture animated sticker.
captureStikcerIndex | audio effect index |
- (unsigned int) getCaptureAnimatedStickerCount |
Gets the count of capture animated sticker.
- (NvsCaptureAudioFx *) getCaptureAudioFxByIndex: | (unsigned int) | captureAudioFxIndex |
Gets a certain capture audio effect.
captureVideoFxIndex | audio effect index |
- (unsigned int) getCaptureAudioFxCount |
Gets the count of audio effects.
- (NvsCaptureCaption *) getCaptureCaptionByIndex: | (unsigned int) | captureCaptionIndex |
Gets a certain capture caption.
captureCaptionIndex | caption index |
- (unsigned int) getCaptureCaptionCount |
Gets the count of capture caption.
- (NvsCaptureCompoundCaption *) getCaptureCompoundCaptionByIndex: | (unsigned int) | captureCaptionIndex |
Gets a certain capture compound caption.
captureCaptionIndex | compound caption index |
- (unsigned int) getCaptureCompoundCaptionCount |
Gets the count of capture compound caption.
- (NvsCaptureDeviceCapability *) getCaptureDeviceCapability: | (unsigned int) | catpureDeviceIndex |
Obtains the capability description object of the capture device.
catpureDeviceIndex | Index of capturing device |
- (NvsSize) getCapturePreviewVideoSize: | (unsigned int) | catpureDeviceIndex |
Gets the capture preview resolution.
catpureDeviceIndex | Index of capturing device |
- (NvsCaptureVideoFx *) getCaptureVideoFxByIndex: | (unsigned int) | captureVideoFxIndex |
Gets a certain capture video effect.
captureVideoFxIndex | Video effect index |
- (unsigned int) getCaptureVideoFxCount |
Gets the count of video effects.
- (float) getColorGainForSDRToHDR |
gets the color gain during SDR to HDR conversion.
- (NSString *) getCurrentCaptureSceneId |
Gets the ID of the current capture scene resource package.
- (unsigned int) getCustomCompileVideoHeight |
Gets the custom video height.
- (NSString *) getDefaultThemeEndingLogoImageFilePath |
Gets the default theme logo image path.
- (NSString *) getDefaultVideoTransitionName |
Gets the default video transition’s name.
- (EAGLSharegroup *) getEAGLSharegroup |
Gets the EAGLSharegroup object used by the engine from the streaming context.
- (int) getEngineHDRCaps |
Get HDR capability.
- (float) getExposureBias |
- (NvsCameraFlashMode) getFlashMode |
get state of the flash light.
- (NSArray*) getFontInfoByFilePath: | (NSString *) | fontFilePath |
Gets font file's font information.
fontFilePath | Font file path |
+ (NSString *) getLogFileDirectory |
Gets the directory path of log file.
+ (void) getSdkVersion: | (int *) | majorVersion | |
minorVersion: | (int *) | minorVersion | |
revisionNumber: | (int *) | revisionNumber | |
Gets the version information of Meishe SDK.
majorVersion | Major version number |
minorVersion | Minor version number |
revisionNumber | Revision number |
- (NvsStreamingEngineState) getStreamingEngineState |
Gets the engine state.
- (int64_t) getTimelineCurrentPosition: | (NvsTimeline *) | timeline |
Gets the current position of the timeline (in microseconds).
timeline | Timeline |
- (NvsFxDescription *) getVideoFxDescription: | (NSString *) | fxName |
Gets the description of a video effect.
fxName | Video effect’s name |
- (VideoStabilizationFlag) getVideoStabilization |
Gets the current video’s stabilization flag.
- (float) getZoomFactor |
- (UIImage *) grabImageFromTimeline: | (NvsTimeline *) | timeline | |
timestamp: | (int64_t) | timestamp | |
proxyScale: | (const NvsRational *) | proxyScale | |
Gets the image in the timeline of a certain timestamp. For details, refer to The Topic of Video Frame Image Extraction.
timeline | The timeline object which gets the image |
timestamp | The timestamp (in microseconds) for the image. The range of timestamp is [0, timeline.duration - 1]. Other values are invalid, and grabImageFromTimeline will return nil. |
proxyScale | Proxy scale.Setting nil indicates the default ratio of 1:1. |
- (UIImage *) grabImageFromTimeline: | (NvsTimeline *) | timeline | |
timestamp: | (int64_t) | timestamp | |
proxyScale: | (const NvsRational *) | proxyScale | |
flags: | (int) | flags | |
Gets the image in the timeline of a certain timestamp. For details, refer to The Topic of Video Frame Image Extraction.
timeline | The timeline object which gets the image |
timestamp | The timestamp (in microseconds) for the image. The range of timestamp is [0, timeline.duration - 1]. Other values are invalid, and grabImageFromTimeline will return nil. |
proxyScale | Proxy scale.Setting nil indicates the default ratio of 1:1. |
flags | Special flag for seeking engine. Please refer to NvsStreamingEngineSeekFlag. |
- (BOOL) grabImageFromTimelineAsync: | (NvsTimeline *) | timeline | |
timestamp: | (int64_t) | timestamp | |
proxyScale: | (const NvsRational *) | proxyScale | |
flags: | (int) | flags | |
Gets the specific frame in timeline with a specific timestamp. For details please refer to The video frame retriever. This function is an internal asynchronous call. It is necessary to ensure that SeekTimeline () will not be invoked before getting the image. If the function that calls SeekTimeline after calling this function may not get the callback of the image, it can call Stop after this function to ensure that the Grab image can be executed successfully.
timeline | The timeline that will be grabbed from. |
timestamp | The desired frame's timestamp(in microseconds). Timestamp should be within range [0,timeline.duration - 1]. Other inputs are invalid and will results grabImageFromTimeline returns null. |
proxyScale | Zoom scale of proxy |
flags | Flags for streaming engine seeking. For specific please refer to The seek flag of streaming engine. |
+ (int) hasARModule |
Checks if the current SDK contains an AR module.
+ (BOOL) initHumanDetection: | (NSString *) | modelFilePath | |
licenseFilePath: | (NSString *) | licenseFilePath | |
features: | (int) | features | |
Initializes the human body detection mechanism.Only once needed.
modelFilePath | Path of the model file |
licenseFilePath | Path of the license file |
features | human detection flag field. Please refer to Flag of human detection. |
+ (BOOL) initHumanDetectionExt: | (NSString *) | modelFilePath | |
licenseFilePath: | (NSString *) | licenseFilePath | |
features: | (int) | features | |
Human detection initialization extension. must called after initHumanDetection.
modelFilePath | Path of the model file |
licenseFilePath | Path of the license file |
features | human detection flag field. Please refer to Flag of human detection. |
- (NvsCaptureVideoFx *) insertBeautyCaptureVideoFx: | (unsigned int) | insertPosition |
Inserts a skin beauty video effect.
insertPosition | Insertion position |
- (NvsCaptureAudioFx *) insertBuiltinCaptureAudioFx: | (NSString *) | audioFxName | |
withInsertPosition: | (unsigned int) | insertPosition | |
Inserts a built-in audio capture effect.
audioFxName | audio effect name. To get the audio effect name, please refer to getAllBuiltinCaptureAudioFxNames() or The List of Built-in Effect Name. |
insertPosition | Insertion position. |
- (NvsCaptureVideoFx *) insertBuiltinCaptureVideoFx: | (NSString *) | videoFxName | |
withInsertPosition: | (unsigned int) | insertPosition | |
Inserts a built-in video capture effect.
videoFxName | Video effect name. To get the video effect name, please refer to getAllBuiltinCaptureVideoFxNames() or The List of Built-in Effect Name. |
insertPosition | Insertion position. |
- (NvsCaptureAnimatedSticker *) insertCaptureAnimatedSticker: | (int64_t) | offsetTime | |
duration: | (int64_t) | duration | |
animatedStickerPackageId: | (NSString *) | animatedStickerPackageId | |
insertPosition: | (unsigned int) | insertPosition | |
Appends a animated sticker.
offsetTime | animated sticker's offset time. |
duration | animated sticker's duration. |
animatedStickerPackageId | Animated sticker package Id. |
insertPosition | Insertion position. |
- (NvsCaptureCaption *) insertCaptureCaption: | (NSString *) | captionText | |
offsetTime: | (int64_t) | offsetTime | |
duration: | (int64_t) | duration | |
captionStylePackageId: | (NSString *) | captionStylePackageId | |
insertPosition: | (unsigned int) | insertPosition | |
Insert a caption.
captionText | Text of caption |
offsetTime | catpion's offset time. |
duration | catpion's duration. |
captionStylePackageId | Caption style package Id.If it does not exist, you can pass an empty string or null. |
insertPosition | Insertion position. |
- (NvsCaptureCompoundCaption *) insertCaptureCompoundCaption: | (int64_t) | offsetTime | |
duration: | (int64_t) | duration | |
compoundCaptionPackageId: | (NSString *) | compoundCaptionPackageId | |
insertPosition: | (unsigned int) | insertPosition | |
Insert a compound caption.
offsetTime | compound catpion's offset time. |
duration | compound catpion's duration. |
compoundCaptionPackageId | Caption style package Id.If it does not exist, you can pass an empty string or null. |
insertPosition | Insertion position. |
- (NvsCaptureCaption *) insertCaptureModularCaption: | (NSString *) | captionText | |
offsetTime: | (int64_t) | offsetTime | |
duration: | (int64_t) | duration | |
insertPosition: | (unsigned int) | insertPosition | |
Insert a modular caption.
captionText | Text of caption |
offsetTime | catpion's offset time. |
duration | catpion's duration. |
insertPosition | Insertion position. |
- (NvsCaptureAnimatedSticker *) insertCustomCaptureAnimatedSticker: | (int64_t) | offsetTime | |
duration: | (int64_t) | duration | |
animatedStickerPackageId: | (NSString *) | animatedStickerPackageId | |
customImagePath: | (NSString *) | customImagePath | |
insertPosition: | (unsigned int) | insertPosition | |
Insert a animated sticker.
offsetTime | animated sticker's offset time. |
duration | animated sticker's duration. |
animatedStickerPackageId | Animated sticker package Id. |
customImagePath | Path of custom animated sticker image(It can be a jpg, png image, or a dynamic caf format image supported by Meishe sdk) |
insertPosition | Insertion position. |
- (NvsCaptureVideoFx *) insertCustomCaptureVideoFx: | (id< NvsCustomVideoFxRenderer >) | customVideoFxRender | |
withInsertPosition: | (int) | insertPosition | |
Inserts a custom capture video effect.
customVideoFxRender | Interface of user-implemented custom video effect renderer |
insertPosition | Insertion position |
- (NvsCaptureVideoFx *) insertPackagedCaptureVideoFx: | (NSString *) | videoFxPackageId | |
withInsertPosition: | (unsigned int) | insertPosition | |
Inserts a package capture effect.
videoFxPackageId | Video effect package ID |
insertPosition | Insertion position |
- (BOOL) isBlackFrame: | (UIImage *) | image |
check the image is a black image or not.
the | image to be checked |
- (BOOL) isCaptureDeviceBackFacing: | (unsigned int) | catpureDeviceIndex |
Whether it's a rear capturing device.
catpureDeviceIndex | Index of capturing device |
- (BOOL) isCompilingPaused |
Check if compiling timeline is paused.
- (BOOL) isFlashOn |
get state of the flash light.
- (BOOL) isPlaybackPaused |
Check if playback timeline is paused.
- (BOOL) isRecordingPaused |
Checks if the recording has been paused.
- (NvsTimeline *) loadProject: | (NSString *) | projectId | |
resourceDir: | (NSString *) | resourceDir | |
Creates timeline.
projectId | project uuid |
resourceDir | Path of assets of project |
- (BOOL) pauseCompiling |
Pause compiling timeline.
- (BOOL) pausePlayback |
Pause playback timeline.
- (BOOL) pauseRecording |
Pause to record. Resuming recording after a pause will output the recorded video to the same file. Note: Recording can only be paused without using the built-in recorder!
- (BOOL) playbackTimeline: | (NvsTimeline *) | timeline | |
startTime: | (int64_t) | startTime | |
endTime: | (int64_t) | endTime | |
proxyScale: | (const NvsRational *) | proxyScale | |
preload: | (BOOL) | preload | |
flags: | (int) | flags | |
Playback timeline.
timeline | Timeline |
startTime | Start time (in microseconds). The value range of startTime is [0, timeline.duration - 1]. Any other value is invalid, and the playbackTimeline will return NO, resulting in startuping unsuccessfully for the playback video. |
endTime | End time (in microseconds). If the input endTime value is negative, it will play to the end of the video by default. |
proxyScale | Proxy scale |
preload | Whether it preloads or not |
flags | Special flag for previewing. If there is no special need, please fill in 0. Please refer to NvsStreamingEnginePlaybackFlag. |
- (BOOL) playbackTimeline: | (NvsTimeline *) | timeline | |
startTime: | (int64_t) | startTime | |
endTime: | (int64_t) | endTime | |
videoSizeMode: | (NvsVideoPreviewSizeMode) | videoSizeMode | |
preload: | (BOOL) | preload | |
flags: | (int) | flags | |
Playback timeline.
timeline | Timeline |
startTime | Start time (in microseconds). The value range of startTime is [0, timeline.duration - 1]. Any other value is invalid, and the playbackTimeline will return NO, resulting in startuping unsuccessfully for the playback video. |
endTime | End time (in microseconds). If the input endTime value is negative, it will play to the end of the video by default. |
videoSizeMode | Mode of previewing image |
preload | Whether it preloads or not |
flags | Special flag for previewing. If there is no special need, please fill in 0. Please refer to NvsStreamingEnginePlaybackFlag. |
- (BOOL) preloadEffectResources |
Preload effect resources.
- (NSString*) registerFontByFilePath: | (NSString *) | fontFilePath |
Gets the fontFamily of the font file.
fontFilePath | Font file path |
- (void) removeAllCaptureAnimatedSticker |
Removes all capture animated sticker.
- (void) removeAllCaptureAudioFx |
Removes all capture audio effects.
- (void) removeAllCaptureCaption |
Removes all capture caption.
- (void) removeAllCaptureCompoundCaption |
Removes all capture compound caption.
- (void) removeAllCaptureVideoFx |
Removes all capture video effects.
- (BOOL) removeCaptureAnimatedSticker: | (unsigned int) | captureAnimagedStickerIndex |
Removes a certain capture animated sticker indicated by its index.
captureAnimagedStickerIndex | animated sticker index |
- (BOOL) removeCaptureAudioFx: | (unsigned int) | captureAudioFxIndex |
Removes a certain capture audio effect indicated by its index.
captureAudioFxIndex | audio effect index |
- (BOOL) removeCaptureCaption: | (unsigned int) | captureCaptionIndex |
Removes a certain capture caption indicated by its index.
captureCaptionIndex | caption index |
- (BOOL) removeCaptureCompoundCaption: | (unsigned int) | captureCompoundCaptionIndex |
Removes a certain capture compound caption indicated by its index.
captureCompoundCaptionIndex | compound caption index |
- (BOOL) removeCaptureVideoFx: | (unsigned int) | captureVideoFxIndex |
Removes a certain capture video effect indicated by its index.
captureVideoFxIndex | Video effect index |
- (void) removeCurrentCaptureScene |
Removes the current capture scene.
- (BOOL) removeTimeline: | (NvsTimeline *) | timeline |
Removes timeline.
timeline | The timeline which will be removed |
- (void) removeUserWatermarkForCapture |
Removes custom watermark which added for capturing video.
- (BOOL) resumeCompiling |
Resume compiling timeline.
- (BOOL) resumePlayback |
Resume playback timeline.
- (BOOL) resumeRecording |
Continues to record. Continuing recording will output the recorded video to the same media file, to which the recording before suspend outputs contents.
- (NvsColor) sampleColorFromCapturedVideoFrame: | (CGRect) | sampleRect |
Samples the capture device's video frame.
sampleRect | Rectangular area to sample, of which coordinates are in livewindow's coordinate system |
- (BOOL) seekTimeline: | (NvsTimeline *) | timeline | |
timestamp: | (int64_t) | timestamp | |
proxyScale: | (const NvsRational *) | proxyScale | |
flags: | (int) | flags | |
Seeks to a certain timestamp of images.
timeline | Timeline |
timestamp | Timestamp (in microseconds). The range of timestamp value is [0, timeline.duration - 1]. And any other input value is invalid, seekTimeline will return No, resulting in seek failure. |
proxyScale | Proxy scale value |
flags | Special seek flag for engine. Please refer to NvsStreamingEngineSeekFlag |
- (BOOL) seekTimeline: | (NvsTimeline *) | timeline | |
timestamp: | (int64_t) | timestamp | |
videoSizeMode: | (NvsVideoPreviewSizeMode) | videoSizeMode | |
flags: | (int) | flags | |
Seeks to a certain timestamp of images.
timeline | Timeline |
timestamp | Timestamp (in microseconds). The range of timestamp value is [0, timeline.duration - 1]. And any other input value is invalid, seekTimeline will return No, resulting in seek failure. |
videoSizeMode | Mode of previewing image |
flags | Special seek flag for engine. Please refer to NvsStreamingEngineSeekFlag |
- (BOOL) sendAudioSamplesToCapturePreview: | (CMSampleBufferRef) | data |
Transfers the input buffer to capture preivew.
data | Data and information of the input buffer. Only NV12 format is supported. |
- (BOOL) sendBufferToCapturePreview: | (const NvsVideoFrameInfo *) | data |
Transfers the input buffer to capture preivew.
data | Data and information of the input buffer. Only NV12 format is supported. |
- (void) setAECEnabled: | (BOOL) | enable |
Set whether to enable AEC(Acoustic Echo Cancellation).Note: Each time you startCapturePreview, this will be set to off, which means that if you want to use echo cancellation, you will need to enable it again after each preview.
whether | to enable AEC. |
- (void) setAudioOutputDeviceVolume: | (float) | volume |
set volume to audio output device.
volume | new volume to device, value range[0, 1] |
- (void) setAudioSampleInfoForCallback: | (NvsCapturedAudioSampleInfo *) | info |
Set audio sample information for callback of capturing.
info | audio sample information |
- (void) setAudioVUMeterEnabled: | (BOOL) | enable |
Enable DB value of audio output.
enable | Enable |
- (void) setCaptureFps: | (int) | fps |
set camera device capture fps.
fps | the frame count of per second |
- (void) setColorGainForSDRToHDR: | (float) | gain |
Sets the color gain during SDR to HDR conversion.
gain | color gain. range is [1.0, 10.0] |
- (void) setCustomCompileVideoHeight: | (unsigned int) | videoHeight |
Sets the customized height for video.
When compiling videos, set the bitrate grade for compiled video to COMPILE_VIDEO_RESOLUTION_GRADE_CUSTOM. Plesae note, to make sure the file is compiled successfully, Meishe SDK would calibrate the height accordingly, thus the final output file may not necessarily be the height set here.
videoHeight | Custom height of the compiled video |
+ (void) setDebugLevel: | (NvsDebugLevel) | debugLevel |
Sets Debug level.
debugLevel | debug‘s level. |
- (void) setDefaultAudioTransitionName: | (NSString *) | name |
Sets the default audio transition’s name.
name | audio transition’s name |
- (void) setDefaultImageClipDuration: | (int64_t) | defaultImageClipDuration |
Sets the default image clip duration.
bitmap. | image clip duration |
- (BOOL) setDefaultThemeEndingLogoImageFilePath: | (NSString *) | logoImageFilePath |
Sets the default theme logo image path.
logoImageFilePath | Path of logo image file |
- (void) setEnableAudioSampleNotify: | (BOOL) | enable |
Enable DB value of audio output.
enable | Enable |
- (void) setExposureBias: | (float) | exposureBias |
Set exposure compensation.
exposureBias | Exposure compensation value |
+ (void) setFxPluginBundlePathList: | (NSArray *) | list |
set the path of the effects plug-in.
effects | plug-in path array |
- (void) setImageReaderCount: | ("Use +setMaxImageReaderCount:") | ||
(macos(10.3, 10.11)) | |||
(ios(7.0, 8.0)) | API_DEPRECATED | ||
set image reader count.
count | the image reader |
+ (void) setMaxAudioReaderCount: | (int) | count |
set max audio reader count.
max | count the audio reader |
+ (void) setMaxCafCacheMemorySize: | (int) | maxMemorySize |
set the maximum cache for CAF.
maxMemorySize | maximum cache |
+ (void) setMaxCompileCaptionCachedContextCount: | (int) | count |
Set the maximum number of caption context cached during compile.
Maximum | number of cached caption contexts |
+ (void) setMaxEditCaptionCachedContextCount: | (int) | count |
Set the maximum number of caption context cached during editing.
Maximum | number of cached caption contexts |
+ (void) setMaxIconReaderCount: | (int) | count |
set max icon reader count.
max | count the icon reader |
+ (void) setMaxImageReaderCount: | (int) | count |
set max image reader count.
count | the max image reader |
+ (void) setMaxReaderCount: | (int) | count |
set max file reader count.
max | count the file reader |
+ (void) setMaxSoftReaderCount: | (int) | count |
set max soft file reader count.
max | count the soft file reader |
+ (void) setSaveDebugMessagesToFile: | (BOOL) | saveDebugMessagesToFile |
Sets whether to write debugging information of the SDK to the file.
saveDebugMessagesToFile | Whether to write debugging information of the SDK to the file.In the /Library/Application Support/log/ path, a file will be generated every day, for example:meishesdklog(2023-01-17).log. If you need to delete the file, you need to delete this directory by yourself, and the Meishesdk will not delete it actively. |
+ (void) setSpecialCameraDeviceType: | (NSString *) | specialCameraType |
set special camera device type to sdk.
specialCameraType | special device type |
+ (void) setStreamingPoolSizeInByte: | (int) | maxMemorySize |
set max image reader count.
count | the max image reader |
- (void) setTemplate: | (NSString *) | templateUuid | |
customResourceDir: | (NSString *) | customResourceDir | |
set templates custom resource folders
templateUuid | template resource package ID |
innerAssetDir | Path of assets of project/template |
- (BOOL) setThemeEndingEnabled: | (BOOL) | enable |
Sets whether the logo effect at the end of the theme is displayed or not.
+ (BOOL) setupHumanDetectionData: | (int) | dataType | |
dataFilePath: | (NSString *) | dataFilePath | |
Initializes human detection data packets.
dataType | Type of human detection packet. Please refer to Type of human detection packete |
dataFilePath | Path of the data file |
- (void) setUserWatermarkForCapture: | (NSString *) | watermarkFilePath | |
displayWidth: | (int) | displayWidth | |
displayHeight: | (int) | displayHeight | |
opacity: | (float) | opacity | |
position: | (NvsTimelineWatermarkPosition) | position | |
marginX: | (int) | marginX | |
marginY: | (int) | marginY | |
Adds a custom watermark for capturing video.
watermarkFilePath | Path of the watermark file, which should be a .PNG or .JPG file. |
displayWidth | The width of the watermark displayed in the preview. If it is 0, the original width of the image is used. |
displayHeight | The height of the watermark displayed in the preview. If it is 0, the original height of the image is used. |
opacity | Watermark opacity, the range of which is 0~1 |
position | Position of the watermark, please refer to NvsTimelineWatermarkPosition. |
marginX | Watermark horizontal margin |
marginY | Watermark vertical margin |
- (void) setVideoStabilization: | (VideoStabilizationFlag) | flags |
- (void) setZoomFactor: | (float) | zoomFactor |
+ (NvsStreamingContext *) sharedInstance |
Gets a unique instance of the streaming context.
+ (NvsStreamingContext *) sharedInstanceWithFlags: | (NvsStreamingContextFlag) | flags |
Gets a unique instance of the streaming context. For details, please refer to 4k Video Editing.
flags | Flag field. If there is no special requirement, please fill in 0. |
- (void) startAutoExposure: | (CGPoint) | pointOfInterest |
Starts automatic exposure adjustment.
pointOfInterest | Exposure adjustment point |
- (void) startAutoFocus: | (CGPoint) | focusPointOfInterest |
Starts autofocus.
focusPointOfInterest | The target area for autofocus, of which coordinates are in live-window's coordinate system |
- (BOOL) startBufferCapturePreview: | (unsigned int) | width | |
height: | (unsigned int) | height | |
fps: | (const NvsRational *) | fps | |
rotation: | (int) | rotation | |
flipHorizontally: | (BOOL) | flipHorizontally | |
Starts the capture preview with inputting buffer mode.
width | Input buffer width. |
height | Input buffer height. |
fps | Input buffer framerate. |
rotation | Input buffer rotation angle. Please refer to Image rotation angle of input buffer |
flipHorizontally | whether to flip the buffer horizontally. |
- (BOOL) startCapturePreview: | (unsigned int) | captureDeviceIndex | |
videoResGrade: | (NvsVideoCaptureResolutionGrade) | videoResGrade | |
flags: | (int) | flags | |
aspectRatio: | (const NvsRational *) | aspectRatio | |
Starts the capture preview.
captureDeviceIndex | Index of the capture device |
videoResGrade | Video capture resolution level. The video resolution is defined by the short side (width or height) of the captured video. Value of the other side (width or height) is calculated according to the video aspect ratio (nil means the aspect ratio will be determined by the system capture device). It includes three levels, namely low, medium and high, the front camera corresponds to 480P, 540P, 720P, and the rear camera corresponds to 540P, 720P, 1080P. If the user wants to customize the recording resolution, such as 540*960 pixels, then it will need to record a video with equal aspect ratio, create a timeline with aspect ratio of 540*960 and compile it to file. When compiling, there is no grade corresponding to a height of 960p, thus the user needs to call setCustomCompileVideoHeight() to customize the height before compilation. Then call compileTimeline(), and the compiled level should be set to NvsCompileVideoResolutionGradeCustom. The example code is as follows: NvsVideoResolution videoEditRes; videoEditRes.imageWidth = 540; videoEditRes.imageHeight = 960; videoEditRes.imagePAR = (NvsRational){1, 1}; NvsRational videoFps = {25, 1}; NvsAudioResolution audioEditRes; audioEditRes.sampleRate = 48000; audioEditRes.channelCount = 2; audioEditRes.sampleFormat = NvsAudSmpFmt_S16; self.timeline = [_context createTimeline:&videoEditRes videoFps:&videoFps audioEditRes:&audioEditRes]; [_context setCustomCompileVideoHeight:960]; [self.context compileTimeline:self.timeline startTime:0 endTime:self.timeline.duration outputFilePath:videoPath videoResolutionGrade:NvsCompileVideoResolutionGradeCustom videoBitrateGrade:NvsCompileBitrateGradeMedium flags:0]; |
flags | Flag field, if there is no special requirement, please fill in 0. Please refer to NvsStreamingEngineCaptureFlag. The application scene for each flag is as follows: NvsStreamingEngineCaptureFlag_GrabCapturedVideoFrame which is used in grabing video frame; NvsStreamingEngineCaptureFlag_StrictPreviewVideoSize is used for face detection combination with NvsStreamingEngineCaptureFlag_CaptureBuddyHostVideoFrame; NvsStreamingEngineCaptureFlag_DontCaptureAudio Used for live video without audio stream. Usually not used. |
aspectRatio | Aspect ratio for previewing, setting nil means that it will be determined by the system capture device. |
- (void) startContinuousFocus |
Starts continuous focus.
- (BOOL) startRecording: | (NSString *) | outputFilePath |
Starts recording. Please refer to Method of Recording Video.
outputFilePath | The path to the recording file. Note: .mov is recommended as the output format. |
- (BOOL) startRecording: | (NSString *) | outputFilePath | |
withFlags: | (int) | flags | |
Starts recording. Please refer to Method of Recording Video.
outputFilePath | The path to the recording file. Note: .mov is recommended as the output format. |
flags | Flag field, if there is no special requirement, please fill in 0. Please refer to NvsStreamingEngineRecordingFlag |
- (BOOL) startRecording: | (NSString *) | outputFilePath | |
withFlags: | (int) | flags | |
withRecordConfigurations: | (NSMutableDictionary *) | withRecordConfigurations | |
Starts recording. Please refer to Method of Recording Video.
outputFilePath | The path to the recording file. Note: .mov is recommended as the output format. |
flags | Flag field, if there is no special requirement, please fill in 0. Please refer to NvsStreamingEngineRecordingFlag |
withRecordConfigurations | Recording configuration. For the key values in NSMutableDictionary, please refer to Recording Video Configuration: For instance:NSMutableDictionary *config = [[NSMutableDictionary alloc] init]; [config setValue:[NSNumber numberWithInteger:15] forKey:NVS_RECORD_GOP_SIZE]; // setting 1 means it will generate an I-frame video. [config setValue:[NSNumber numberWithInteger:10000000] forKey:NVS_RECORD_BITRATE]; // 10M bps |
- (BOOL) startRecordingWithFx: | (NSString *) | outputFilePath |
Starts to record, and the recorded content contains all the special effects which applied.
Note: If the effect processed is too complicated, it may cause the recorded video to drop frames. Therefore, users must be careful when using this method. Make sure that the effects can be processed in real time for the current phone. Please refer to Method of Recording Video.
outputFilePath | The path to the recording file. Note: .mov is recommended as the output format. |
- (BOOL) startRecordingWithFx: | (NSString *) | outputFilePath | |
withFlags: | (int) | flags | |
Starts to record, and the recorded content contains all the special effects which applied.
Note: If the effect processed is too complicated, it may cause the recorded video to drop frames. Therefore, users must be careful when using this method. Make sure that the effects can be processed in real time for the current phone. Please refer to Method of Recording Video.
outputFilePath | The path to the recording file. Note: .mov is recommended as the output format. |
flags | Flag field, if there is no special requirement, please fill in 0. Please refer to NvsStreamingEngineRecordingFlag |
- (BOOL) startRecordingWithFx: | (NSString *) | outputFilePath | |
withFlags: | (int) | flags | |
withRecordConfigurations: | (NSMutableDictionary *) | withRecordConfigurations | |
Starts recording. Please refer to Method of Recording Video.
outputFilePath | The path to the recording file. Note: .mov is recommended as the output format. |
flags | Flag field, if there is no special requirement, please fill in 0. Please refer to NvsStreamingEngineRecordingFlag |
withRecordConfigurations | Recording configuration. For the key values in NSMutableDictionary, please refer to Recording Video Configuration: For instance:NSMutableDictionary *config = [[NSMutableDictionary alloc] init]; [config setValue:[NSNumber numberWithInteger:15] forKey:NVS_RECORD_GOP_SIZE]; // setting 1 means it will generate an I-frame video. [config setValue:[NSNumber numberWithInteger:10000000] forKey:NVS_RECORD_BITRATE]; // 10M bps |
- (void) stop |
Stops the engine.
- (void) stop: | (int) | flags |
tops the engine
flags | Flag of stopping the engine. Please refer to NvsStreamingEngineStopFlag. |
- (void) stopRecording |
Stops recording.
- (BOOL) takePicture: | (int) | flags |
take a picture with the max resolution of camera which matches the preview resolution best
flags | take picture flag. value is 0 |
- (void) toggleFlash: | (BOOL) | on |
Sets which the flash light is on/off.
on | whether the flash light is on or not |
- (void) toggleFlashMode: | (NvsCameraFlashMode) | mode |
Sets the flash mode.
mode | flash mode value, please refer to Flash Mode |
+ (BOOL) verifySdkLicenseFile: | (NSString *) | sdkLicenseFilePath |
Verifies the SDK license file. Note: The license file interface must be called before the NvsStreamingContext is initialized.
sdkLicenseFilePath | Path of SDK license file |
|
readatomicassign |
Package manager.
|
readwritenonatomicassign |
Sets the timeline configurations, which stay valid once set. For key values in NSMutableDictionary, please refer to Configuration of Compilation Timeline For instance: NSMutableDictionary *config = [[NSMutableDictionary alloc] init]; [config setValue:[NSNumber numberWithInteger:15] forKey:NVS_COMPILE_GOP_SIZE]; //If set to 1 then a I-frame-only video is compiled. [config setValue:[NSNumber numberWithInteger:10000000] forKey:NVS_COMPILE_BITRATE]; // 10M bps [config setValue:[NSNumber numberWithInteger:256000] forKey:NVS_COMPILE_AUDIO_BITRATE]; // Sets the audio bitrate to 256Kbps [config setValue:[NSNumber numberWithBool:YES] forKey:NVS_COMPILE_LOSSLESS_AUDIO]; //Sets to generate lossless audio [config setValue:[NSNumber numberWithBool:YES] forKey:NVS_COMPILE_OPTIMIZE_FOR_NETWORK_USE]; //Sets index table to prepose _streamingContext.compileConfigurations = config; Cancels configurations and returns to default settings:[_streamingContext.compileConfigurations setValue:nil forKey:NVS_COMPILE_GOP_SIZE];.
|
readwritenonatomicassign |
Bitrate multiplier of compiling video.
|
readwritenonatomicassign |
Whether the default caption effect is fade in and out.
|
readwritenonatomicweak |
|
readwritenonatomicweak |
|
readwritenonatomicassign |
Bitrate multiplier of recording video.