diff --git a/APIDiffs/api-diffs-3.2.1.md b/APIDiffs/api-diffs-3.2.1.md new file mode 100644 index 00000000..e0c566ee --- /dev/null +++ b/APIDiffs/api-diffs-3.2.1.md @@ -0,0 +1,14 @@ +# PLShortVideoKit 3.2.0 to 3.2.1 API Differences + +## General Headers + +`PLShortVideoRecorder.h` + +- *Added* + +```objc +- (nonnull instancetype)initWithVideoConfiguration:(PLSVideoConfiguration *__nonnull)videoConfiguration + audioConfiguration:(PLSAudioConfiguration *__nonnull)audioConfiguration + videoCaptureEnabled:(BOOL)videoCaptureEnabled + audioCaptureEnabled:(BOOL)audioCaptureEnabled; +``` \ No newline at end of file diff --git a/PLShortVideoKit-Advanced.podspec b/PLShortVideoKit-Advanced.podspec index fee27982..b4514f83 100644 --- a/PLShortVideoKit-Advanced.podspec +++ b/PLShortVideoKit-Advanced.podspec @@ -9,12 +9,12 @@ Pod::Spec.new do |s| s.name = "PLShortVideoKit" - s.version = "3.2.0" + s.version = "3.2.1" s.summary = "PILI iOS short video record SDK" s.homepage = "https://github.com/pili-engineering/PLShortVideoKit" s.license = "Apache License 2.0" s.author = { "pili" => "pili@qiniu.com" } - s.source = { :http => "https://sdk-release.qnsdk.com/PLShortVideoKit-advanced-v3.2.0.zip"} + s.source = { :http => "https://sdk-release.qnsdk.com/PLShortVideoKit-advanced-v#{s.version}.zip"} s.platform = :ios s.requires_arc = true diff --git a/PLShortVideoKit-Basic.podspec b/PLShortVideoKit-Basic.podspec index c9d412ac..6cc2dd1d 100644 --- a/PLShortVideoKit-Basic.podspec +++ b/PLShortVideoKit-Basic.podspec @@ -9,12 +9,12 @@ Pod::Spec.new do |s| s.name = "PLShortVideoKit" - s.version = "3.2.0" + s.version = "3.2.1" s.summary = "PILI iOS short video record SDK" s.homepage = "https://github.com/pili-engineering/PLShortVideoKit" s.license = "Apache License 2.0" s.author = { "pili" => "pili@qiniu.com" } - s.source = { :http => "https://sdk-release.qnsdk.com/PLShortVideoKit-basic-v3.2.0.zip"} + s.source = { :http => "https://sdk-release.qnsdk.com/PLShortVideoKit-basic-v#{s.version}.zip"} s.platform = :ios s.requires_arc = true diff --git a/PLShortVideoKit-Smart.podspec b/PLShortVideoKit-Smart.podspec index a08f1af1..ef762673 100644 --- a/PLShortVideoKit-Smart.podspec +++ b/PLShortVideoKit-Smart.podspec @@ -9,12 +9,12 @@ Pod::Spec.new do |s| s.name = "PLShortVideoKit" - s.version = "3.2.0" + s.version = "3.2.1" s.summary = "PILI iOS short video record SDK" s.homepage = "https://github.com/pili-engineering/PLShortVideoKit" s.license = "Apache License 2.0" s.author = { "pili" => "pili@qiniu.com" } - s.source = { :http => "https://sdk-release.qnsdk.com/PLShortVideoKit-smart-v3.2.0.zip"} + s.source = { :http => "https://sdk-release.qnsdk.com/PLShortVideoKit-smart-v#{s.version}.zip"} s.platform = :ios s.requires_arc = true diff --git a/PLShortVideoKit.podspec b/PLShortVideoKit.podspec index 0f8670dd..fea155f1 100644 --- a/PLShortVideoKit.podspec +++ b/PLShortVideoKit.podspec @@ -9,12 +9,12 @@ Pod::Spec.new do |s| s.name = "PLShortVideoKit" - s.version = "3.2.0" + s.version = "3.2.1" s.summary = "PILI iOS short video record SDK" s.homepage = "https://github.com/pili-engineering/PLShortVideoKit" s.license = "Apache License 2.0" s.author = { "pili" => "pili@qiniu.com" } - s.source = { :http => "https://sdk-release.qnsdk.com/PLShortVideoKit-profession-v3.2.0.zip"} + s.source = { :http => "https://sdk-release.qnsdk.com/PLShortVideoKit-profession-v#{s.version}.zip"} s.platform = :ios s.requires_arc = true diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSCVPixelBufferRotateProcessor.h b/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSCVPixelBufferRotateProcessor.h deleted file mode 100644 index 67f41e52..00000000 --- a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSCVPixelBufferRotateProcessor.h +++ /dev/null @@ -1,89 +0,0 @@ -// -// PLSCVPixelBufferRotateProcessor.h -// PLShortVideoKit -// -// Created by hxiongan on 2018/5/30. -// Copyright © 2018年 Pili Engineering, Qiniu Inc. All rights reserved. -// - -#import -#import -#import "PLSPixelBufferProcessor.h" -#import "PLSTypeDefines.h" - -/*! - @typedef PLSGLRotateProcessorType - @brief 旋转类型枚举值、每次只能设置其中的某一种情况,不能同时使用多种(比如不能设置 FlipVertical 了再叠加设置 Degree90,以最后设置的值为准) - */ -typedef enum : NSUInteger { - PLSGLRotateProcessorTypeNone, - PLSGLRotateProcessorTypeDegree90, - PLSGLRotateProcessorTypeDegree180, - PLSGLRotateProcessorTypeDegree270, - PLSGLRotateProcessorTypeFlipVertical, - PLSGLRotateProcessorTypeFlipHorizonal, -} PLSGLRotateProcessorType; - -/*! - @class PLSCVPixelBufferRotateProcessor - @brief 对 kCVPixelFormatType_32BGRA 格式图片进行旋转、缩放处理 - */ -@interface PLSCVPixelBufferRotateProcessor : NSObject - -/*! - @property rotateType - @brief 旋转类型 - - @warning 注意:如果设置为 PLSGLRotateProcessorTypeDegree90 或者 PLSGLRotateProcessorTypeDegree270, - 内部会自动调整一下 sourceRect,destRect 和 destFrameSize 的值。比如 destRect 设置为 {10, 30, 100, 200}, - 最终得到的结果为 {30, 10, 200, 100} - */ -@property (nonatomic, assign) PLSGLRotateProcessorType rotateType; - -/*! - @property aspectMode - @brief 当被裁剪的部分比例与在新图中需要安放的位置的比例不同时选择的填充模式 - */ -@property (nonatomic, assign) PLSVideoFillModeType aspectMode; - -/*! - @property sourceRect - @brief 需要从原始图片中裁剪出来的部分的位置和大小 - */ -@property (nonatomic, assign, readonly) CGRect sourceRect; - -/*! - @property destRect - @brief 裁剪出来的部分放置在新图之中的位置和大小 - */ -@property (nonatomic, assign, readonly) CGRect destRect; - -/*! - @property destFrameSize - @brief 新图的整体画幅大小 - */ -@property (nonatomic, assign, readonly) CGSize destFrameSize; - -/*! - @method setSourceRect:destRect:destFrameSize: - @brief 设置剪裁和缩放信息 - - @param sourceRect 需要从原始图片中裁剪出来的部分的位置和大小 - @param destRect 裁剪出来的部分放置在新图之中的位置和大小 - @param destFrameSize 新图的整体画幅大小 - */ -- (void)setSourceRect:(CGRect)sourceRect destRect:(CGRect)destRect destFrameSize:(CGSize)destFrameSize; - -/*! - @method process: - @brief 图片剪裁和缩放 - - @param pixelBuffer 待剪裁的原始图片 - - @return pixelBuffer 新的图片 - - @warning 使用该接口进行图像处理需要注意的是,为了保持图像处理的效率,减小开销,该类内部会持有一个 CVPixelBufferRef 并在每次都会返回该对象,因此在每次调用之后请确认对返回的数据已经使用完毕再进行下一次调用,否则会出现非预期的问题 - */ -- (CVPixelBufferRef)process:(CVPixelBufferRef)pixelBuffer; - -@end diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSGLKView.h b/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSGLKView.h deleted file mode 100644 index 48aba1b2..00000000 --- a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSGLKView.h +++ /dev/null @@ -1,72 +0,0 @@ -// -// PLSGLKView.h -// PLShortVideoKit -// -// Created by suntongmian on 17/3/1. -// Copyright © 2017年 Pili Engineering, Qiniu Inc. All rights reserved. -// - -#import -#import -#import -#import -#import "PLSTypeDefines.h" - -/*! - @typedef PLSGLKRotationMode. - @abstract 渲染的方向设置 - @since v1.0.0 - */ -typedef enum { - PLSGLKNoRotation, - PLSGLKRotateLeft, - PLSGLKRotateRight, - PLSGLKFlipVertical, - PLSGLKFlipHorizonal, - PLSGLKRotateRightFlipVertical, - PLSGLKRotateRightFlipHorizontal, - PLSGLKRotate180 -} PLSGLKRotationMode; - -/*! - @class PLSGLKView - @brief 视频渲染 View - */ -@interface PLSGLKView : UIView - -/*! - @property previewOrientation - @brief 视频渲染方向 - */ -@property (assign, nonatomic) PLSGLKRotationMode previewOrientation; - - /*! - @property fillMode - @brief 当视频宽高和渲染 View 宽高比例不一样的时候,填充模式 - */ -@property (nonatomic, assign) PLSVideoFillModeType fillMode; - -/*! - @property context - @brief 获取 OpenGL ES 上下文 - */ -@property (nonatomic, strong, readonly) EAGLContext *context; - -/*! - @method initWithFrame:eaglContext - @brief 带 OpenGL ES 上下文的初始化方法 - - @param frame frame - @param context OpenGL ES 上下文,如无特殊需求建议传 nil - */ -- (instancetype)initWithFrame:(CGRect)frame eaglContext:(EAGLContext *)context; - -/*! - @method displayPixelBuffer: - @brief 渲染视频帧 - - @param pixelBuffer 带渲染的视频帧,kCVPixelFormatType_32BGRA 格式 - */ -- (void)displayPixelBuffer:(CVPixelBufferRef)pixelBuffer; - -@end diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSImageRotateProcessor.h b/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSImageRotateProcessor.h deleted file mode 100644 index 2a57cb33..00000000 --- a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSImageRotateProcessor.h +++ /dev/null @@ -1,53 +0,0 @@ -// -// PLSImageRotateProcessor.h -// PLShortVideoKit -// -// Created by hxiongan on 2018/5/23. -// Copyright © 2018年 Pili Engineering, Qiniu Inc. All rights reserved. -// - -#import -#import -#import - -/*! - @class PLSImageRotateProcessor - @brief 图片旋转录制帧处理类. - */ -@interface PLSImageRotateProcessor : NSObject - -/*! - @property backgroundSize - @brief 返回最终生成图像的宽高. - */ -@property (nonatomic, readonly) CGSize backgroundSize; - -/*! - @property rotateFrame - @brief 设置旋转图片的位置和大小,(相对于 backgroundSize). - */ -@property (nonatomic, readonly) CGRect rotateFrame; - -/*! - @method setWantPixelSize:rotateFrame:backgroundPixelBuffer:rotatePixelBuffer: - @brief 设置渲染信息. - - @param videoSize 最后生成的 CVPixelBufferRef 的宽高,即就是 pixelBufferWithAngel:返回 pixelbuffer 的宽高. - @param rotateframe 旋转部分的frame,相对于 videoSize. - @param backgroundPixelBuffer 背景图片. - @param rotatePxielBuffer 旋转图片. - */ -- (void)setWantPixelSize:(CGSize)videoSize - rotateFrame:(CGRect)rotateframe - backgroundPixelBuffer:(CVPixelBufferRef __nonnull)backgroundPixelBuffer - rotatePixelBuffer:(CVPixelBufferRef __nonnull)rotatePxielBuffer; - -/*! - @method pixelBufferWithAngel: - @brief 传入一个角度,返回个旋转了 angle 的 buffer. - - @param angle 以弧度为单位的角度. - */ -- (CVPixelBufferRef __nullable)pixelBufferWithAngel:(float)angle; - -@end diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSPixelBufferProcessor.h b/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSPixelBufferProcessor.h deleted file mode 100644 index c7312dca..00000000 --- a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSPixelBufferProcessor.h +++ /dev/null @@ -1,88 +0,0 @@ -// -// PLSPixelBufferProcessor.h -// PLShortVideoKit -// -// Created by suntongmian on 17/3/1. -// Copyright © 2017年 Pili Engineering, Qiniu Inc. All rights reserved. -// - -#import -#import -#import - -/*! - @class PLSPixelBufferProcessor - @abstract PLSPixelBufferProcessor 用于对图像进行裁剪和缩放 - - @since v1.0.0 - */ -@interface PLSPixelBufferProcessor : NSObject - -/*! - @typedef PLSPixelAspectMode - - @brief 当被裁剪的部分比例与在新图中需要安放的位置的比例不同时选择的填充模式 - */ -typedef enum -{ - /// 保持原图比例并嵌入新图来填充 - PLSPixelAspectModeFit, - - /// 保持原图比例并将新图填充满 - PLSPixelAspectModeFill -} PLSPixelAspectMode; - -/*! - @property sourceRect - - @brief 需要从原始图片中裁剪出来的部分的位置和大小 - */ -@property (nonatomic, assign) CGRect sourceRect; - -/*! - @property destRect - - @brief 裁剪出来的部分放置在新图之中的位置和大小 - */ -@property (nonatomic, assign) CGRect destRect; - -/*! - @property destFrameSize - - @brief 新图的整体画幅大小 - */ -@property (nonatomic, assign) CGSize destFrameSize; - -/*! - @property aspectMode - - @brief 当被裁剪的部分比例与在新图中需要安放的位置的比例不同时选择的填充模式 - */ -@property (nonatomic, assign) PLSPixelAspectMode aspectMode; - -/*! - @method initWithSourceRect:destRect:destFrameSize:aspectMode - @brief 初始化一个 PLSPixelBufferProcessor 对象 - - @param sourceRect 需要从原始图片中裁剪出来的部分的位置和大小 - @param destRect 裁剪出来的部分放置在新图之中的位置和大小 - @param destFrameSize 新图的整体画幅大小 - @param aspectMode 当被裁剪的部分比例与在新图中需要安放的位置的比例不同时选择的填充模式 - - @return 初始化后的 PLSPixelBufferProcessor 对象 - */ -- (instancetype)initWithSourceRect:(CGRect)sourceRect destRect:(CGRect)destRect destFrameSize:(CGSize)destFrameSize aspectMode:(PLSPixelAspectMode)aspectMode; - -/*! - @method processPixelBuffer: - @brief 用于处理图像的接口 - - @param sourceBuffer 原始图片的对象 - - @return 处理之后的 CVPixelBufferRef 对象 - - @discussion 使用该接口进行图像处理需要注意的是,为了保持图像处理的效率,减小开销,该类内部会持有一个 CVPixelBufferRef 并在每次都会返回该对象,因此在每次调用之后请确认对返回的数据已经使用完毕再进行下一次调用,否则会出现非预期的问题 - */ -- (CVPixelBufferRef)processPixelBuffer:(CVPixelBufferRef)sourceBuffer; - -@end diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSTransitionAssetExport.h b/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSTransitionAssetExport.h deleted file mode 100644 index 206a63f3..00000000 --- a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSTransitionAssetExport.h +++ /dev/null @@ -1,42 +0,0 @@ -// -// PLSTransitionAssetExport.h -// PLShortVideoKit -// -// Created by hxiongan on 2018/1/23. -// Copyright © 2018年 Pili Engineering, Qiniu Inc. All rights reserved. -// - -#import -#import -#import "PLSTransition.h" -#import "PLSImageSetting.h" -#import "PLSTextSetting.h" - -/*! - @class PLSTransitionAssetExport - @brief 转场动画导出类 - */ -@interface PLSTransitionAssetExport : NSObject - -/*! - @property scale - @brief 设置背景视频和生成的视频的大小比例,用来调整文字或者图片在背景视屏中的相对位置和大小 - */ -@property (nonatomic, assign) CGFloat scale; - -- (void)addText:(PLSTextSetting *)textSetting transition:(NSArray *)transitions; - -- (void)addImage:(PLSImageSetting *)imageSetting transition:(NSArray *)transitions; - -- (void)startWithAsset:(AVAsset *)asset - outURL:(NSURL *)outURL - outPixelSize:(CGSize)outSize - totalDuration:(float)duration - frameRate:(float)frameRate - backgroundColor:(UIColor *)backgroundColor - progress:(void(^)(float progress))progressBlock - complete:(void(^)(bool isSucceed, NSError *error))completeBlock; - -- (void)cancelExport; - -@end diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSVideoMergeProcess.h b/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSVideoMergeProcess.h deleted file mode 100644 index b307b40e..00000000 --- a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSVideoMergeProcess.h +++ /dev/null @@ -1,139 +0,0 @@ -// -// PLSVideoMergeProcess.h -// PLShortVideoKit -// -// Created by hxiongan on 2018/4/26. -// Copyright © 2018年 Pili Engineering, Qiniu Inc. All rights reserved. -// - -#import -#import "PLSTypeDefines.h" -#import -#import -#import -#import - -#ifndef ARRAY_SIZE -#define ARRAY_SIZE(c_array) (sizeof((c_array))/sizeof((c_array)[0])) -#endif - -/*! - @define MAX_MIX_COUNT - @brief 单次支持的最大合并图片张数 - */ -#define MAX_MIX_COUNT 9 - -GLuint loaderShader(const char* strShaderDesc, GLenum shaderType); -GLuint createProgram(const char* strVertexDesc, const char* strFragmentDesc); - -/*! - class PLSVideoMergeProcess - @brief 多张图片合并,最大支持 9 张 - */ -@interface PLSVideoMergeProcess : NSObject -{ - EAGLContext *_context; - - GLuint _vbo_vertext; - GLuint _vbo_element; - - GLuint _vbo_textures[MAX_MIX_COUNT]; - CGSize _pixelBufferSizes[MAX_MIX_COUNT]; - CGRect _videoFrames[MAX_MIX_COUNT]; - - GLuint _watermark_vbo_texture; - - NSRecursiveLock *_lock; - - CGRect _waterMarkFrame; - UIImage *_waterMarkImage; - BOOL _waterMarkUpdate; -} - -/*! - @property destVideoSize - @brief 合并之后的图片大小 - */ -@property (nonatomic, readonly) CGSize destVideoSize; - - /*! - @method setWaterMark:waterMarkPosition: - @brief 设置水印 - - @param waterMark 水印图片 - @param position 水印左上角的顶点 - */ -- (void)setWaterMark:(UIImage *)waterMark waterMarkPosition:(CGPoint)position; - -/*! - @method setDestVideoSize: - @brief 设置合并之后的图片大小 - - @param destVideoSize 合并之后的图片大小 - */ -- (void)setDestVideoSize:(CGSize)destVideoSize; - -/*! - @method setVideoFrame:index: - @brief 设置合并图片的位置和大小 - - @param frame 图片的位置和大小 - @param index 图片的索引 - */ -- (void)setVideoFrame:(CGRect)frame index:(int)index; - -/*! - @method reloadTextCoorBuffer: - @brief 重新加载纹理顶点信息 - - @param index 设置的图片索引 - */ -- (void)reloadTextCoorBuffer:(int)index; - -/*! - @method mergeVideoWithPixelBuffers:count: - @brief 合并多张图片 - - @param pixelBuffer 多张图片数组的首图 - @param bufferCount 合并的图片张数 - - @return 返回由 pixelBuffer 中的图片合并之后的图片 - */ -- (CVPixelBufferRef)mergeVideoWithPixelBuffers:(CVPixelBufferRef *)pixelBuffer count:(int)bufferCount; - -/*! - @method lumaTextureForPixelBuffer:textureCache: - @brief 使用 luma 数据创建纹理 - - @param pixelBuffer NV12/I420 格式的 CVPixelBufferRef - @param textureCache TextureCache - - @return 返回由 pixelBuffer 中的 luma 数据创建得到的纹理 - */ -- (CVOpenGLESTextureRef)lumaTextureForPixelBuffer:(CVPixelBufferRef)pixelBuffer - textureCache:(CVOpenGLESTextureCacheRef)textureCache; - -/*! - @method chromaTextureForPixelBuffer:textureCache: - @brief 使用 chroma 数据创建纹理 - - @param pixelBuffer NV12 格式的 CVPixelBufferRef - @param textureCache TextureCache - - @return 返回由 pixelBuffer 中的 chroma 数据创建得到的纹理 - */ -- (CVOpenGLESTextureRef)chromaTextureForPixelBuffer:(CVPixelBufferRef)pixelBuffer - textureCache:(CVOpenGLESTextureCacheRef)textureChahe;; - -/*! - @method rgb32TextureForPixelBuffer:textureCache: - @brief 使用 32BGRA 数据创建纹理 - - @param pixelBuffer 32BGRA 格式的 CVPixelBufferRef - @param textureCache TextureCache - - @return 返回由 pixelBuffer 中的 BGRA 数据创建得到的纹理 - */ -- (CVOpenGLESTextureRef)rgb32TextureForPixelBuffer:(CVPixelBufferRef)pixelBuffer - textureCache:(CVOpenGLESTextureCacheRef)textureCache; -@end diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSWatermarkProcessor.h b/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSWatermarkProcessor.h deleted file mode 100644 index 59a92d2c..00000000 --- a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLSWatermarkProcessor.h +++ /dev/null @@ -1,84 +0,0 @@ -// -// PLSWatermarkProcessor.h -// PLShortVideoKit -// -// Created by suntongmian on 17/3/1. -// Copyright © 2017年 Pili Engineering, Qiniu Inc. All rights reserved. -// - -#import -#import -#import -#import "PLSTypeDefines.h" - -/*! - @class PLSWatermarkProcessor - @abstract PLSWatermarkProcessor 用于给 BGRA32 图像添加镜像和水印 - - @since v1.0.0 - */ -@interface PLSWatermarkProcessor : NSObject - -/*! - @method setWatermarkImage: - @brief 设置水印图片 - - @param image 水印图片,如果 image = nil,则表示移除水印 - */ -- (void)setWatermarkImage:(UIImage*)image; - -/*! - @method setWatermarkImage:alpha - @brief 设置水印图片 - - @param image 水印图片,如果 image = nil,则表示移除水印 - @param alpha 水印图片的 alpha 值 - */ -- (void)setWatermarkImage:(UIImage*)image alpha:(CGFloat)alpha; - -/*! - @method setGifWatermarkData:alpha:videoFrameRate: - @brief 设置 gif 水印数据 - - @param gifData gif 水印数据 - @param alpha 水印的 alpha 值 - @param videoFrameRate 视频的帧率 - - @warning gif 的帧率一般比视频的帧率低,因此内部会对 gif 进行插帧操作,需要设置的视频帧率接近真实的视频帧率,否则生成的视频会出现 gif 水印的播放比视频快或者慢 - */ -- (void)setGifWatermarkData:(NSData *)gifData alpha:(CGFloat)alpha videoFrameRate:(CGFloat)videoFrameRate; - -/*! - @method setWatermarkDisplaySize:position: - @brief 设置水印图片的大小,位置 - - @param size 水印的大小 - @param position 水印的位置 - - @warning 如果设置的水印宽高和水印图片的宽高不一致的时候,水印会被拉伸 - */ -- (void)setWatermarkDisplaySize:(CGSize)size position:(CGPoint)position; - -/*! - @method setWatermarkDisplaySize:position:rotateAngle - @brief 设置水印图片的大小,位置,旋转角度 - - @param angle 水印的旋转角度(单位:弧度) - - @see setWatermarkDisplaySize:position: - */ -- (void)setWatermarkDisplaySize:(CGSize)size position:(CGPoint)position rotateAngle:(CGFloat)angle; - -/*! - @method process: - @brief 用于处理图像的接口 - - @param pixelBuffer 原始图像的对象 - - @return 处理之后的 CVPixelBufferRef 对象 - - @discussion 使用该接口进行图像处理需要注意的是,为了保持图像处理的效率,减小开销,该类内部会持有一个 CVPixelBufferRef 并在每次都会返回该对象,因此在每次调用之后请确认对返回的数据已经使用完毕再进行下一次调用,否则会出现非预期的问题 - */ -- (CVPixelBufferRef)process:(CVPixelBufferRef)pixelBuffer; - -@end diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLShortVideoRecorder.h b/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLShortVideoRecorder.h index b6db8b5d..36276bfb 100644 --- a/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLShortVideoRecorder.h +++ b/Pod/Library/Profession/PLShortVideoKit.framework/Headers/PLShortVideoRecorder.h @@ -18,7 +18,7 @@ /*! @protocol PLShortVideoRecorderDelegate @brief 短视频录制协议 - + @since v1.0.0 */ @protocol PLShortVideoRecorderDelegate @@ -28,10 +28,10 @@ /*! @method shortVideoRecorder:didGetCameraAuthorizationStatus: @abstract 摄像头授权状态发生变化的回调 - + @param recorder PLShortVideoRecorder 实例 @param status 相机授权状态 - + @since v1.0.0 */ - (void)shortVideoRecorder:(PLShortVideoRecorder *__nonnull)recorder didGetCameraAuthorizationStatus:(PLSAuthorizationStatus)status; @@ -39,10 +39,10 @@ /*! @method shortVideoRecorder:didGetMicrophoneAuthorizationStatus: @abstract 麦克风授权状态发生变化的回调 - + @param recorder PLShortVideoRecorder 实例 @param status 麦克风授权状态 - + @since v1.0.0 */ - (void)shortVideoRecorder:(PLShortVideoRecorder *__nonnull)recorder didGetMicrophoneAuthorizationStatus:(PLSAuthorizationStatus)status; @@ -53,7 +53,7 @@ @abstract 摄像头对焦位置的回调 @param point 相机当前焦点 - + @since v1.6.0 */ - (void)shortVideoRecorderDidFocusAtPoint:(CGPoint)point __deprecated_msg("Method deprecated in v1.9.0. Use `shortVideoRecorder: didFocusAtPoint:`"); @@ -61,10 +61,10 @@ /*! @method shortVideoRecorder:didFocusAtPoint: @abstract 摄像头对焦位置的回调 - + @param recorder PLShortVideoRecorder 实例 @param point 相机当前焦点 - + @since v1.9.0 */ - (void)shortVideoRecorder:(PLShortVideoRecorder *__nonnull)recorder didFocusAtPoint:(CGPoint)point; @@ -73,10 +73,10 @@ /*! @method shortVideoRecorder:pixelBuffer: @abstract 获取到摄像头原数据时的回调, 便于开发者做滤镜等处理,需要注意的是这个回调在 camera 数据的输出线程,请不要做过于耗时的操作,否则可能会导致帧率下降 - + @param recorder PLShortVideoRecorder 实例 @param pixelBuffer 视频帧数据 - + @since v1.0.0 */ - (CVPixelBufferRef __nonnull)shortVideoRecorder:(PLShortVideoRecorder *__nonnull)recorder cameraSourceDidGetPixelBuffer:(CVPixelBufferRef __nonnull)pixelBuffer __deprecated_msg("Method deprecated in v3.1.1. Use `shortVideoRecorder:cameraSourceDidGetPixelBuffer:timingInfo:'"); @@ -84,19 +84,30 @@ /*! @method shortVideoRecorder:pixelBuffer: @abstract 获取到摄像头原数据时的回调, 便于开发者做滤镜等处理,需要注意的是这个回调在 camera 数据的输出线程,请不要做过于耗时的操作,否则可能会导致帧率下降 - + @param recorder PLShortVideoRecorder 实例 @param pixelBuffer 视频帧数据 @param timingInfo 采样时间信息 - + @since v3.1.1 */ - (CVPixelBufferRef __nonnull)shortVideoRecorder:(PLShortVideoRecorder *__nonnull)recorder cameraSourceDidGetPixelBuffer:(CVPixelBufferRef __nonnull)pixelBuffer timingInfo:(CMSampleTimingInfo)timingInfo; +/*! + @method shortVideoRecorder:cameraSourceDidGetSampleBuffer: + @abstract 获取摄像头原始数据 + + @param recorder PLShortVideoRecorder 实例 + @param sampleBuffer 视频帧数据 + + @since 3.2.1 + */ +- (void)shortVideoRecorder:(PLShortVideoRecorder *__nonnull)recorder cameraSourceDidGetSampleBuffer:(CMSampleBufferRef __nonnull)sampleBuffer; + /*! @method shortVideoRecorder:microphoneSourceDidGetSampleBuffer: @abstract 获取到麦克风原数据时的回调,需要注意的是这个回调在 microphone 数据的输出线程,请不要做过于耗时的操作,否则可能阻塞该线程影响音频输出或其他未知问题 - + @param recorder PLShortVideoRecorder 实例 @param sampleBuffer 音频帧数据 @@ -108,10 +119,10 @@ /*! @method shortVideoRecorder:didStartRecordingToOutputFileAtURL: @abstract 开始录制一段视频时 - + @param recorder PLShortVideoRecorder 实例 @param fileURL 录制文件的存放地址 - + @since v1.0.0 */ - (void)shortVideoRecorder:(PLShortVideoRecorder *__nonnull)recorder didStartRecordingToOutputFileAtURL:(NSURL *__nonnull)fileURL; @@ -119,12 +130,12 @@ /*! @method shortVideoRecorder:didRecordingToOutputFileAtURL:fileDuration:totalDuration: @abstract 正在录制的过程中。在完成该段视频录制前会一直回调,可用来更新所有视频段加起来的总时长 totalDuration UI。 - + @param recorder PLShortVideoRecorder 实例 @param fileURL 当前正在录制的文件存放地址 @param fileDuration 当前正在录制的文件时长 @param totalDuration 所有录制文件的总时长 - + @since v1.0.0 */ - (void)shortVideoRecorder:(PLShortVideoRecorder *__nonnull)recorder didRecordingToOutputFileAtURL:(NSURL *__nonnull)fileURL fileDuration:(CGFloat)fileDuration totalDuration:(CGFloat)totalDuration; @@ -132,7 +143,7 @@ /*! @method shortVideoRecorder:didDeleteFileAtURL:fileDuration:totalDuration: @abstract 删除了某一段视频 - + @param recorder PLShortVideoRecorder 实例 @param fileURL 当前删除的文件存放地址 @param fileDuration 当前删除的文件时长 @@ -145,12 +156,12 @@ /*! @method shortVideoRecorder:didFinishRecordingToOutputFileAtURL:fileDuration:totalDuration: @abstract 完成一段视频的录制时 - + @param recorder PLShortVideoRecorder 实例 @param fileURL 当前录制完成的文件存放地址 @param fileDuration 当前录制完成的文件时长 @param totalDuration 所有录制文件的总时长 - + @since v1.0.0 */ - (void)shortVideoRecorder:(PLShortVideoRecorder *__nonnull)recorder didFinishRecordingToOutputFileAtURL:(NSURL *__nonnull)fileURL fileDuration:(CGFloat)fileDuration totalDuration:(CGFloat)totalDuration; @@ -158,10 +169,10 @@ /*! @method shortVideoRecorder:didFinishRecordingMaxDuration: @abstract 在达到指定的视频录制时间 maxDuration 后,如果再调用 [PLShortVideoRecorder startRecording],那么会立即执行该回调。该回调功能是用于页面跳转 - + @param recorder PLShortVideoRecorder 实例 @param maxDuration 设置的最大录制时长 - + @since v1.0.0 */ - (void)shortVideoRecorder:(PLShortVideoRecorder *__nonnull)recorder didFinishRecordingMaxDuration:(CGFloat)maxDuration; @@ -173,7 +184,7 @@ /*! @class PLShortVideoRecorder @abstract 短视频录制的核心类。 - + @discussion 一个 PLShortVideoRecorder 实例会包含了对视频源、音频源的控制,并且对流的操作及流状态的返回都是通过它来完成的。 */ @interface PLShortVideoRecorder : NSObject @@ -181,7 +192,7 @@ /*! @method assetRepresentingAllFiles @brief 获取代表当前会话的所有视频段文件的 asset - + @return 返回代表当前会话的所有视频段文件的 asset @since v1.0.0 */ @@ -190,7 +201,7 @@ /*! @property maxDuration @brief 视频录制的最大时长,单位为秒。默认为10秒 - + @since v1.0.0 */ @property (assign, nonatomic) CGFloat maxDuration; @@ -198,7 +209,7 @@ /*! @property minDuration @brief 视频录制的最短时间,单位为秒。默认为2秒 - + @since v1.0.0 */ @property (assign, nonatomic) CGFloat minDuration; @@ -206,7 +217,7 @@ /*! @property videoConfiguration @brief 视频配置,只读 - + @since v1.0.0 */ @property (strong, nonatomic, readonly) PLSVideoConfiguration *__nonnull videoConfiguration; @@ -214,7 +225,7 @@ /*! @property audioConfiguration @brief 音频配置,只读 - + @since v1.0.0 */ @property (strong, nonatomic, readonly) PLSAudioConfiguration *__nonnull audioConfiguration; @@ -222,7 +233,7 @@ /*! @property previewView @brief 摄像头的预览视图 - + @since v1.0.0 */ @property (strong, nonatomic, readonly) UIView *__nullable previewView; @@ -230,7 +241,7 @@ /*! @property adaptationRecording @brief 根据设备的方向自动确定竖屏、横屏拍摄。默认为 NO,不启用自动确定 - + @since v1.3.0 */ @property (assign, nonatomic) BOOL adaptationRecording; @@ -238,14 +249,14 @@ /*! @property deviceOrientation @brief 获取当前设备的旋转方向 - + @discussion 当 adaptationRecording 为YES时,获取设备方向的回调 deviceOrientationBlock 才有效。 拍摄时可根据 deviceOrientation 做 UI 效果来标明当前拍摄的方向是竖屏还是横屏。 PLSPreviewOrientationPortrait 竖屏拍摄 PLSPreviewOrientationPortraitUpsideDown 倒立拍摄 PLSPreviewOrientationLandscapeRight 右横屏拍摄 PLSPreviewOrientationLandscapeLeft 左横屏拍摄 - + @since v1.3.0 */ @property (copy, nonatomic) void(^ _Nullable deviceOrientationBlock)(PLSPreviewOrientation deviceOrientation); @@ -253,7 +264,7 @@ /*! @property delegate @brief 代理对象 - + @since v1.0.0 */ @property (weak, nonatomic) id __nullable delegate; @@ -261,13 +272,13 @@ /*! @property delegateQueue @abstract 触发代理对象回调时所在的任务队列。 - + @discussion 默认情况下该值为 nil,此时代理方法都会通过 main queue 异步执行回调。如果你期望可以所有的回调在自己创建或者其他非主线程调用, 可以设置改 delegateQueue 属性。 - + @see PLShortVideoRecorderDelegate @see delegate - + @since v1.0.0 */ @property (strong, nonatomic) dispatch_queue_t __nullable delegateQueue; @@ -275,7 +286,7 @@ /*! @property fillMode @brief previewView 中视频的填充方式,默认使用 PLVideoFillModePreserveAspectRatioAndFill - + @since v1.0.0 */ @property (readwrite, nonatomic) PLSVideoFillModeType fillMode; @@ -283,7 +294,7 @@ /*! @property isRecording @brief PLShortVideoRecorder 处于录制状态时为 true - + @since v1.0.0 */ @property (readonly, nonatomic) BOOL isRecording; @@ -291,7 +302,7 @@ /*! @property captureEnabled @brief 是否开启音视频采集 - + @since v1.2.0 */ @property (assign, nonatomic, readonly) BOOL captureEnabled; @@ -299,7 +310,7 @@ /*! @property recoderRate @brief 视频拍摄速率值,默认使用 PLSVideoRecoderRateNormal,isRecording 为 YES 时,设置该值无效 - + @since v1.4.0 */ @property (readwrite, nonatomic) PLSVideoRecoderRateType recoderRate; @@ -307,7 +318,7 @@ /*! @property outputFileType @brief 视频的文件类型,默认为 PLSFileTypeMPEG4(.mp4) - + @since v1.6.0 */ @property (assign, nonatomic) PLSFileType outputFileType; @@ -315,7 +326,7 @@ /*! @property catpuredView @brief 指定捕捉某个 View 的画面,将 View 画面录制为视频 - + @since v1.11.0 */ @property (strong, nonatomic) UIView *_Nullable catpuredView; @@ -323,29 +334,28 @@ /*! @method initWithCatpuredViewVideoConfiguration:audioConfiguration: @brief 指定捕捉某个 View 的画面,将 View 画面录制为视频时的初始化方法 - + @discussion catpuredViewVideoConfiguration 必须要设置,用来配置视频信息。 audioConfiguration 设置为 nil 时,不采集音频。 - + @param catpuredViewVideoConfiguration 视频采集和编码参数 @param audioConfiguration 音频采集和编码参数 - + @return 返回 PLShortVideoRecorder 实例 @since v1.11.0 */ - - (nonnull instancetype)initWithCatpuredViewVideoConfiguration:(PLSVideoConfiguration *_Nonnull)catpuredViewVideoConfiguration audioConfiguration:(PLSAudioConfiguration *_Nullable)audioConfiguration; /*! @method initWithVideoConfiguration:audioConfiguration: @abstract 初始化方法 - + @discussion videoConfiguration 设置为 nil 时,不采集视频。 audioConfiguration 设置为 nil 时,不采集音频。 - + @param videoConfiguration 视频采集和编码参数 @param audioConfiguration 音频采集和编码参数 - + @since v1.0.0 @return 返回 PLShortVideoRecorder 实例 */ @@ -354,13 +364,13 @@ /*! @method initWithVideoConfiguration:audioConfiguration:captureEnabled: @abstract 初始化方法 - + @param videoConfiguration 视频采集和编码参数 @param audioConfiguration 音频采集和编码参数 @param captureEnabled 是否启用音视频采集 - + @since v1.2.0 - + @discussion 是否使用 SDK 内部的音视频采集,默认为 YES,当设置为 NO 时,可通过以下两个接口导入音视频数据 - (void)writePixelBuffer:(CVPixelBufferRef _Nonnull)pixelBuffer timeStamp:(CMTime)timeStamp; - (void)writeAudioBuffer:(AudioBuffer *_Nonnull)audioBuffer asbd:(AudioStreamBasicDescription *_Nonnull)asbd timeStamp:(CMTime)timeStamp; @@ -368,13 +378,30 @@ */ - (nonnull instancetype)initWithVideoConfiguration:(PLSVideoConfiguration *__nonnull)videoConfiguration audioConfiguration:(PLSAudioConfiguration *__nonnull)audioConfiguration captureEnabled:(BOOL)captureEnabled; + +/*! + @method initWithVideoConfiguration:audioConfiguration:videoCaptureEnabled:audioCaptureEnabled: + @abstract 初始化方法 + + @param videoConfiguration 视频采集和编码参数 + @param audioConfiguration 音频采集和编码参数 + @param videoCaptureEnabled 是否启用视频采集 + @param audioCaptureEnabled 是否启用音频采集 + + @since 3.2.1 + */ +- (nonnull instancetype)initWithVideoConfiguration:(PLSVideoConfiguration *__nonnull)videoConfiguration + audioConfiguration:(PLSAudioConfiguration *__nonnull)audioConfiguration + videoCaptureEnabled:(BOOL)videoCaptureEnabled + audioCaptureEnabled:(BOOL)audioCaptureEnabled; + /*! @method writePixelBuffer:timeStamp @abstract 写入视频数据,当 captureEnabled 为 NO 时,可通过该接口导入视频数据 - + @param pixelBuffer kCVPixelFormatType_32BGRA 格式的 CVPixelBufferRef @param timeStamp pixelBuffer 对应的时间戳 - + @warning 目前仅支持 kCVPixelFormatType_32BGRA 格式的 pixelBuffer @since v1.2.0 @@ -384,9 +411,9 @@ /*! @method writeSampleBuffer: @abstract 写入音频数据,当 captureEnabled 为 NO 时,可通过该接口导入音频数据 - + @param sampleBuffer 音频数据帧 - + @since v1.2.0 */ - (void)writeSampleBuffer:(CMSampleBufferRef _Nonnull)sampleBuffer; @@ -394,11 +421,11 @@ /*! @method insertVideo: @abstract 插入视频,支持任意位置,通过该接口传入,成为 PLShortVideoRecorder 当前视频数组的下一个视频段 - + @param videoURL 插入的视频存放地址 - + @warning PLShortVideoRecorder 初始化后调用,当视频时长加上视频数组中的所有视频段时长,超过视频设置的最大时长 maxDuration 时,则传值无效 - + @since v1.7.0 */ - (void)insertVideo:(NSURL *_Nonnull)videoURL; @@ -406,7 +433,7 @@ /*! @method startRecording @brief 开始录制视频,录制的视频的存放地址由 SDK 内部自动生成 - + @warning 获取所有录制的视频段的地址,可以使用 - (NSArray *__nullable)getAllFilesURL @since v1.0.0 @@ -416,12 +443,12 @@ /*! @method startRecording: @brief 开始录制视频 - + @param fileURL 录制的视频的存放地址,该参数可以在外部设置,录制的视频会保存到该位置 - + @warning 生成 URL 需使用 [NSURL fileURLWithPath:fileName] 方式,让 URL 的 scheme 合法(file://,http://,https:// 等)。 获取所有录制的视频段的地址,可以使用 - (NSArray *__nullable)getAllFilesURL - + @since v1.8.0 */ - (void)startRecording:(NSURL *_Nonnull)fileURL; @@ -429,7 +456,7 @@ /*! @method stopRecording @brief 停止录制视频 - + @since v1.0.0 */ - (void)stopRecording; @@ -437,7 +464,7 @@ /*! @method cancelRecording @brief 取消录制会停止视频录制并删除已经录制的视频段文件 - + @since v1.0.0 */ - (void)cancelRecording; @@ -445,7 +472,7 @@ /*! @method deleteLastFile @brief 删除上一个录制的视频段 - + @since v1.0.0 */ - (void)deleteLastFile; @@ -453,7 +480,7 @@ /*! @method deleteAllFiles @brief 删除所有录制的视频段 - + @since v1.0.0 */ - (void)deleteAllFiles; @@ -461,7 +488,7 @@ /*! @method getAllFilesURL @brief 获取所有录制的视频段的地址 - + @return 返回当前录制完成的所有视频段地址 @since v1.0.0 */ @@ -470,7 +497,7 @@ /*! @method getFilesCount @brief 获取录制的视频段的总数目 - + @return 返回当前录制完成的是视频段总数 @since v1.0.0 */ @@ -479,7 +506,7 @@ /*! @method getTotalDuration @brief 获取所有录制的视频段加起来的总时长 - + @return 返回所有录制的视频段加起来的总时长 @since v1.0.0 */ @@ -488,9 +515,9 @@ /*! @method getScreenShotWithCompletionHandler: @brief 实时截图, 异步返回截图结果 image. 在 handler 内部调用 self,请使用 __weak typeof(self) weakSelf = self, 避免循环引用, 因为 SDK 内部对 handle 执行了 copy 操作 - + @param handler 截图完成的回调 - + @since v1.9.0 */ - (void)getScreenShotWithCompletionHandler:(void(^_Nullable)(UIImage * _Nullable image))handler; @@ -508,13 +535,13 @@ /*! @property backgroundMonitorEnable @abstract 默认为 YES,即 SDK 内部根据监听到的 Application 前后台状态自动停止和开始录制视频 - + @warning 设置为 YES 时,即 Application 进入后台,若当前为拍摄视频状态,SDK 内部会自动停止视频的录制,恢复到前台,SDK 内部自动启动视频的录制; 设置为 NO 时,即 Application 进入后台,若当前为拍摄视频状态,SDK 内部会停止视频的录制,恢复到前台,SDK 内部不会自动启动视频的录制。 为什么设置为 NO,SDK 内部仍然要在 Application 进入后台时停止视频录制呢?原因是,开发者将该属性设置为 NO 后,可能在应用层忘记处理 Application 进入后台时要调用 stopRecording 来停止视频的录制,进而出现 crash。所以,不管该属性是 YES 还是 NO,当 Application 进入后台,SDK 内部都会调用 stopRecording 自动停止视频的录制。 - + @since v1.11.0 */ @property (assign, nonatomic) BOOL backgroundMonitorEnable; @@ -532,11 +559,11 @@ /*! @method mixAudio: @abstract 设置录制时的背景音乐 - + @param audioURL 音乐文件存放地址 - + @warning PLShortVideoRecorder 初始化后调用,audioURL 为音频 URL - + @since v1.7.0 */ - (void)mixAudio:(NSURL *_Nullable)audioURL; @@ -544,12 +571,12 @@ /*! @method mixAudio:playEnable: @abstract 设置录制时的背景音乐 - + @warning PLShortVideoRecorder 初始化后调用,audioURL 为音频 URL - + @param audioURL 音频 URL @param playEnable 音频添加后是否立即播放 - + @since v1.11.0 */ - (void)mixAudio:(NSURL *_Nullable)audioURL playEnable:(BOOL)playEnable; @@ -557,14 +584,14 @@ /*! @method mixAudio:startTime:volume:playEnable: @abstract 设置录制时的背景音乐 - + @warning PLShortVideoRecorder 初始化后调用,audioURL 为音频 URL - + @param audioURL 音频 URL @param startTime 音频开始播放的位置 @param volume 音频的音量 @param playEnable 音频添加后是否立即播放 - + @since v1.11.0 */ - (void)mixAudio:(NSURL *_Nullable)audioURL startTime:(NSTimeInterval)startTime volume:(CGFloat)volume playEnable:(BOOL)playEnable; @@ -572,13 +599,13 @@ /*! @method mixWithMusicVolume:videoVolume:completionHandler: @brief 获取添加背景音乐录制完成后的 audioMix - + @warning 设置背景音乐后有效 - + @param musicVolume 背景音乐音量,范围 0 ~ 1 @param videoVolume 原视频音量,范围 0 ~ 1 @param completionHandler 获取 composition 及 audioMix - + @since v1.7.0 */ - (void)mixWithMusicVolume:(float)musicVolume videoVolume:(float)videoVolume completionHandler:(void (^_Nonnull)(AVMutableComposition * _Nullable composition, AVAudioMix * _Nullable audioMix, NSError * _Nullable error))completionHandler; @@ -589,7 +616,7 @@ /*! @category PLShortVideoRecorder (Info) @abstract SDK 信息相关 - + @since v1.0.0 */ @interface PLShortVideoRecorder (Info) @@ -597,7 +624,7 @@ /*! @method versionInfo @abstract PLShortVideoRecorder 的 SDK 版本。 - + @return 返回 SDK 版本信息 @since v1.0.0 */ @@ -606,9 +633,9 @@ /*! @method checkAuthentication: @abstract SDK 授权状态查询 - + @param resultBlock 授权状态查询完成之后的回调 - + @since v1.16.1 */ + (void)checkAuthentication:(void(^ __nonnull)(PLSAuthenticationResult result))resultBlock;; @@ -620,7 +647,7 @@ /*! @category PLShortVideoRecorder (Dubber) @abstract 视频配音 - + @since v1.6.0 */ @interface PLShortVideoRecorder (Dubber) @@ -628,10 +655,10 @@ /*! @method mixAsset:timeRange: @brief 纯音频录制时,将录制的纯音频 AVAsset *audio = [self.recorder assetRepresentingAllFiles] 与 asset 混合。 - + @param asset AVAsset 对象文件 @param timeRange asset 的截取时间段 - + @since v1.6.0 */ - (AVAsset *_Nullable)mixAsset:(AVAsset *_Nullable)asset timeRange:(CMTimeRange)timeRange; @@ -643,7 +670,7 @@ /*! @category PLShortVideoRecorder(CameraSource) @discussion 与摄像头相关的接口 - + @since v1.0.0 */ @interface PLShortVideoRecorder (CameraSource) @@ -651,7 +678,7 @@ /*! @property captureSession @brief 只读变量,给有特殊需求的开发者使用 - + @since v1.15.0 */ @property (readonly, nonatomic) AVCaptureSession *_Nullable captureSession; @@ -659,7 +686,7 @@ /*! @property captureDeviceInput @brief 视频采集输入源,只读变量,给有特殊需求的开发者使用 - + @since v1.11.1 */ @property (readonly, nonatomic) AVCaptureDeviceInput *_Nullable captureDeviceInput; @@ -667,7 +694,7 @@ /*! @property captureDevicePosition @brief default as AVCaptureDevicePositionBack - + @since v1.0.0 */ @property (assign, nonatomic) AVCaptureDevicePosition captureDevicePosition; @@ -675,7 +702,7 @@ /*! @property videoOrientation @brief 开启 camera 时的采集摄像头的旋转方向,默认为 AVCaptureVideoOrientationPortrait - + @since v1.0.0 */ @property (assign, nonatomic) AVCaptureVideoOrientation videoOrientation; @@ -691,7 +718,7 @@ /*! @property continuousAutofocusEnable @abstract 手动对焦的视图动画。该属性默认开启。 - + @since v1.6.0 */ @property (assign, nonatomic) BOOL innerFocusViewShowEnable; @@ -699,7 +726,7 @@ /*! @property continuousAutofocusEnable @abstract 连续自动对焦。该属性默认开启。 - + @since v1.0.0 */ @property (assign, nonatomic, getter=isContinuousAutofocusEnable) BOOL continuousAutofocusEnable; @@ -707,7 +734,7 @@ /*! @property touchToFocusEnable @abstract 手动点击屏幕进行对焦。该属性默认开启。 - + @since v1.0.0 */ @property (assign, nonatomic, getter=isTouchToFocusEnable) BOOL touchToFocusEnable; @@ -721,7 +748,7 @@ /*! @property focusPointOfInterest @abstract default as (0.5, 0.5), (0,0) is top-left, (1,1) is bottom-right. - + @since v1.0.0 */ @property (assign, nonatomic) CGPoint focusPointOfInterest; @@ -729,7 +756,7 @@ /*! @property videoZoomFactor @abstract 默认为 1.0,设置的数值需要小于等于 videoActiveForat.videoMaxZoomFactor,如果大于会设置失败 - + @since v1.0.0 */ @property (assign, nonatomic) CGFloat videoZoomFactor; @@ -737,7 +764,7 @@ /*! @property videoFormats @brief videoFormats - + @since v1.0.0 */ @property (strong, nonatomic, readonly) NSArray *__nonnull videoFormats; @@ -745,7 +772,7 @@ /*! @property videoActiveFormat @brief videoActiveFormat - + @since v1.0.0 */ @property (strong, nonatomic) AVCaptureDeviceFormat *__nonnull videoActiveFormat; @@ -753,7 +780,7 @@ /*! @property sessionPreset @brief 采集的视频的 sessionPreset,默认为 AVCaptureSessionPreset1280x720 - + @since v1.0.0 */ @property (strong, nonatomic) NSString *__nonnull sessionPreset; @@ -761,7 +788,7 @@ /*! @property videoFrameRate @brief 采集的视频数据的帧率,默认为 25 - + @since v1.0.0 */ @property (assign, nonatomic) NSUInteger videoFrameRate; @@ -769,7 +796,7 @@ /*! @property previewMirrorFrontFacing @brief 前置预览是否开启镜像,默认为 YES - + @since v1.0.0 */ @property (assign, nonatomic) BOOL previewMirrorFrontFacing; @@ -777,7 +804,7 @@ /*! @property previewMirrorRearFacing @brief 后置预览是否开启镜像,默认为 NO - + @since v1.0.0 */ @property (assign, nonatomic) BOOL previewMirrorRearFacing; @@ -785,7 +812,7 @@ /*! @property streamMirrorFrontFacing @brief 前置摄像头,编码写入文件时是否开启镜像,默认 NO - + @since v1.0.0 */ @property (assign, nonatomic) BOOL streamMirrorFrontFacing; @@ -793,7 +820,7 @@ /*! @property streamMirrorRearFacing @brief 后置摄像头,编码写入文件时是否开启镜像,默认 NO - + @since v1.0.0 */ @property (assign, nonatomic) BOOL streamMirrorRearFacing; @@ -801,7 +828,7 @@ /*! @property renderQueue @brief 预览的渲染队列 - + @since v1.0.0 */ @property (strong, nonatomic, readonly) dispatch_queue_t __nonnull renderQueue; @@ -809,7 +836,7 @@ /*! @property renderContext @brief 预览的渲染 OpenGL context - + @since v1.0.0 */ @property (strong, nonatomic, readonly) EAGLContext *__nonnull renderContext; @@ -823,9 +850,9 @@ /*! @method toggleCamera: @brief 切换前置/后置摄像头 - + @param completeBlock 切换相机完成回调 - + @since 2.0.0 */ - (void)toggleCamera:(void(^)(BOOL isFinish))completeBlock; @@ -833,7 +860,7 @@ /*! @method startCaptureSession @brief 开启音视频采集 - + @since v1.0.0 */ - (void)startCaptureSession; @@ -841,7 +868,7 @@ /*! @method stopCaptureSession @brief 停止音视频采集 - + @since v1.0.0 */ - (void)stopCaptureSession; @@ -849,9 +876,9 @@ /*! @method setBeautifyModeOn: @brief 是否开启美颜 - + @param beautifyModeOn 美颜开关 - + @since v1.0.0 */ -(void)setBeautifyModeOn:(BOOL)beautifyModeOn; @@ -859,9 +886,9 @@ /*! @method setBeautify: @brief 设置对应 Beauty 的程度参数. - + @param beautify 范围从 0 ~ 1,0 为不美颜 - + @since v1.0.0 */ -(void)setBeautify:(CGFloat)beautify; @@ -869,9 +896,9 @@ /*! @method setWhiten: @brief 设置美白程度(注意:如果美颜不开启,设置美白程度参数无效) - + @param whiten 范围是从 0 ~ 1,0 为不美白 - + @since v1.0.0 */ -(void)setWhiten:(CGFloat)whiten; @@ -879,21 +906,20 @@ /*! @method setRedden: @brief 设置红润的程度参数.(注意:如果美颜不开启,设置美白程度参数无效) - + @param redden 范围是从 0 ~ 1,0 为不红润 - + @since v1.0.0 */ - -(void)setRedden:(CGFloat)redden; /*! @method setWaterMarkWithImage:position: @brief 开启水印 - + @param waterMarkImage 水印的图片 @param position 水印的位置 - + @since v1.0.0 */ -(void)setWaterMarkWithImage:(UIImage *__nonnull)waterMarkImage position:(CGPoint)position; @@ -901,7 +927,7 @@ /*! @method clearWaterMark @brief 移除水印 - + @since v1.0.0 */ -(void)clearWaterMark; @@ -909,7 +935,7 @@ /*! @method reloadvideoConfiguration: @brief 重新配置视频的参数 - + @since v1.0.0 */ - (void)reloadvideoConfiguration:(PLSVideoConfiguration *__nonnull)videoConfiguration; diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/Info.plist b/Pod/Library/Profession/PLShortVideoKit.framework/Info.plist index 9e66822c..7368f24c 100644 Binary files a/Pod/Library/Profession/PLShortVideoKit.framework/Info.plist and b/Pod/Library/Profession/PLShortVideoKit.framework/Info.plist differ diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/PLShortVideoKit b/Pod/Library/Profession/PLShortVideoKit.framework/PLShortVideoKit index 4fc9c238..ef2621fc 100644 Binary files a/Pod/Library/Profession/PLShortVideoKit.framework/PLShortVideoKit and b/Pod/Library/Profession/PLShortVideoKit.framework/PLShortVideoKit differ diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeDirectory b/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeDirectory deleted file mode 100644 index cca6c526..00000000 Binary files a/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeDirectory and /dev/null differ diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeRequirements b/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeRequirements deleted file mode 100644 index 8ad43fb0..00000000 Binary files a/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeRequirements and /dev/null differ diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeRequirements-1 b/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeRequirements-1 deleted file mode 100644 index c266bc24..00000000 Binary files a/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeRequirements-1 and /dev/null differ diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeResources b/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeResources deleted file mode 100644 index 4074330f..00000000 --- a/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeResources +++ /dev/null @@ -1,762 +0,0 @@ - - - - - files - - Headers/AVAsset+PLSExtendProperty.h - - SWRl2gOO0iYX4V7JptJkIxTzeEE= - - Headers/PLSAVAssetExportSession.h - - 9ot5Mkc6EXASC0kmoAZTdWtEd3Q= - - Headers/PLSAudioConfiguration.h - - 2Bb0sf/wC9dJ+Qfkysn3as/woNY= - - Headers/PLSAudioMixConfiguration.h - - sN3K2eScZs2OtbB1lcP/LfQE2Ds= - - Headers/PLSCVPixelBufferRotateProcessor.h - - JPsN5NhPoK9Zu131R2AYjOeUIgg= - - Headers/PLSEditPlayer.h - - CMCE9jCENNzRcNG73zDPfKZdZqI= - - Headers/PLSEditSettings.h - - LAtRp7FnNUMypTma1GDvnpaOF4Y= - - Headers/PLSFadeTranstion.h - - P0R2X1qA6JzWdw/qR8W2HcSz2CY= - - Headers/PLSFilter.h - - Ee2XD6Z5U6tES2yn1bHEwGwwLUQ= - - Headers/PLSGLKView.h - - lpZ3yF/STaOBKnO2LQqU0YBzDLg= - - Headers/PLSGifComposer.h - - d/aV5YXPfmKhkRYXKhK2EjySJa8= - - Headers/PLSImageRotateProcessor.h - - 8Z7bEyqGRRYqweKqGxl86Fa9I0s= - - Headers/PLSImageRotateRecorder.h - - iQf4qzin0K7vGk0UHlHeNG4kfaM= - - Headers/PLSImageSetting.h - - 5T7NO+wYFi7SA4O6EnbNQvhdK3M= - - Headers/PLSImageToMovieComposer.h - - zlQny/jdjvLLEDaeB8uyDBJElWE= - - Headers/PLSMovieComposer.h - - dI6zTrkvL9cHeVQk7QK7yzHaMdI= - - Headers/PLSPixelBufferProcessor.h - - tkVdlvd+M1/w16pUJz06Qkhs2cY= - - Headers/PLSPositionTransition.h - - LDIgAdjm+1V1YEvJMtSrbTkX7vA= - - Headers/PLSRangeMedia.h - - 1QBjl5400TWeW3k/DayY+hzDz+s= - - Headers/PLSRangeMediaTools.h - - QSIi6jS+laN9YnecWA0+D/Oggko= - - Headers/PLSRangeMovieExport.h - - T5TvBl4ymRhmlEQGoCV3Rgs4rqA= - - Headers/PLSReverserEffect.h - - ISI1GPBN1aSE0z2Dh/vt6CEGeBE= - - Headers/PLSRotateTransition.h - - bws3dagqYayaNeY1vdgx/dE/8bA= - - Headers/PLSScaleTransition.h - - i61v03HRkFZFmMNPkOUqtzcxi5o= - - Headers/PLSTextSetting.h - - oLlIT6Gd00+wT+n2sPCJybv8BMs= - - Headers/PLSTransition.h - - hrhiJjhd08Om3KmhpZv8/L+ICMM= - - Headers/PLSTransitionAssetExport.h - - 3uh6hSgIkeVjA7ycL/q1TmJAjo8= - - Headers/PLSTransitionMaker.h - - W2eSmNpC57c3V4kLZS6fysKr/tA= - - Headers/PLSTypeDefines.h - - tQxzcgjOpLp0Np70XHGHbMws3oM= - - Headers/PLSUploaderConfiguration.h - - cQayQ/rAx8WsCM9wUwfx1A96Yr8= - - Headers/PLSUploaderResponseInfo.h - - 3LUtFCWcrbfL5w2kAZMtlCzDREE= - - Headers/PLSVideoConfiguration.h - - C8m3X4gdEf0XPjBFnF7IEe+Oots= - - Headers/PLSVideoMergeProcess.h - - l6JwjJojTx24FaykRtpgXlO5nwM= - - Headers/PLSVideoMixConfiguration.h - - eC8bapwgvQRqWgvQDxm6aJIRpVg= - - Headers/PLSVideoMixRecorder.h - - V61kQSOw+v+0RLQnU1s+TtqCN/Q= - - Headers/PLSWatermarkProcessor.h - - +jJ1xDwjmpqaes0pP60IpSISK1s= - - Headers/PLShortVideoAsset.h - - HNqGXY4l2E29xNonu4HgoSZTjv8= - - Headers/PLShortVideoEditor.h - - 84vPJf5rZ0ej00+/FZ6HNtJJ8pw= - - Headers/PLShortVideoKit.h - - LehiMI5PnnM3MLneWRNgkqLF2UM= - - Headers/PLShortVideoKitEnv.h - - qlw9lqQd2bYzY99QtlTEW4Cn4X8= - - Headers/PLShortVideoRecorder.h - - 4YHQMA41UvMwyw43M8GUp+fZR1Y= - - Headers/PLShortVideoTranscoder.h - - TB8yBS2RBe+OloWR1+t3yKJZK+M= - - Headers/PLShortVideoUploader.h - - EnmjKfkvfilweaFWgUAaM8dyIoQ= - - Info.plist - - 53JMo2jPGfHNkmDylL+9+nUgFcA= - - Modules/module.modulemap - - +pa9k0pqKWlbwK9Mjk4UbUk5dRY= - - - files2 - - Headers/AVAsset+PLSExtendProperty.h - - hash - - SWRl2gOO0iYX4V7JptJkIxTzeEE= - - hash2 - - K7tvrUxowuShZk2JjHhoRsY6JuglIcaavRfUTyFGhHg= - - - Headers/PLSAVAssetExportSession.h - - hash - - 9ot5Mkc6EXASC0kmoAZTdWtEd3Q= - - hash2 - - P0Sot7eZCCro6RY7ScQ79dfw/Tv8ppJB2a/1QCz2Th0= - - - Headers/PLSAudioConfiguration.h - - hash - - 2Bb0sf/wC9dJ+Qfkysn3as/woNY= - - hash2 - - pe8YPDmhYhtChXZMjmL/j+zyBRF682tMShb2Sua+wiA= - - - Headers/PLSAudioMixConfiguration.h - - hash - - sN3K2eScZs2OtbB1lcP/LfQE2Ds= - - hash2 - - 1K5zguZwmoUpfCSpLWuEWAYNE7DAZ15PcoXzHPJ2CO8= - - - Headers/PLSCVPixelBufferRotateProcessor.h - - hash - - JPsN5NhPoK9Zu131R2AYjOeUIgg= - - hash2 - - ON37FlF+QTG+/pwkBCHSC4+PA1qCHtdBmMz9V16MPbQ= - - - Headers/PLSEditPlayer.h - - hash - - CMCE9jCENNzRcNG73zDPfKZdZqI= - - hash2 - - E/geIB03yFM69VzS2eBhOO8bjqA5cNep0YJ0tEFwV+g= - - - Headers/PLSEditSettings.h - - hash - - LAtRp7FnNUMypTma1GDvnpaOF4Y= - - hash2 - - uurI4KcsxXWhwdzBdmE75ABkKsULPc/TAoydguQSBrs= - - - Headers/PLSFadeTranstion.h - - hash - - P0R2X1qA6JzWdw/qR8W2HcSz2CY= - - hash2 - - FS4gkUzjHPqdUTsWyhuNsmlyACQseRyNAblPRsbSX9o= - - - Headers/PLSFilter.h - - hash - - Ee2XD6Z5U6tES2yn1bHEwGwwLUQ= - - hash2 - - 1+LjfiELKeMsqEzNwvF2OgnyRvD7G5FNtCLWR4kSziA= - - - Headers/PLSGLKView.h - - hash - - lpZ3yF/STaOBKnO2LQqU0YBzDLg= - - hash2 - - y48iANiObcyTTiXpJPZeAjnszgos4a7A5q4aTy9ISw0= - - - Headers/PLSGifComposer.h - - hash - - d/aV5YXPfmKhkRYXKhK2EjySJa8= - - hash2 - - JFk6fqAMwIFRMCGi9PwtexNTIJIi9XeWvssnwF9dS7I= - - - Headers/PLSImageRotateProcessor.h - - hash - - 8Z7bEyqGRRYqweKqGxl86Fa9I0s= - - hash2 - - vY1o/YkUOPvKJz25gmH3N2hT7TsKaesItdI4tIzbyec= - - - Headers/PLSImageRotateRecorder.h - - hash - - iQf4qzin0K7vGk0UHlHeNG4kfaM= - - hash2 - - D4RvWFGD1Imw8SgdsNkikA4qZLIjqTmQjJaPgxzkcUg= - - - Headers/PLSImageSetting.h - - hash - - 5T7NO+wYFi7SA4O6EnbNQvhdK3M= - - hash2 - - V5LYFlGCwdGbbcitPGMTFiTsZjZ1CZOcGdOiCCx896Q= - - - Headers/PLSImageToMovieComposer.h - - hash - - zlQny/jdjvLLEDaeB8uyDBJElWE= - - hash2 - - 91AYTZgFZe/b9HAxzaZqhDj5ek1qyfeON0oq8Go4udI= - - - Headers/PLSMovieComposer.h - - hash - - dI6zTrkvL9cHeVQk7QK7yzHaMdI= - - hash2 - - T5KnkL7yyQYO9S0niX5ohKSC/V0Hr+K1dm6Cu4ch+K8= - - - Headers/PLSPixelBufferProcessor.h - - hash - - tkVdlvd+M1/w16pUJz06Qkhs2cY= - - hash2 - - K9HuH2joAcfOCbjYgXcEotHHHmYZZq3dM+h31LracFc= - - - Headers/PLSPositionTransition.h - - hash - - LDIgAdjm+1V1YEvJMtSrbTkX7vA= - - hash2 - - CYas5o6qS5K44NiKdLGpKVjohm7y7klG/AYxFMfyPVE= - - - Headers/PLSRangeMedia.h - - hash - - 1QBjl5400TWeW3k/DayY+hzDz+s= - - hash2 - - 5ElKmTbJ4DLPobdwyCGGBD/axnda5H2FgW64oDs3Jq0= - - - Headers/PLSRangeMediaTools.h - - hash - - QSIi6jS+laN9YnecWA0+D/Oggko= - - hash2 - - d0HEqZQXyNfFj/VMXs/fPNbiWWxYXAP3fj/80M2KBNc= - - - Headers/PLSRangeMovieExport.h - - hash - - T5TvBl4ymRhmlEQGoCV3Rgs4rqA= - - hash2 - - 70FZfLukmxEFv1Ipv+DA4Is8QT9D8NCkx3c82x/ud2M= - - - Headers/PLSReverserEffect.h - - hash - - ISI1GPBN1aSE0z2Dh/vt6CEGeBE= - - hash2 - - GB0OV1WExGCEJEgv1wHn2RDblCKosClPaJOoUBVDluY= - - - Headers/PLSRotateTransition.h - - hash - - bws3dagqYayaNeY1vdgx/dE/8bA= - - hash2 - - 5llOKVtKZWzLT+CK0fUoxdxi664/33G46AOS9GUZIG4= - - - Headers/PLSScaleTransition.h - - hash - - i61v03HRkFZFmMNPkOUqtzcxi5o= - - hash2 - - 4FbVYUkZRkCZDj0LPQG/nA4lrWrUMU2LP1n0IzOOQpU= - - - Headers/PLSTextSetting.h - - hash - - oLlIT6Gd00+wT+n2sPCJybv8BMs= - - hash2 - - vLsStQxJKRqov/S5tttOQdqOaufVvV+PvarBKKmwPIo= - - - Headers/PLSTransition.h - - hash - - hrhiJjhd08Om3KmhpZv8/L+ICMM= - - hash2 - - Vf4DjCogSFbrn/ipBQFoHQvFCxe6t47C0Ag+g3PoDpY= - - - Headers/PLSTransitionAssetExport.h - - hash - - 3uh6hSgIkeVjA7ycL/q1TmJAjo8= - - hash2 - - o9FIJbcMo9GFxWku3N6USe+2YvLBf9346RDB3UCjEak= - - - Headers/PLSTransitionMaker.h - - hash - - W2eSmNpC57c3V4kLZS6fysKr/tA= - - hash2 - - 3S7a5e74znz/0wrmcW0AtcTKapIr3V/z1EaYtwkmDZ0= - - - Headers/PLSTypeDefines.h - - hash - - tQxzcgjOpLp0Np70XHGHbMws3oM= - - hash2 - - G45lnvSE4HGnp1brupNcUlSwjn3Z4G1roGusTJvxjio= - - - Headers/PLSUploaderConfiguration.h - - hash - - cQayQ/rAx8WsCM9wUwfx1A96Yr8= - - hash2 - - T7r6RH12isCfcKYFErE2/WQE/zkfdpxvGs5o62vy9jw= - - - Headers/PLSUploaderResponseInfo.h - - hash - - 3LUtFCWcrbfL5w2kAZMtlCzDREE= - - hash2 - - opp0YY+8iZAj8WXNjj8ynFOZdqtgCUpvYmTiCTCK5Cs= - - - Headers/PLSVideoConfiguration.h - - hash - - C8m3X4gdEf0XPjBFnF7IEe+Oots= - - hash2 - - 5BgxCC/iAA9YOyq3V/KdCLHvbcGFvBsZVcpNSKDDqMk= - - - Headers/PLSVideoMergeProcess.h - - hash - - l6JwjJojTx24FaykRtpgXlO5nwM= - - hash2 - - dlNw4xTPRtizJtGhzd7qv3L7Ce5KhLpgkPIHe9dNkE0= - - - Headers/PLSVideoMixConfiguration.h - - hash - - eC8bapwgvQRqWgvQDxm6aJIRpVg= - - hash2 - - MHhHlkfoXm4UH0ihKwZ6AIMjrJPTDR+3qtY35dI0RJ8= - - - Headers/PLSVideoMixRecorder.h - - hash - - V61kQSOw+v+0RLQnU1s+TtqCN/Q= - - hash2 - - yLk8bJUurs7W7ORz4n9WO9jYTfxeVDvEMc1KFC70GRI= - - - Headers/PLSWatermarkProcessor.h - - hash - - +jJ1xDwjmpqaes0pP60IpSISK1s= - - hash2 - - 18UlQhP2jQPy/rAMsSHjYU26IYUAGb0JmKVmH6S4Lyc= - - - Headers/PLShortVideoAsset.h - - hash - - HNqGXY4l2E29xNonu4HgoSZTjv8= - - hash2 - - AkSrTx1b1p05/kZNJEnKXgdAQNNoyW2Wvad9wXF7bjM= - - - Headers/PLShortVideoEditor.h - - hash - - 84vPJf5rZ0ej00+/FZ6HNtJJ8pw= - - hash2 - - X4U/IyChkbCCoqJG6/Q9C3oeCMkiHAh84fEaqppBq+s= - - - Headers/PLShortVideoKit.h - - hash - - LehiMI5PnnM3MLneWRNgkqLF2UM= - - hash2 - - bmOUMiMWAWIARtMFDn7pk/ydU6dKNj5mQs3k7JbNxbY= - - - Headers/PLShortVideoKitEnv.h - - hash - - qlw9lqQd2bYzY99QtlTEW4Cn4X8= - - hash2 - - 2HhROV5zwTFWfozCrLEt21DZOGUEMvUGFwXLzk+KPt4= - - - Headers/PLShortVideoRecorder.h - - hash - - 4YHQMA41UvMwyw43M8GUp+fZR1Y= - - hash2 - - ZPmtQwEqXMBullLnHxoEDUWgA5RuM/EMzsY4uSAMY4M= - - - Headers/PLShortVideoTranscoder.h - - hash - - TB8yBS2RBe+OloWR1+t3yKJZK+M= - - hash2 - - 0mbPSBsEpVxfooo5xHYUt8vjBL+DaRiWH2Gw1xZ8nqA= - - - Headers/PLShortVideoUploader.h - - hash - - EnmjKfkvfilweaFWgUAaM8dyIoQ= - - hash2 - - LrTK8wZVo2KzqQIJzcpWzeCCjwbgkxAbJjtTfe4IC9Q= - - - Modules/module.modulemap - - hash - - +pa9k0pqKWlbwK9Mjk4UbUk5dRY= - - hash2 - - xoarXq2A9ptaDfat5G5iJgV0awRKFOAUT5CybLzv/EI= - - - - rules - - ^.* - - ^.*\.lproj/ - - optional - - weight - 1000 - - ^.*\.lproj/locversion.plist$ - - omit - - weight - 1100 - - ^Base\.lproj/ - - weight - 1010 - - ^version.plist$ - - - rules2 - - .*\.dSYM($|/) - - weight - 11 - - ^(.*/)?\.DS_Store$ - - omit - - weight - 2000 - - ^.* - - ^.*\.lproj/ - - optional - - weight - 1000 - - ^.*\.lproj/locversion.plist$ - - omit - - weight - 1100 - - ^Base\.lproj/ - - weight - 1010 - - ^Info\.plist$ - - omit - - weight - 20 - - ^PkgInfo$ - - omit - - weight - 20 - - ^embedded\.provisionprofile$ - - weight - 20 - - ^version\.plist$ - - weight - 20 - - - - diff --git a/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeSignature b/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeSignature deleted file mode 100644 index 309f46d5..00000000 Binary files a/Pod/Library/Profession/PLShortVideoKit.framework/_CodeSignature/CodeSignature and /dev/null differ diff --git a/ReleaseNotes/release-notes-3.2.1.md b/ReleaseNotes/release-notes-3.2.1.md new file mode 100644 index 00000000..84b671a6 --- /dev/null +++ b/ReleaseNotes/release-notes-3.2.1.md @@ -0,0 +1,20 @@ +# PLShortVideoKit Release Notes for 3.2.1 + +### 简介 +PLShortVideoKit 是七牛推出的一款适用于 iOS 平台的短视频 SDK,提供了包括美颜、滤镜、水印、断点录制、分段回删、视频编辑、混音特效、MV 特效、本地/云端存储在内的多种功能,支持高度定制以及二次开发。 + +### 版本 +- 发布 PLShortVideoKit.framework + +### 缺陷 +- 修复一些音轨不正常的视频导出失败的问题 +- 修复无法打开闪光灯的问题 +- 修复 4k 编辑 crash 的问题 + +### 功能 +- 支持单独开关音频、视频采集 + +### 注意事项 +- 七牛短视频 SDK 自 v3.0.0 版本起, 划分为精简版、基础版、进阶版、专业版 。不同版本 SDK 可以使用的功能点数量有差别,请按照购买的 License 版本使用对应的短视频 SDK 版本。 +- 若需要使用 PLShortVideoKit.framework 中的内置滤镜,则必须将 PLShortVideoKit.bundle 导入项目中。若需要增删、替换滤镜资源可操作 PLShortVideoKit.bundle 中的 colorFilter 文件夹。 +- 抖音特效,需要联系七牛商务获取 appkey 和资源文件。具体使用可参看 PLShortVideoKitDemo。 diff --git a/ShortVideoFunctionDemo/PLShortVideoKitDemo/EditViewController.m b/ShortVideoFunctionDemo/PLShortVideoKitDemo/EditViewController.m index 068fc3aa..5c1085c5 100644 --- a/ShortVideoFunctionDemo/PLShortVideoKitDemo/EditViewController.m +++ b/ShortVideoFunctionDemo/PLShortVideoKitDemo/EditViewController.m @@ -2200,8 +2200,24 @@ - (void)nextButtonClick { // // 设置视频的输出路径 // exportSession.outputURL = [self getFileURL:@"outputMovie"]; + /* + 7及以下机型导出 4K 分辨率有较大的可能性会导致内存过大而导致应用被系统杀死 + 由于源视频是 4K 视频,限制导出分辨率仍然会有较高的内存使用,若要支持老设备建议编辑之前提前转换为 1080p + */ + CGSize outsize = self.videoSize; + const CGSize limit = CGSizeMake(1280, 1280); + if (outsize.width > limit.width || outsize.height > limit.height) { + float wratio = limit.width / outsize.width; + float hratio = limit.height / outsize.height; + float ratio = wratio < hratio ? wratio : hratio; + + outsize = CGSizeMake(ceil(outsize.width * ratio), ceil(outsize.height * ratio)); + outsize.width = ((int)outsize.width) & (~1); + outsize.height = ((int)outsize.height) & (~1); + } + // 设置视频的导出分辨率,会将原视频缩放 - exportSession.outputVideoSize = self.videoSize; + exportSession.outputVideoSize = outsize; // 旋转视频 exportSession.videoLayerOrientation = self.videoLayerOrientation; @@ -2235,7 +2251,7 @@ - (void)nextButtonClick { // 更新进度 UI NSLog(@"Asset Export Progress: %f", progress); dispatch_async(dispatch_get_main_queue(), ^{ - weakSelf.progressLabel.text = [NSString stringWithFormat:@"%d%%", (int)(progress * 50)]; + weakSelf.progressLabel.text = [NSString stringWithFormat:@"%d%%", (int)(progress * 100)]; }); }]; @@ -2381,8 +2397,20 @@ - (void)doReserverEffect:(BOOL)removeAudio { // // 设置视频的输出路径 // exportSession.outputURL = [self getFileURL:@"outputMovie"]; + CGSize outsize = weakSelf.videoSize; + const CGSize limit = CGSizeMake(1280, 1280); + if (outsize.width > limit.width || outsize.height > limit.height) { + float wratio = limit.width / outsize.width; + float hratio = limit.height / outsize.height; + float ratio = wratio < hratio ? wratio : hratio; + + outsize = CGSizeMake(ceil(outsize.width * ratio), ceil(outsize.height * ratio)); + outsize.width = ((int)outsize.width) & (~1); + outsize.height = ((int)outsize.height) & (~1); + } + // 设置视频的导出分辨率,会将原视频缩放 - exportSession.outputVideoSize = weakSelf.videoSize; + exportSession.outputVideoSize = outsize; // 旋转视频 exportSession.videoLayerOrientation = weakSelf.videoLayerOrientation; @@ -2413,9 +2441,9 @@ - (void)doReserverEffect:(BOOL)removeAudio { // __weak typeof(self)weaksSelf = weakSelf; [exportSession setProcessingBlock:^(float progress) { // 更新进度 UI - NSLog(@"Asset Export Progress: %f %d", progress,(int)(50+(progress * 50))); + NSLog(@"Asset Export Progress: %f", progress * 50 + 50); dispatch_async(dispatch_get_main_queue(), ^{ - weakSelf.progressLabel.text = [NSString stringWithFormat:@"%d%%", (int)(50+(progress * 50))]; + weakSelf.progressLabel.text = [NSString stringWithFormat:@"%d%%", (int)progress * 50 + 50]; }); }]; diff --git a/ShortVideoFunctionDemo/PLShortVideoKitDemo/Info.plist b/ShortVideoFunctionDemo/PLShortVideoKitDemo/Info.plist index 73016280..35803e42 100644 --- a/ShortVideoFunctionDemo/PLShortVideoKitDemo/Info.plist +++ b/ShortVideoFunctionDemo/PLShortVideoKitDemo/Info.plist @@ -17,7 +17,7 @@ CFBundleShortVersionString $(MARKETING_VERSION) CFBundleVersion - $(MARKETING_VERSION).git-2020-07-17-610bd88 + $(MARKETING_VERSION).git-2020-09-18-dd1de68 Fabric APIKey diff --git a/ShortVideoFunctionDemo/PLShortVideoKitDemo/RecordViewController.m b/ShortVideoFunctionDemo/PLShortVideoKitDemo/RecordViewController.m index c19d5b47..83e1d26e 100644 --- a/ShortVideoFunctionDemo/PLShortVideoKitDemo/RecordViewController.m +++ b/ShortVideoFunctionDemo/PLShortVideoKitDemo/RecordViewController.m @@ -927,6 +927,10 @@ - (CVPixelBufferRef)shortVideoRecorder:(PLShortVideoRecorder *)recorder cameraSo return pixelBuffer; } +- (void)shortVideoRecorder:(PLShortVideoRecorder *)recorder cameraSourceDidGetSampleBuffer:(CMSampleBufferRef)sampleBuffer { + +} + #pragma mark -- PLShortVideoRecorderDelegate 视频录制回调 // 开始录制一段视频时 diff --git a/ShortVideoFunctionDemo/PLShortVideoKitDemo/SegmentEffects/BaseViewController.h b/ShortVideoFunctionDemo/PLShortVideoKitDemo/SegmentEffects/BaseViewController.h index e13fbb09..90b267a0 100644 --- a/ShortVideoFunctionDemo/PLShortVideoKitDemo/SegmentEffects/BaseViewController.h +++ b/ShortVideoFunctionDemo/PLShortVideoKitDemo/SegmentEffects/BaseViewController.h @@ -9,7 +9,9 @@ #import -#define iPhoneX_SERIES (enumDeviceTypeIPhoneXR == [BaseViewController deviceType] || enumDeviceTypeIPhoneX == [BaseViewController deviceType] || enumDeviceTypeIPhoneXS == [BaseViewController deviceType] || enumDeviceTypeIPhoneXSMax == [BaseViewController deviceType]) +BOOL hasNotch(); + +#define iPhoneX_SERIES hasNotch() typedef enum : NSUInteger { diff --git a/ShortVideoFunctionDemo/PLShortVideoKitDemo/SegmentEffects/BaseViewController.m b/ShortVideoFunctionDemo/PLShortVideoKitDemo/SegmentEffects/BaseViewController.m index a053bbb9..41d9b277 100644 --- a/ShortVideoFunctionDemo/PLShortVideoKitDemo/SegmentEffects/BaseViewController.m +++ b/ShortVideoFunctionDemo/PLShortVideoKitDemo/SegmentEffects/BaseViewController.m @@ -12,6 +12,15 @@ #define PLS_BaseToolboxView_HEIGHT 64 +BOOL hasNotch() { + if (@available(iOS 11.0, *)) { + if (UIApplication.sharedApplication.keyWindow.safeAreaInsets.bottom > 0) { + return YES; + } + } + return NO; +} + @interface BaseViewController () @end