video2gif 0.0.34 → 0.0.35
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/video2gif/ffmpeg.rb +6 -6
- data/lib/video2gif/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d7c44e514f51abaa8a8e62d5a5d4c10c773abc153c81cf681a5b52aa5a535e35
|
4
|
+
data.tar.gz: d0c29308eb5de00e89f09d3361062b12936bb998ca8102a8b2585036bcd8e894
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2889843a7689713191f3adebdd0b035ff3cfbeed0a991ad70d6af8ca8d803b59ad77e19a3f4321a1e19a07b9184e3d0c8ae14a328b94e9524719d690d4b48907
|
7
|
+
data.tar.gz: a4aedbe2ea00eb8d3ac5904041bf426541a57e1e64076fec0945099ea437467c8f8da812747bb4033d510481878de14db780edcd020ad30b98c55f27175290ce
|
data/Gemfile.lock
CHANGED
data/lib/video2gif/ffmpeg.rb
CHANGED
@@ -40,7 +40,7 @@ module Video2gif
|
|
40
40
|
end
|
41
41
|
|
42
42
|
def self.fps(options)
|
43
|
-
"fps=#{ options[:fps] ||
|
43
|
+
"fps=#{ options[:fps] || 20 }"
|
44
44
|
end
|
45
45
|
|
46
46
|
def self.crop(options)
|
@@ -59,8 +59,8 @@ module Video2gif
|
|
59
59
|
|
60
60
|
zscale_parameters << 'dither=none'
|
61
61
|
zscale_parameters << 'filter=lanczos'
|
62
|
-
zscale_parameters << "width=#{ options[:width] ||
|
63
|
-
zscale_parameters << "height=trunc(#{ options[:width] ||
|
62
|
+
zscale_parameters << "width=#{ options[:width] || 480 }"
|
63
|
+
zscale_parameters << "height=trunc(#{ options[:width] || 480 }/dar)"
|
64
64
|
|
65
65
|
'zscale=' + zscale_parameters.join(':')
|
66
66
|
end
|
@@ -92,8 +92,8 @@ module Video2gif
|
|
92
92
|
|
93
93
|
scale_parameters << 'flags=lanczos'
|
94
94
|
scale_parameters << 'sws_dither=none'
|
95
|
-
scale_parameters << "width=#{ options[:width] ||
|
96
|
-
scale_parameters << "height=trunc(#{ options[:width] ||
|
95
|
+
scale_parameters << "width=#{ options[:width] || 480 }"
|
96
|
+
scale_parameters << "height=trunc(#{ options[:width] || 480 }/dar)"
|
97
97
|
|
98
98
|
'scale=' + scale_parameters.join(':')
|
99
99
|
end
|
@@ -131,7 +131,7 @@ module Video2gif
|
|
131
131
|
drawtext_parameters << "y='#{ options[:ypos] || "(main_h-line_h*1.5*#{count_of_lines})" }'"
|
132
132
|
drawtext_parameters << "fontsize='#{ options[:textsize] || 32 }'"
|
133
133
|
drawtext_parameters << "fontcolor='#{ options[:textcolor] || 'white' }'"
|
134
|
-
drawtext_parameters << "borderw='#{ options[:textborder] ||
|
134
|
+
drawtext_parameters << "borderw='#{ options[:textborder] || 2 }'"
|
135
135
|
drawtext_parameters << "fontfile='#{ options[:textfont] || 'Arial'}'\\\\:style='#{options[:textvariant] || 'Bold' }'"
|
136
136
|
drawtext_parameters << "text='#{text(options)}'"
|
137
137
|
|
data/lib/video2gif/version.rb
CHANGED