Skip to content

Commit

Permalink
filename macro bug fixed.
Browse files Browse the repository at this point in the history
SCVideoPlayerView duplicated bug fixed
  • Loading branch information
AliThink committed Feb 24, 2016
1 parent 4842d21 commit 3cfb186
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 5 deletions.
4 changes: 2 additions & 2 deletions WechatShortVideo.podspec
@@ -1,11 +1,11 @@
Pod::Spec.new do |s|
s.name = "WechatShortVideo"
s.version = "0.1.8"
s.version = "0.1.9"
s.summary = "Short Video Capture like Wechat App"
s.homepage = "https://github.com/AliThink/WechatShortVideo"
s.license = "MIT"
s.author = { "AliThink" => "cloudsthinker@126.com" }
s.source = { :git => "https://github.com/AliThink/WechatShortVideo.git", :tag => "v0.1.8" }
s.source = { :git => "https://github.com/AliThink/WechatShortVideo.git", :tag => "v0.1.9" }
s.source_files = "WechatShortVideo/**/*.{h,m}"
s.resources = ["WechatShortVideo/**/*.{xib}","WechatShortVideo/**/*.{png}"]
s.platform = :ios, '7.0'
Expand Down
5 changes: 2 additions & 3 deletions WechatShortVideo/WechatShortVideoConfig.h
Expand Up @@ -37,15 +37,14 @@
#define WechatShortVideo_WechatShortVideoConfig_h

#import "CALayer+AddUIColor.h"
#import <UIKit/UIKit.h>

//Video file time length limitation (Maximum Seconds)
#define VIDEO_MAX_TIME 8.0
//Video file time length limitation (Minimum Seconds)
#define VIDEO_VALID_MINTIME 0.8
//Video filename
#define VIDEO_DEFAULTNAME @"videoReadyToUpload.mov"
//Video filepath
#define VIDEO_OUTPUTFILE [NSURL fileURLWithPath:[PATH_OF_DOCUMENT stringByAppendingPathComponent:VIDEO_DEFAULTNAME]]
static NSString *VIDEO_DEFAULTNAME = @"videoReadyToUpload.mov";

//Tip Strings pressed on the record area
#define OPERATE_RECORD_TIP @"↑上移取消"
Expand Down
10 changes: 10 additions & 0 deletions WechatShortVideo/WechatShortVideoController.m
Expand Up @@ -33,6 +33,7 @@
#import "SCRecordSessionManager.h"
#import "MBProgressHUD.h"


@interface WechatShortVideoController () <SCRecorderDelegate, SCAssetExportSessionDelegate, MBProgressHUDDelegate>
@property (weak, nonatomic) IBOutlet UIView *scanPreviewView;
@property (weak, nonatomic) IBOutlet UIView *operatorView;
Expand All @@ -56,6 +57,9 @@ @implementation WechatShortVideoController {

//Preview
SCPlayer *_player;

//Video filepath
NSURL *VIDEO_OUTPUTFILE;
}

@synthesize delegate;
Expand All @@ -74,6 +78,8 @@ - (IBAction)closeAction:(UIButton *)sender {
- (void)viewDidLoad {
[super viewDidLoad];
// Do any additional setup after loading the view from its nib.
VIDEO_OUTPUTFILE = [NSURL fileURLWithPath:[PATH_OF_DOCUMENT stringByAppendingPathComponent:VIDEO_DEFAULTNAME]];

captureValidFlag = NO;

[self configRecorder];
Expand Down Expand Up @@ -249,6 +255,10 @@ - (void)cancelCaptureWithSaveFlag:(BOOL)saveFlag {

#pragma mark - Record finish Preview and save
- (void)configPreviewMode {
if ([self.scanPreviewView viewWithTag:400]) {
return;
}

[self hideCaptureBtn];
self.captureRealBtn.enabled = NO;

Expand Down
Binary file not shown.

0 comments on commit 3cfb186

Please sign in to comment.