vtranscoder 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.2
1
+ 0.0.3
data/lib/vtranscoder.rb CHANGED
@@ -40,16 +40,14 @@ class VTranscoder
40
40
  def take_screenshot(options)
41
41
  verify_ffmpeg_exists
42
42
  verify_source_exists
43
- options = { :size => '320*240' }.merge(options)
44
-
43
+
45
44
  ffmpeg_options = {
46
45
  :i => @source,
47
- :y => '',
46
+ :s => '320x240',
47
+ :vframes => 1,
48
48
  :ss => options[:at],
49
- :sameq => '',
50
- :t => '0.001',
51
- :s => options[:size]
52
- }
49
+ :an => '',
50
+ }.merge(options.has_key?(:options) ? options[:options] : {})
53
51
 
54
52
  output = run_ffmpeg( ffmpeg_options, options[:to], true )
55
53
  raise "unable to take screenshot:\n\n#{output}" unless File.exists?(options[:to])
@@ -77,7 +75,7 @@ class VTranscoder
77
75
  ffmpeg_output.scan(/Stream #0.([0-9]): (.*): (.*), (.*)/).each do |match|
78
76
  @meta[:streams][match[0].to_i] = { :type => match[1], :codec => match[2], :details => match[3] }
79
77
  end
80
- end
78
+ end
81
79
 
82
80
  def convert_with_options(destination,options)
83
81
  verify_ffmpeg_exists
data/vtranscoder.gemspec CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{vtranscoder}
8
- s.version = "0.0.2"
8
+ s.version = "0.0.3"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Chris Bielinski"]
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vtranscoder
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chris Bielinski