Install FFmpeg with homebrew. You'll need to install it with a couple flags for webm and the AAC audio codec.
brew install ffmpeg --with-libvpx --with-libvorbis --with-fdk-aac --with-opus
There’s been a lot of buzz in the recent year around Ethereum cryptocurrency and not without cause. Smart contracts is a new exciting concept that Ethereum introduced. What is it? Ethereum is a distributed ledger (same as bitcoin) but this ledger may contain not only accounts and balances, but also computer programs. Programs are first class citizen on Ethereum blockchain and they are not only stored on it, but they provide functions that might be called (same as you may deposit or withdraw money on the ledger’s account) and store its state on the blockchain. For software developers it would be a good analogy that Ethereum Blockchain is a something similar to a VM. There is a virtual machine with instances of objects that are stored in its memory (smart contract). Instances contain not only code that might be executed but also its state. The main difference is that the everything is stored on distributed ledger instead of RAM. This metaphor is not perfect and simplifie
A list of useful commands for the ffmpeg command line tool.
Download FFmpeg: https://www.ffmpeg.org/download.html
Full documentation: https://www.ffmpeg.org/ffmpeg.html
Basic conversion
Brought to you by Headjack
FFmpeg is one of the most powerful tools for video transcoding and manipulation, but it's fairly complex and confusing to use. That's why I decided to create this cheat sheet which shows some of the most often used commands.
Let's start with some basics:
ffmpeg
calls the FFmpeg application in the command line window, could also be the full path to the FFmpeg binary or .exe fileThese are a few quick easy ffmpeg command lines that can be used to make oft-used video formats. I use them a lot so I wrote them down in a txt file but I converted it to markdown to upload here and access on all my pcs.
Feel free to use 'em. I've gathered them through superuser posts, wiki trawls, and personal experience.
-movflags faststart
to make mp4 files have their headers at the beginning of the file, allowing them to be streamed (i.e. played even if only part of the file is downloaded).libfdk_aac
isnt available (it's the only good aac enc) use libmp3lame
.-preset X
to use mp4 enc presets, like slow or superfast. (veryfast or fast is ok)c:v
refers to the video codec used (codec: video). Likewise, c:a
is audio. If you're using -map
or something, this can be extended (-c:a:0
: codec: audio: stream 0)#!/bin/bash | |
## Script to merge all mp4 videos in current directory (recursively 2 levels) | |
## And update chapter marks to retain the folder/filename | |
## Script for merging videos | |
filename=`basename pwd` | |
current=`pwd` |
const spawn = require('child_process').spawn; | |
const parent = process.argv[2]; | |
let videos = []; | |
if(process.argv[2]){ | |
// Parent Path | |
const start = parseInt(process.argv[3]); | |
const end = parseInt(process.argv[4]); | |
for (let i = start; i <= end; i++) { | |
videos.push(i); |
var ffmpeg = require('ffmpeg'); | |
try { | |
var process = new ffmpeg('example.mp4'); | |
process.then(function (video) { | |
console.log('The video is ready to be processed'); | |
var watermarkPath = 'watermark-suissa.png', | |
newFilepath = './video-com-watermark.mp4', | |
settings = { | |
position : "SE" // Position: NE NC NW SE SC SW C CE CW |
Get nodejs from Node
node server.js