Initial commit: video effects processing system
Add S-expression based video effects pipeline with modular effect definitions, constructs, and recipe files. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
55
recipe-all-effects-modular.sexp
Normal file
55
recipe-all-effects-modular.sexp
Normal file
@@ -0,0 +1,55 @@
|
||||
;; All Effects Showcase (Modular Version)
|
||||
;; Uses data-driven effect presets for easy customization
|
||||
(recipe "all-effects-showcase-modular"
|
||||
:version "1.0"
|
||||
:encoding (:codec "libx264" :crf 20 :preset "medium" :audio-codec "aac" :fps 30)
|
||||
|
||||
;; Standard libraries - analyzers, effects, constructs
|
||||
(include :path "libs/standard-analyzers.sexp")
|
||||
(include :path "libs/all-effects.sexp")
|
||||
(include :path "libs/standard-constructs.sexp")
|
||||
|
||||
;; Effect preset - SWAP THIS to change the entire effect palette
|
||||
(include all-42-preset :path "effect-presets/all-42.sexp")
|
||||
|
||||
;; Sources with auto-detected info
|
||||
(def video-a (source :path "monday.webm"))
|
||||
(def video-b (source :path "new.webm"))
|
||||
(def video-c (source :path "ecstacy.mp4"))
|
||||
|
||||
;; Video info analysis (duration, resolution, fps, etc.)
|
||||
(def video-a-info (-> video-a (analyze video-info)))
|
||||
(def video-b-info (-> video-b (analyze video-info)))
|
||||
(def video-c-info (-> video-c (analyze video-info)))
|
||||
|
||||
(def videos (list video-a video-b video-c))
|
||||
(def video-infos (list video-a-info video-b-info video-c-info))
|
||||
|
||||
;; Audio
|
||||
(def audio (source :path "dizzy.mp3"))
|
||||
|
||||
;; Analysis
|
||||
(def beats-data (-> audio (analyze beats)))
|
||||
(def bass-data (-> audio (analyze bass)))
|
||||
(def energy-data (-> audio (analyze energy)))
|
||||
|
||||
;; Analyzers dict for binding resolution (use dict fn, not literal, for symbol resolution)
|
||||
(def analyzers (dict :bass bass-data :energy energy-data))
|
||||
|
||||
;; Segments - now just one clean call!
|
||||
;; Note: kwargs use underscores (planner converts - to _)
|
||||
(def segments (cycle-effects-preset
|
||||
:beats beats-data
|
||||
:videos videos
|
||||
:video_infos video-infos
|
||||
:preset all-42-preset
|
||||
:analyzers analyzers
|
||||
:beats_per_segment 21))
|
||||
|
||||
(assert (> (len segments) 0) "No segments created - all videos too short")
|
||||
|
||||
;; Sequence and output
|
||||
(def showcase (-> segments
|
||||
(sequence :resize-mode :fit :priority :width)))
|
||||
|
||||
(mux showcase audio))
|
||||
Reference in New Issue
Block a user