diff options
| author | AppleDash <[email protected]> | 2021-03-29 23:06:38 -0400 |
|---|---|---|
| committer | AppleDash <[email protected]> | 2021-03-29 23:06:38 -0400 |
| commit | 77c312d5cc0f1eb024c458edc1fedd55bf5c3852 (patch) | |
| tree | 2ba027a92739d117ae1f892ebe6f2130ce7890d4 /lib/booru/image_processing/webm_processor.rb | |
| parent | 88227a3799271b6ac104d8878ecaedd269cff54c (diff) | |
More dedupe
Diffstat (limited to 'lib/booru/image_processing/webm_processor.rb')
| -rw-r--r-- | lib/booru/image_processing/webm_processor.rb | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/lib/booru/image_processing/webm_processor.rb b/lib/booru/image_processing/webm_processor.rb index 0e50cc4..3a75caa 100644 --- a/lib/booru/image_processing/webm_processor.rb +++ b/lib/booru/image_processing/webm_processor.rb @@ -1,5 +1,4 @@ # frozen_string_literal: true -require 'open3' require 'shellwords' module Booru @@ -10,19 +9,6 @@ module Booru FileUtils.ln_sf(@original_path, destination_path) end - - def additional_process - write_log "additional_process" - - # generate gifs from webms; no idea why this is special-cased. - duration = @metadata[:duration] / 10.0 - duration = 1 if duration == 0 - - [[250, :thumb], [150, :thumb_small], [50, :thumb_tiny]].each do |w, n| - # FIXME: Why is this so EXTREME? - exec "ffmpeg -loglevel warning -i #{@original_path.shellescape} -vf \"fps=1/#{duration},scale=w=#{w}:h=#{w}:force_original_aspect_ratio=decrease\" -vframes 10 -qscale:v 2 -f image2pipe -vcodec ppm - | convert -delay 50 -loop 0 - gif:- | gifsicle --no-warnings -O2 -o #{@directory}/#{n}.gif" - end - end end end end |
