one-k-rmov 0.2.2 → 0.2.3
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG +2 -0
- data/Manifest +1 -0
- data/Rakefile +1 -1
- data/rmov.gemspec +2 -2
- data/spec/quicktime/hd_track_spec.rb +105 -0
- metadata +2 -1
data/CHANGELOG
CHANGED
data/Manifest
CHANGED
data/Rakefile
CHANGED
@@ -2,7 +2,7 @@ require 'rubygems'
|
|
2
2
|
require 'rake'
|
3
3
|
require 'echoe'
|
4
4
|
|
5
|
-
Echoe.new('rmov', '0.2.
|
5
|
+
Echoe.new('rmov', '0.2.3') do |p|
|
6
6
|
p.summary = "Ruby wrapper for the QuickTime C API."
|
7
7
|
p.description = "Ruby wrapper for the QuickTime C API. Updates by 1K include exposing some movie properties such as codec and audio channel descriptions"
|
8
8
|
p.url = "http://github.com/ryanb/rmov"
|
data/rmov.gemspec
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = %q{rmov}
|
5
|
-
s.version = "0.2.
|
5
|
+
s.version = "0.2.3"
|
6
6
|
|
7
7
|
s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
|
8
8
|
s.authors = ["Ryan Bates, with updates by 1K Studios, LLC"]
|
@@ -11,7 +11,7 @@ Gem::Specification.new do |s|
|
|
11
11
|
s.email = %q{ryan (at) railscasts (dot) com}
|
12
12
|
s.extensions = ["ext/extconf.rb"]
|
13
13
|
s.extra_rdoc_files = ["CHANGELOG", "ext/exporter.c", "ext/extconf.rb", "ext/movie.c", "ext/rmov_ext.c", "ext/rmov_ext.h", "ext/track.c", "lib/quicktime/exporter.rb", "lib/quicktime/movie.rb", "lib/quicktime/track.rb", "lib/rmov.rb", "LICENSE", "README.rdoc", "tasks/setup.rake", "tasks/spec.rake", "TODO"]
|
14
|
-
s.files = ["CHANGELOG", "ext/exporter.c", "ext/extconf.rb", "ext/movie.c", "ext/rmov_ext.c", "ext/rmov_ext.h", "ext/track.c", "lib/quicktime/exporter.rb", "lib/quicktime/movie.rb", "lib/quicktime/track.rb", "lib/rmov.rb", "LICENSE", "Manifest", "Rakefile", "README.rdoc", "spec/fixtures/settings.st", "spec/quicktime/exporter_spec.rb", "spec/quicktime/movie_spec.rb", "spec/quicktime/track_spec.rb", "spec/spec.opts", "spec/spec_helper.rb", "tasks/setup.rake", "tasks/spec.rake", "TODO", "rmov.gemspec"]
|
14
|
+
s.files = ["CHANGELOG", "ext/exporter.c", "ext/extconf.rb", "ext/movie.c", "ext/rmov_ext.c", "ext/rmov_ext.h", "ext/track.c", "lib/quicktime/exporter.rb", "lib/quicktime/movie.rb", "lib/quicktime/track.rb", "lib/rmov.rb", "LICENSE", "Manifest", "Rakefile", "README.rdoc", "spec/fixtures/settings.st", "spec/quicktime/exporter_spec.rb", "spec/quicktime/movie_spec.rb", "spec/quicktime/track_spec.rb", "spec/quicktime/hd_track_spec.rb", "spec/spec.opts", "spec/spec_helper.rb", "tasks/setup.rake", "tasks/spec.rake", "TODO", "rmov.gemspec"]
|
15
15
|
s.has_rdoc = true
|
16
16
|
s.homepage = %q{http://github.com/ryanb/rmov}
|
17
17
|
s.rdoc_options = ["--line-numbers", "--inline-source", "--title", "Rmov", "--main", "README.rdoc"]
|
@@ -0,0 +1,105 @@
|
|
1
|
+
require File.dirname(__FILE__) + '/../spec_helper.rb'
|
2
|
+
|
3
|
+
describe QuickTime::Track do
|
4
|
+
describe "HD2.mov" do
|
5
|
+
before(:each) do
|
6
|
+
@movie = QuickTime::Movie.open(File.dirname(__FILE__) + '/../fixtures/HD2.mov')
|
7
|
+
end
|
8
|
+
|
9
|
+
describe "HD2.mov video track" do
|
10
|
+
before(:each) do
|
11
|
+
@track = @movie.video_tracks.first
|
12
|
+
end
|
13
|
+
|
14
|
+
it "should have a codec of Apple ProRes 422 (HQ)" do
|
15
|
+
@track.codec.should == "Apple ProRes 422 (HQ)"
|
16
|
+
end
|
17
|
+
|
18
|
+
end
|
19
|
+
|
20
|
+
describe "HD2.mov audio track" do
|
21
|
+
before(:each) do
|
22
|
+
@track = @movie.audio_tracks.first
|
23
|
+
end
|
24
|
+
|
25
|
+
it "should have a volume of 1.0" do
|
26
|
+
@track.volume.should == 1.0
|
27
|
+
end
|
28
|
+
|
29
|
+
it "should have a channel count" do
|
30
|
+
@track.channel_count.should == 2
|
31
|
+
end
|
32
|
+
|
33
|
+
it "should have an audio channel map size" do
|
34
|
+
@track.channel_map.size.should == 2
|
35
|
+
end
|
36
|
+
|
37
|
+
it "should have an audio channel map with tags" do
|
38
|
+
@track.channel_map[0][:assignment].should == :left
|
39
|
+
@track.channel_map[1][:assignment].should == :right
|
40
|
+
end
|
41
|
+
|
42
|
+
it "should have all audio tracks > 1 mono" do
|
43
|
+
@movie.audio_tracks[1..-1].each do |tr|
|
44
|
+
tr.channel_map[0][:assignment].should == :mono
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
end
|
49
|
+
|
50
|
+
end
|
51
|
+
|
52
|
+
describe "SD3v2.mov audio tracks" do
|
53
|
+
before(:each) do
|
54
|
+
@movie = QuickTime::Movie.open(File.dirname(__FILE__) + '/../fixtures/SD3v2.mov')
|
55
|
+
end
|
56
|
+
|
57
|
+
it "has audio track 0 with left/right" do
|
58
|
+
track = @movie.audio_tracks[0]
|
59
|
+
track.channel_map.should_not == nil
|
60
|
+
track.channel_map[0][:assignment].should == :left
|
61
|
+
track.channel_map[1][:assignment].should == :right
|
62
|
+
end
|
63
|
+
|
64
|
+
it "has audio track 1 with left/right" do
|
65
|
+
track = @movie.audio_tracks[1]
|
66
|
+
track.channel_map.should_not == nil
|
67
|
+
track.channel_map[0][:assignment].should == :left
|
68
|
+
end
|
69
|
+
|
70
|
+
it "has audio tracks with proper assignments" do
|
71
|
+
channel_maps = @movie.audio_tracks.collect {|tr| tr.channel_map}
|
72
|
+
channel_maps.should == [
|
73
|
+
[{:assignment => :left}, {:assignment => :right}],
|
74
|
+
[{:assignment => :left}],
|
75
|
+
[{:assignment => :right}],
|
76
|
+
[{:assignment => :center}],
|
77
|
+
[{:assignment => :LFEScreen}],
|
78
|
+
[{:assignment => :leftSurround}],
|
79
|
+
[{:assignment => :rightSurround}],
|
80
|
+
]
|
81
|
+
end
|
82
|
+
|
83
|
+
end
|
84
|
+
|
85
|
+
|
86
|
+
describe "SD1.mov audio tracks" do
|
87
|
+
before(:each) do
|
88
|
+
@movie = QuickTime::Movie.open(File.dirname(__FILE__) + '/../fixtures/SD1.mov')
|
89
|
+
end
|
90
|
+
|
91
|
+
it "has audio tracks with proper assignments" do
|
92
|
+
channel_maps = @movie.audio_tracks.collect {|tr| tr.channel_map}
|
93
|
+
channel_maps.should == [
|
94
|
+
[{:assignment => :left}, {:assignment => :right}],
|
95
|
+
[{:assignment => :mono}],
|
96
|
+
[{:assignment => :mono}],
|
97
|
+
[{:assignment => :mono}],
|
98
|
+
[{:assignment => :mono}],
|
99
|
+
[{:assignment => :mono}],
|
100
|
+
[{:assignment => :mono}],
|
101
|
+
]
|
102
|
+
end
|
103
|
+
end
|
104
|
+
|
105
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: one-k-rmov
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ryan Bates, with updates by 1K Studios, LLC
|
@@ -56,6 +56,7 @@ files:
|
|
56
56
|
- spec/quicktime/exporter_spec.rb
|
57
57
|
- spec/quicktime/movie_spec.rb
|
58
58
|
- spec/quicktime/track_spec.rb
|
59
|
+
- spec/quicktime/hd_track_spec.rb
|
59
60
|
- spec/spec.opts
|
60
61
|
- spec/spec_helper.rb
|
61
62
|
- tasks/setup.rake
|