easyvideo_utils 0.3.0 → 0.3.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a91b8ba51bbff313106e09945d19827ebaa2c462d97b3bf0102eaa07b2112e60
4
- data.tar.gz: ae94c800fd3b1dfc8f60533845479d7b1b51d7828909172638159adf189b8d9a
3
+ metadata.gz: 6cf96bd7cae7c924f5bc6259a374b4f3869f5a99aa936f9bc965ade2678b3301
4
+ data.tar.gz: 2794a519340d3142e0958dd35b46d9f62776978ea1ecd3835370afab929f260d
5
5
  SHA512:
6
- metadata.gz: 35d68326073bf0963ce7d3d5412315697ca154a9d1c3fd9194eb076ec057f8f0260468f6b7685b796b3d39ba05d09408d8738e1142b397e682d67fd8886485ba
7
- data.tar.gz: 80ed22acbfa4ae9991480c0b9af42d5cf01fcc0e964fc8ce659c17aaf1d2daabb285e1c2a7acd025446662a34a9e412f58ce6a5ce1ccecfcd221d2a47d994f51
6
+ metadata.gz: e705fe92de0df9800359f0a39b0bec628c9b423a4e8ab0371a4d6bb65d45d01be14b0c1e719243a0d8df693e871db5209028a5009d70caf510dd668cb8a78de8
7
+ data.tar.gz: 2bea5237a862fb1de00261d4c43a91dd7a1215e558f63eab8b2045d587c2c27f6e054a6d5ed4039bf0c6cb0357b723ceb1903dd88551d6bbadac5b0c5d365188
checksums.yaml.gz.sig CHANGED
Binary file
data.tar.gz.sig CHANGED
Binary file
@@ -20,8 +20,8 @@ module CommandHelper
20
20
  " %s %s %s" % ['*'.blue, command, desc.to_s.light_black]
21
21
  end
22
22
 
23
- s = a.map {|x| format_command.call(x) }.join("\n")
24
- puts s
23
+ puts a.map {|x| format_command.call(x) }.join("\n")
24
+
25
25
  end
26
26
 
27
27
  def search(s)
@@ -39,6 +39,8 @@ class EasyVideoUtils
39
39
  * concat # concatenate 2 or more videos
40
40
  * convert # alias for transcode
41
41
  * capture # capture the desktop at 1024x768
42
+ * create_poster # Video created from audio file + static image
43
+ * create_slideshow # Combines images to create a video. Defaults to 5 seconds per image
42
44
  * extract_images # Extracts images at 1 FPS by default
43
45
  * play # plays the video using mplayer
44
46
  * preview # plays the video using ffplay
@@ -112,7 +114,25 @@ class EasyVideoUtils
112
114
 
113
115
  run command, show
114
116
 
115
- end
117
+ end
118
+
119
+ # creates a video from an audio file along with a single image file
120
+ #
121
+ def create_poster(audiox=nil, imagex=nil, image: imagex,
122
+ audio: audiox, show: false)
123
+ command = "ffmpeg -loop 1 -i #{image} -i #{audio} -c:v libx264 -c:a " +
124
+ "aac -strict experimental -b:a 192k -shortest #{@file_out}"
125
+ run command, show
126
+ end
127
+
128
+ def create_slideshow(ext: '.jpg', image_duration: 5, show: false)
129
+
130
+ file_mask = @file_in || "image-%03d" + ext
131
+ command = "ffmpeg -r 1/#{image_duration} -i #{file_mask} -c:v " +
132
+ "libx264 -r 30 -pix_fmt yuv420p #{@file_out}"
133
+ run command, show
134
+
135
+ end
116
136
 
117
137
  # Duration returned in seconds
118
138
  #
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: easyvideo_utils
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Robertson
@@ -35,7 +35,7 @@ cert_chain:
35
35
  iOODRzCT1NjcNTH5nzIOVNDgsjVdBcyabDtEoJ+ABRBRC3QbmGexUCnpCQVsGRJh
36
36
  aGOV1YBw3DOVQYevaOX+Vxuw
37
37
  -----END CERTIFICATE-----
38
- date: 2019-05-06 00:00:00.000000000 Z
38
+ date: 2019-05-07 00:00:00.000000000 Z
39
39
  dependencies:
40
40
  - !ruby/object:Gem::Dependency
41
41
  name: c32
metadata.gz.sig CHANGED
Binary file