enigmamachine 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -13,6 +13,13 @@ begin
13
13
  gem.add_development_dependency "thoughtbot-shoulda", ">= 0"
14
14
  gem.add_dependency "dm-core", "=0.10.2"
15
15
  gem.add_dependency "eventmachine", "=0.12.10"
16
+ gem.add_dependency "rack-flash"
17
+ gem.add_dependency "ruby-debug"
18
+ gem.add_dependency "sinatra"
19
+ gem.add_dependency "datamapper"
20
+ gem.add_dependency "data_objects"
21
+ gem.add_dependency "do_sqlite3"
22
+ gem.add_dependency "thin"
16
23
 
17
24
  # gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
18
25
  end
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.1
1
+ 0.0.2
@@ -3,6 +3,8 @@ require File.dirname(__FILE__) + '/video'
3
3
  # An encoding profile which can be applied to a video. It has a name and is
4
4
  # composed of a bunch of EncodingTasks.
5
5
  #
6
+ # The Encoder class can shell out to FFMPeg and trigger the encoding of a Video.
7
+ #
6
8
  class Encoder
7
9
  include DataMapper::Resource
8
10
 
@@ -15,8 +17,7 @@ class Encoder
15
17
  #
16
18
  has n, :encoding_tasks
17
19
 
18
- # This is a candidate for being moved into the class Encoders::Video (which
19
- # could happily be renamed as something like Encoders::Ffmpeg).
20
+ # Kicks off an FFMpeg encode on a given video.
20
21
  #
21
22
  def encode(video)
22
23
  ffmpeg(encoding_tasks.first, video)
@@ -24,8 +25,9 @@ class Encoder
24
25
 
25
26
  private
26
27
 
27
- # If the encode method is pulled into another class, this one should go with
28
- # it, obviously.
28
+ # Shells out to ffmpeg and hits the given video with the parameters in the
29
+ # given task. Will call itself recursively until all tasks in this encoder's
30
+ # encoding_tasks are completed.
29
31
  #
30
32
  def ffmpeg(task, video)
31
33
  current_task_index = encoding_tasks.index(task)
metadata CHANGED
@@ -1,7 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: enigmamachine
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ prerelease: false
5
+ segments:
6
+ - 0
7
+ - 0
8
+ - 2
9
+ version: 0.0.2
5
10
  platform: ruby
6
11
  authors:
7
12
  - dave
@@ -9,39 +14,133 @@ autorequire:
9
14
  bindir: bin
10
15
  cert_chain: []
11
16
 
12
- date: 2010-03-05 00:00:00 +00:00
17
+ date: 2010-03-10 00:00:00 +00:00
13
18
  default_executable: enigmamachine
14
19
  dependencies:
15
20
  - !ruby/object:Gem::Dependency
16
21
  name: thoughtbot-shoulda
17
- type: :development
18
- version_requirement:
19
- version_requirements: !ruby/object:Gem::Requirement
22
+ prerelease: false
23
+ requirement: &id001 !ruby/object:Gem::Requirement
20
24
  requirements:
21
25
  - - ">="
22
26
  - !ruby/object:Gem::Version
27
+ segments:
28
+ - 0
23
29
  version: "0"
24
- version:
30
+ type: :development
31
+ version_requirements: *id001
25
32
  - !ruby/object:Gem::Dependency
26
33
  name: dm-core
27
- type: :runtime
28
- version_requirement:
29
- version_requirements: !ruby/object:Gem::Requirement
34
+ prerelease: false
35
+ requirement: &id002 !ruby/object:Gem::Requirement
30
36
  requirements:
31
37
  - - "="
32
38
  - !ruby/object:Gem::Version
39
+ segments:
40
+ - 0
41
+ - 10
42
+ - 2
33
43
  version: 0.10.2
34
- version:
44
+ type: :runtime
45
+ version_requirements: *id002
35
46
  - !ruby/object:Gem::Dependency
36
47
  name: eventmachine
37
- type: :runtime
38
- version_requirement:
39
- version_requirements: !ruby/object:Gem::Requirement
48
+ prerelease: false
49
+ requirement: &id003 !ruby/object:Gem::Requirement
40
50
  requirements:
41
51
  - - "="
42
52
  - !ruby/object:Gem::Version
