Permalink
Browse files

Fix to avoid checking for framerate if not available

  • Loading branch information...
1 parent 83e266e commit 1fb5f861de7201c845192661c1935fa67177ce2c @manast manast committed Feb 23, 2013
Showing with 5 additions and 6 deletions.
  1. +5 −6 lib/navcodec.js
View
@@ -201,16 +201,15 @@ Media.prototype.transcode = function(cb){
var numFrames;
if(inputVideo){
numFrames = inputVideo.numFrames;
+ if(!numFrames && inputVideo.frameRate){
+ numFrames =
+ (this.duration * inputVideo.frameRate.num) / inputVideo.frameRate.den;
+ }
}
if(inputAudio){
numFrames = numFrames || inputAudio.numFrames;
}
-
- if(!numFrames){
- numFrames =
- (this.duration * inputVideo.frameRate.num) / inputVideo.frameRate.den;
- }
-
+
numFrames = numFrames || 1000;
var outputFiles = {};

0 comments on commit 1fb5f86

Please sign in to comment.