BBASMPlugin+VideoPicker.h 1.82 KB
//
//  BBASMPlugin+Video.h
//  SWAN
//
//  Created by baidu on 2018/4/25.
//  Copyright © 2018年 baidu. All rights reserved.
//

#import "BBASMPlugin.h"

@interface BBASMPlugin (VideoPicker)

/**
 * 描  述: 拍摄视频或从手机相册中选视频,返回视频的临时文件路径。
 * 示  例: baiduboxapp://swanAPI/chooseVideo?params=$params&callback=$callback
 * 文  档: http://ft.baidu.com/#/scheme/swan_choosevideo
 * 备  注:
 * ********** description ************
 * @name:      chooseVideo
 * @authority: swanAPI
 * @path:      /chooseVideo
 * @args:      [{"name": "camera", "value": "string="}, {"name": "cb", "value": "string"}, {"name": "sourceType", "value": "string[]="}, {"name": "compressed", "value": "boolean="}, {"name": "maxDuration", "value": "string="}]
 * @config:    {"swan": {"web": {"invoke": "swan.message.url", "handler": "bridge"}, "webdegrade": {"invoke": "swan.message.url", "handler": "bridge"}, "jsc": {"invoke": "swan.method.url", "method": "_naSwan.bridge.postMessage"}}}
 */
- (void)chooseVideo:(BBASchemeDispatcher *)dispatcher;

/**
 * 描  述: 保存视频到系统相册
 * 示  例: baiduboxapp://swanAPI/saveVideoToPhotosAlbum?params={"filePath":"bdfile://tmp_57176fef6c6db8d99c112c3d0fd53db0.mp4","cb":"_bdbox_pjs_72"}&callback=_bdbox_js_85&upgrade=0
 * 文  档: http://ft.baidu.com/#/scheme/swan_savevideotophotosalbum
 * 备  注:
 * ********** description ************
 * @name:      saveVideoToPhotosAlbum
 * @authority: swanAPI
 * @path:      /saveVideoToPhotosAlbum
 * @args:      [{"name": "filePath", "value": "string"}, {"name": "cb", "value": "string"}]
 * @config:    {"swan": {"web": {"invoke": "swan.message.url", "handler": "bridge"}, "jsc": {"invoke": "swan.method.url", "method": "_naSwan.bridge.postMessage"}}}
 */
- (void)saveVideoToPhotosAlbum:(BBASchemeDispatcher *)dispatcher;

@end