-
Notifications
You must be signed in to change notification settings - Fork 121
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #36 from anhaoxiong/master
release v1.10.0
- Loading branch information
Showing
194 changed files
with
4,940 additions
and
449 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
# PLShortVideoKit 1.9.0 to 1.10.0 API Differences | ||
|
||
## General Headers | ||
|
||
``` | ||
PLSUploaderConfiguration.h | ||
``` | ||
|
||
- *Added* @property (nonatomic, strong) NSDictionary * _Nullable params; | ||
- *Added* - (instancetype _Nullable)initWithToken:(NSString * _Nonnull)token videoKey:(NSString * _Nullable)videoKey https:(BOOL)https recorder:(NSString * _Nullable)recorder params:(NSDictionary * _Nullable)params; | ||
|
||
|
||
``` | ||
Added Class PLSTextSetting | ||
Added Class PLSImageSetting | ||
Added Class PLSFadeTranstion | ||
Added Class PLSScaleTransition | ||
Added Class PLSRotateTransition | ||
Added Class PLSPositionTransition | ||
Added Class PLSTransitionMaker | ||
Added Class PLSRangeMedia | ||
Added Class PLSRangeMovieExport | ||
Added Class PLSRangeMediaTools | ||
``` | ||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// | ||
// H265MovieViewController.h | ||
// PLShortVideoKitDemo | ||
// | ||
// Created by suntongmian on 2018/2/12. | ||
// Copyright © 2018年 Pili Engineering, Qiniu Inc. All rights reserved. | ||
// | ||
|
||
#import <UIKit/UIKit.h> | ||
|
||
@interface H265MovieViewController : UITableViewController | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,111 @@ | ||
// | ||
// H265MovieViewController.m | ||
// PLShortVideoKitDemo | ||
// | ||
// Created by suntongmian on 2018/2/12. | ||
// Copyright © 2018年 Pili Engineering, Qiniu Inc. All rights reserved. | ||
// | ||
|
||
#import "H265MovieViewController.h" | ||
#import "MovieTransCodeViewController.h" | ||
#import "ClipMovieViewController.h" | ||
|
||
#define PLS_RGBCOLOR(r,g,b) [UIColor colorWithRed:(r)/255.0 green:(g)/255.0 blue:(b)/255.0 alpha:1] | ||
|
||
static NSString *reuseIdentifier = @"reuseIdentifier"; | ||
|
||
@interface H265MovieViewController () <UIAlertViewDelegate> | ||
{ | ||
NSMutableArray *_h265VideoArray; | ||
} | ||
|
||
@end | ||
|
||
@implementation H265MovieViewController | ||
|
||
- (void)viewDidLoad { | ||
[super viewDidLoad]; | ||
|
||
// Uncomment the following line to preserve selection between presentations. | ||
// self.clearsSelectionOnViewWillAppear = NO; | ||
|
||
// Uncomment the following line to display an Edit button in the navigation bar for this view controller. | ||
// self.navigationItem.rightBarButtonItem = self.editButtonItem; | ||
|
||
UIBarButtonItem *backItem = [[UIBarButtonItem alloc] initWithTitle:@"返回 " style:(UIBarButtonItemStylePlain) target:self action:@selector(clickBackItem:)]; | ||
self.navigationItem.leftBarButtonItem = backItem; | ||
|
||
[self loadH265Videos]; | ||
|
||
[self.tableView registerClass:[UITableViewCell class] forCellReuseIdentifier:reuseIdentifier]; | ||
} | ||
|
||
- (void)loadH265Videos { | ||
NSString *subpath = @"h265_video"; | ||
_h265VideoArray = [[NSMutableArray alloc] init]; | ||
|
||
NSBundle *bundle = [NSBundle mainBundle]; | ||
[_h265VideoArray addObjectsFromArray:[bundle pathsForResourcesOfType:@"mp4" inDirectory:subpath]]; | ||
[_h265VideoArray addObjectsFromArray:[bundle pathsForResourcesOfType:@"mov" inDirectory:subpath]]; | ||
} | ||
|
||
- (void)clickBackItem:(UIBarButtonItem *)item { | ||
[self dismissViewControllerAnimated:YES completion:nil]; | ||
} | ||
|
||
- (void)didReceiveMemoryWarning { | ||
[super didReceiveMemoryWarning]; | ||
// Dispose of any resources that can be recreated. | ||
} | ||
|
||
#pragma mark - Table view data source | ||
|
||
- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView { | ||
return 1; | ||
} | ||
|
||
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { | ||
return _h265VideoArray.count; | ||
} | ||
|
||
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { | ||
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:reuseIdentifier forIndexPath:indexPath]; | ||
cell.textLabel.text = [_h265VideoArray[indexPath.row] lastPathComponent]; | ||
|
||
return cell; | ||
} | ||
|
||
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { | ||
NSString *h265VideoPath = _h265VideoArray[indexPath.row]; | ||
|
||
UIAlertView *alertView = [[UIAlertView alloc] initWithTitle:@"提示" message:h265VideoPath delegate:self cancelButtonTitle:@"取消" otherButtonTitles:@"转码", nil]; | ||
alertView.tag = 10001; | ||
[alertView show]; | ||
} | ||
|
||
#pragma mark - | ||
- (void)alertView:(UIAlertView *)alertView clickedButtonAtIndex:(NSInteger)buttonIndex { | ||
if (10001 == alertView.tag) { | ||
NSURL *url = [NSURL fileURLWithPath:alertView.message]; | ||
|
||
if (1 == buttonIndex) { | ||
// 转码 | ||
MovieTransCodeViewController *transCodeViewController = [[MovieTransCodeViewController alloc] init]; | ||
transCodeViewController.url = url; | ||
[self presentViewController:transCodeViewController animated:YES completion:nil]; | ||
|
||
} | ||
} | ||
} | ||
|
||
#pragma mark -- 隐藏状态栏 | ||
- (BOOL)prefersStatusBarHidden { | ||
return YES; | ||
} | ||
|
||
#pragma mark -- dealloc | ||
- (void)dealloc { | ||
|
||
} | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.