Comments (3)
Maybe like this:
ffmpeg -i "$INPUTFILE" -r 60 -filter_complex "\
color=c=white:s=2x720 [cursor]; \
[0:a] showwavespic=s=1920x720:split_channels=1:draw=full, fps=60 [stillwave];\
[0:a] showfreqs=mode=line:ascale=log:s=1920x180 [freqwave]; \
[0:a] showwaves=size=1920x180:mode=p2p [livewave]; \
[stillwave][cursor] overlay=(W*t)/(${DURATION}):0:shortest=1 [progress]; \
[livewave][progress] vstack[stacked]; \
[stacked][freqwave] vstack [out]; \
" -map [out] -map 0:a \
-c:v libx264 -c:a flac \
-y output_progr.mp4
Omitting the [freqwave] layer makes this 2-3x faster, but spectral analysis might be quite useful for reviews & annotation.
from clapshot.
More ideas. Detect media type by running a jq script on mediainfo JSON, and then convert into a video (like above) with an FFMPEG filter_complex chain. The current FFMPEG caller already injects nice progress tracking options, which should be useful for long audio files, too.
CREATE TABLE media_types (
type_name VARCHAR(255) NOT NULL PRIMARY KEY,
precedence INTEGER NOT NULL, -- run jq scripts in order from highest to lowest, pick the first that matches
jq_script TEXT, -- Stores the jq script for media type detection
ffmpeg_script TEXT -- Stores the FFMPEG script for converting media to video
);
Video
jq '[.media.track[]["@type"]] | if (index("Video") != null) then "Video" else empty end'
Audio
jq '[.media.track[]["@type"]] | if (index("Audio") != null) and (index("Video") == null) then "Audio" else empty end'
Image
jq '[.media.track[]["@type"]] | if (index("Image") != null) and (index("Video") == null) and (index("Audio") == null) then "Image" else empty end'
Use https://github.com/onelson/jq-rs to avoid shell invokes.
from clapshot.
Implemented in v0.7.0
from clapshot.
Related Issues (20)
- Connecting Server... HOT 2
- Video download button
- Looping for video player
- Video timeline jumps from 00:30:00:00 to 01:30:00:00 HOT 2
- Reopen log file on SIGUSR1
- Add "download" action to video context popup HOT 1
- Debian 12 required? HOT 3
- How to run behind Nginx Proxy Manager? HOT 1
- Unable to connect to docker demo HOT 1
- Include subtitles for visualization and correction HOT 3
- --host option in server is ignored in master HOT 1
- ARM64 version and Audio only version? HOT 8
- admin user can not see the videos of other users? HOT 5
- Trying to run the demo HOT 17
- [CONNECTION ERROR] Auth error at 'http://192.168.1.109/api/health': 502 - Bad Gateway HOT 2
- running small business in docker but without cloudflare? HOT 4
- Logrotate / SIGUSR1 kills Organizer
- Feature Request: FFMPEG scene cut detection and In/Out points. HOT 4
- Feature Request: CSS Styling/Theming? HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from clapshot.