GithubHelp home page GithubHelp logo

gluemp4's Introduction

GlueMP4

GlueMP4 is a simple driver script for ffmpeg to trim, crop and concatenate MP4 video fragments. It was developed to combine fragments of a lecture, recorded by screencasting on a tablet, into a single video clip.

Installation

pip install git+https://github.com/tovrstra/gluemp4.git@master

You also need to install ffmpeg separately:

  • On Fedora Linux, first activate RPM Fusion. Then run the following install command:

    sudo dnf install ffmpeg --allowerasing

Usage

Make a YAML config file config.yaml describing the fragments going into the video clip:

fragments:
- ["some_file1.mp4", "width:height:xleft:ytop", start, stop or null]
- ["some_file2.mp4", "width:height:xleft:ytop", start, stop or null]
- ...
output: final_output.mp4

Then run gluemp4 config.yaml.

How to determine the cropping region?

Take a single snapshot from your video, e.g. with ffmpeg at second 3 of the video:

ffmpeg -i input.mp4 -ss 3.0 -f image2 -vframes 1 snapshot.jpeg

Then open the image snapshot.jpeg in teh Gimp and draw a rectangle with the cropping tool, e.g. one that fits neatly your slide. Do not crop yet, just read the parameters of the cropping window and copy them to the config file.

gluemp4's People

Contributors

pre-commit-ci[bot] avatar tovrstra avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.