File tree Expand file tree Collapse file tree 7 files changed +31
-12
lines changed
TZImagePickerControllerFramework Expand file tree Collapse file tree 7 files changed +31
-12
lines changed Original file line number Diff line number Diff line change 10
10
11
11
## 重要提示2:issue未说明下面必要情况的不予处理:1、我的demo是否正常? 2、你用的什么版本? 3、你的初始化TZImagePicker的代码 4、你是pod安装还是源码导入的?是否有改动TZImagePicker内部代码?
12
12
13
- ## 重要提示3:1.9.0版本后移除了"prefs: root ="的调用,这个API已经被列为私有API,请大家尽快升级。目前最新版本2.2.5
13
+ ## 重要提示3:1.9.0版本后移除了"prefs: root ="的调用,这个API已经被列为私有API,请大家尽快升级。目前最新版本2.2.6
14
14
15
15
关于升级iOS10和Xcdoe8的提示:
16
16
在Xcode8环境下将项目运行在iOS10的设备/模拟器中,访问相册和相机需要额外配置info.plist文件。分别是Privacy - Photo Library Usage Description和Privacy - Camera Usage Description字段,详见Demo中info.plist中的设置。
@@ -112,8 +112,15 @@ A:是否有集成WRNavigationBar?如有,参考其readme调一下它的wr_s
112
112
** Q:导航栏没了?**
113
113
A:是否有集成GKNavigationBarViewController?需要升级到2.0.4及以上版本,详见issue:[ https://github.com/QuintGao/GKNavigationBarViewController/issues/7 ] ( https://github.com/QuintGao/GKNavigationBarViewController/issues/7 ) 。
114
114
115
+ ** Q:有的视频导出失败?**
116
+ A:升级到2.2.6及以上版本试试,发现是修正视频转向导致的,2.2.6开始默认不再主动修正。如需打开,可设置needFixComposition为YES,但有几率导致安卓拍的视频导出失败。
117
+
118
+ ** Q:视频导出慢?**
119
+ A:视频导出分两步,第一步是通过PHAsset获取AVURLAsset,如是iCloud视频则涉及到网络请求,耗时容易不可控,第二步是通过AVURLAsset把视频保存到沙盒,耗时不算多。但第一步耗时不可控,你可以拷贝我源码出来拿到第一步的进度给用户一个进度提示...
120
+
115
121
## 六. Release Notes 最近更新
116
122
123
+ 2.2.6 新增needFixComposition属性,默认为NO,不再主动修正视频转向,防止部分安卓拍的视频导出失败
117
124
2.2.5 修复minPhotoWidthSelectable不生效的问题, 使用@available 消除警告
118
125
2.1.8 优化gif图播放的体验,加入iCloud同步进度条;新增notScaleImage属性,设置为YES时内部不去缩放图片
119
126
2.1.6 新增allowCameraLocation属性,默认为YES,置为NO时不会在照相/摄像时定位,修复一个序号紊乱的bug
Original file line number Diff line number Diff line change 1
1
Pod ::Spec . new do |s |
2
2
s . name = "TZImagePickerController"
3
- s . version = "2.2.5 "
3
+ s . version = "2.2.6 "
4
4
s . summary = "A clone of UIImagePickerController, support picking multiple photos、original photo and video"
5
5
s . homepage = "https://github.com/banchichen/TZImagePickerController"
6
6
s . license = "MIT"
7
7
s . author = { "banchichen" => "tanzhenios@foxmail.com" }
8
8
s . platform = :ios
9
9
s . ios . deployment_target = "6.0"
10
- s . source = { :git => "https://github.com/banchichen/TZImagePickerController.git" , :tag => "2.2.5 " }
10
+ s . source = { :git => "https://github.com/banchichen/TZImagePickerController.git" , :tag => "2.2.6 " }
11
11
s . requires_arc = true
12
12
s . resources = "TZImagePickerController/TZImagePickerController/*.{png,bundle}"
13
13
s . source_files = "TZImagePickerController/TZImagePickerController/*.{h,m}"
Original file line number Diff line number Diff line change 15
15
<key >CFBundlePackageType </key >
16
16
<string >APPL </string >
17
17
<key >CFBundleShortVersionString </key >
18
- <string >2.2.5 </string >
18
+ <string >2.2.6 </string >
19
19
<key >CFBundleSignature </key >
20
20
<string >???? </string >
21
21
<key >CFBundleVersion </key >
Original file line number Diff line number Diff line change @@ -888,12 +888,14 @@ - (void)startExportVideoWithVideoAsset:(AVURLAsset *)videoAsset presetName:(NSSt
888
888
[[NSFileManager defaultManager ] createDirectoryAtPath: [NSHomeDirectory () stringByAppendingFormat: @" /tmp" ] withIntermediateDirectories: YES attributes: nil error: nil ];
889
889
}
890
890
891
- AVMutableVideoComposition *videoComposition = [self fixedCompositionWithAsset: videoAsset];
892
- if (videoComposition.renderSize .width ) {
893
- // 修正视频转向
894
- session.videoComposition = videoComposition;
891
+ if ([TZImagePickerConfig sharedInstance ].needFixComposition ) {
892
+ AVMutableVideoComposition *videoComposition = [self fixedCompositionWithAsset: videoAsset];
893
+ if (videoComposition.renderSize .width ) {
894
+ // 修正视频转向
895
+ session.videoComposition = videoComposition;
896
+ }
895
897
}
896
-
898
+
897
899
// Begin to export video to the output path asynchronously.
898
900
[session exportAsynchronouslyWithCompletionHandler: ^(void ) {
899
901
dispatch_async (dispatch_get_main_queue (), ^{
Original file line number Diff line number Diff line change 4
4
//
5
5
// Created by 谭真 on 15/12/24.
6
6
// Copyright © 2015年 谭真. All rights reserved.
7
- // version 2.2.5 - 2018.08.10
7
+ // version 2.2.6 - 2018.08.21
8
8
// 更多信息,请前往项目的github地址:https://github.com/banchichen/TZImagePickerController
9
9
10
10
/*
133
133
// / 默认是NO,如果设置为YES,内部不会缩放图片到photoWidth像素宽
134
134
@property (assign , nonatomic ) BOOL notScaleImage;
135
135
136
+ // / 默认是NO,如果设置为YES,导出视频时会修正转向(慎重设为YES,可能导致部分安卓下拍的视频导出失败)
137
+ @property (assign , nonatomic ) BOOL needFixComposition;
138
+
136
139
// / The photos user have selected
137
140
// / 用户选中过的图片数组
138
141
@property (nonatomic , strong ) NSMutableArray *selectedAssets;
332
335
@property (assign , nonatomic ) BOOL showSelectedIndex;
333
336
@property (assign , nonatomic ) BOOL showPhotoCannotSelectLayer;
334
337
@property (assign , nonatomic ) BOOL notScaleImage;
338
+ @property (assign , nonatomic ) BOOL needFixComposition;
335
339
@end
Original file line number Diff line number Diff line change 4
4
//
5
5
// Created by 谭真 on 15/12/24.
6
6
// Copyright © 2015年 谭真. All rights reserved.
7
- // version 2.2.5 - 2018.08.10
7
+ // version 2.2.6 - 2018.08.21
8
8
// 更多信息,请前往项目的github地址:https://github.com/banchichen/TZImagePickerController
9
9
10
10
#import " TZImagePickerController.h"
@@ -273,6 +273,7 @@ - (void)configDefaultSetting {
273
273
self.allowPreview = YES ;
274
274
// 2.2.26版本,不主动缩放图片,降低内存占用
275
275
self.notScaleImage = YES ;
276
+ self.needFixComposition = NO ;
276
277
self.statusBarStyle = UIStatusBarStyleLightContent;
277
278
self.cannotSelectLayerColor = [[UIColor whiteColor ] colorWithAlphaComponent: 0.8 ];
278
279
self.allowCameraLocation = YES ;
@@ -361,6 +362,11 @@ - (void)setNotScaleImage:(BOOL)notScaleImage {
361
362
[TZImagePickerConfig sharedInstance ].notScaleImage = notScaleImage;
362
363
}
363
364
365
+ - (void )setNeedFixComposition : (BOOL )needFixComposition {
366
+ _needFixComposition = needFixComposition;
367
+ [TZImagePickerConfig sharedInstance ].needFixComposition = needFixComposition;
368
+ }
369
+
364
370
- (void )observeAuthrizationStatusChange {
365
371
[_timer invalidate ];
366
372
_timer = nil ;
Original file line number Diff line number Diff line change 15
15
<key >CFBundlePackageType </key >
16
16
<string >FMWK </string >
17
17
<key >CFBundleShortVersionString </key >
18
- <string >2.2.5 </string >
18
+ <string >2.2.6 </string >
19
19
<key >CFBundleVersion </key >
20
20
<string >$(CURRENT_PROJECT_VERSION) </string >
21
21
<key >NSPrincipalClass </key >
You can’t perform that action at this time.
0 commit comments