53
+ segments:
54
+ - 0
55
+ - 12
56
+ - 10
43
57
  version: 0.12.10
44
- version:
58
+ type: :runtime
59
+ version_requirements: *id003
60
+ - !ruby/object:Gem::Dependency
61
+ name: rack-flash
62
+ prerelease: false
63
+ requirement: &id004 !ruby/object:Gem::Requirement
64
+ requirements:
65
+ - - ">="
66
+ - !ruby/object:Gem::Version
67
+ segments:
68
+ - 0
69
+ version: "0"
70
+ type: :runtime
71
+ version_requirements: *id004
72
+ - !ruby/object:Gem::Dependency
73
+ name: ruby-debug
74
+ prerelease: false
75
+ requirement: &id005 !ruby/object:Gem::Requirement
76
+ requirements:
77
+ - - ">="
78
+ - !ruby/object:Gem::Version
79
+ segments:
80
+ - 0
81
+ version: "0"
82
+ type: :runtime
83
+ version_requirements: *id005
84
+ - !ruby/object:Gem::Dependency
85
+ name: sinatra
86
+ prerelease: false
87
+ requirement: &id006 !ruby/object:Gem::Requirement
88
+ requirements:
89
+ - - ">="
90
+ - !ruby/object:Gem::Version
91
+ segments:
92
+ - 0
93
+ version: "0"
94
+ type: :runtime
95
+ version_requirements: *id006
96
+ - !ruby/object:Gem::Dependency
97
+ name: datamapper
98
+ prerelease: false
99
+ requirement: &id007 !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ segments:
104
+ - 0
105
+ version: "0"
106
+ type: :runtime
107
+ version_requirements: *id007
108
+ - !ruby/object:Gem::Dependency
109
+ name: data_objects
110
+ prerelease: false
111
+ requirement: &id008 !ruby/object:Gem::Requirement
112
+ requirements:
113
+ - - ">="
114
+ - !ruby/object:Gem::Version
115
+ segments:
116
+ - 0
117
+ version: "0"
118
+ type: :runtime
119
+ version_requirements: *id008
120
+ - !ruby/object:Gem::Dependency
121
+ name: do_sqlite3
122
+ prerelease: false
123
+ requirement: &id009 !ruby/object:Gem::Requirement
124
+ requirements:
125
+ - - ">="
126
+ - !ruby/object:Gem::Version
127
+ segments:
128
+ - 0
129
+ version: "0"
130
+ type: :runtime
131
+ version_requirements: *id009
132
+ - !ruby/object:Gem::Dependency
133
+ name: thin
134
+ prerelease: false
135
+ requirement: &id010 !ruby/object:Gem::Requirement
136
+ requirements:
137
+ - - ">="
138
+ - !ruby/object:Gem::Version
139
+ segments:
140
+ - 0
141
+ version: "0"
142
+ type: :runtime
143
+ version_requirements: *id010
45
144
  description: A RESTful video encoder which you can use as either a front-end to ffmpeg or headless on a server.
46
145
  email: dave@caprica
47
146
  executables:
@@ -117,25 +216,27 @@ required_ruby_version: !ruby/object:Gem::Requirement
117
216
  requirements:
118
217
  - - ">="
119
218
  - !ruby/object:Gem::Version
219
+ segments:
220
+ - 0
120
221
  version: "0"
121
- version:
122
222
  required_rubygems_version: !ruby/object:Gem::Requirement
123
223
  requirements:
124
224
  - - ">="
125
225
  - !ruby/object:Gem::Version
226
+ segments:
227
+ - 0
126
228
  version: "0"
127
- version:
128
229
  requirements: []
129
230
 
130
231
  rubyforge_project:
131
- rubygems_version: 1.3.5
232
+ rubygems_version: 1.3.6
132
233
  signing_key:
133
234
  specification_version: 3
134
235
  summary: A RESTful video encoder.
135
236
  test_files:
136
- - test/test_video.rb
137
- - test/support/blueprints.rb
138
237
  - test/helper.rb
238
+ - test/support/blueprints.rb
239
+ - test/test_encoder.rb
139
240
  - test/test_encoder_queue.rb
140
241
  - test/test_enigmamachine.rb
141
- - test/test_encoder.rb
242
+ - test/test_video.rb