Module: FFMpegCommand

Extended by:
FFMpegCommand
Included in:
FFMpegCommand
Defined in:
lib/rffmpeg/ffmpeg_command.rb

Constant Summary collapse

@@commands =
[]

Instance Method Summary collapse

Instance Method Details

#add(cmd) ⇒ Object



6
7
8
# File 'lib/rffmpeg/ffmpeg_command.rb', line 6

def add(cmd)
  @@commands << cmd
end

#add_at(cmd, pos) ⇒ Object



10
11
12
# File 'lib/rffmpeg/ffmpeg_command.rb', line 10

def add_at(cmd, pos)
  @@commands.insert(pos, cmd)
end

#clearObject



14
15
16
# File 'lib/rffmpeg/ffmpeg_command.rb', line 14

def clear
  @@commands.clear
end

#runObject



18
19
20
21
22
23
24
# File 'lib/rffmpeg/ffmpeg_command.rb', line 18

def run
  str = "ffmpeg"
  @@commands.each do |cmd|
    str << " " + cmd
  end
  str
end