Bonum Certa Men Certa

Adding, Seaming Together, Merging, or Concatenating Videos From the Command Line With FFMPEG (Scripting for Streamlining of Workflows)

Video download link



Summary: In order to enrich the looks of videos with almost no extra time/effort (all scripted, no GUIs should be needed) use ffmpeg with the concat operator; but there are several big gotchas, namely lack of sound and need for consistency across formats/codecs and even sampling rates

TODAY we focused on some site 'logistics' and especially dealt with video and sound. The goal is to automate some tasks and/or improve the presentation of multimedia using Free software. Free as in freedom...



Frankly, the tool we used to generate some video segments was an "online" thing called Canva (never heard of it before, but it seems powerful enough and doesn't require downloading anything, logging in etc. -- not even an E-mail address). On the face of it, problem solved! But no... it gets trickier from then on. I spent many hours working around barriers.

Well, ffmpeg is very powerful and extremely versatile. However, as it turns out, ffmpeg will first need to convert .mp4 files downloaded from there (Canva) so as to incorporate sound, even if it's just mute (inaudible sound track).

For this reason and for that purpose, as per people who had similar issues concatenation tracks that lack sound (merged or combined with some that do have sound), run a command as follows (depending on the sampling rate, 48000 in my case, or else the sound/pitch will be funny).

ffmpeg -i "file.mp4" -f lavfi -i anullsrc=cl=mono:r=48000 -shortest -y "file-new.mp4"

Assuming you now have a track that is compatible with what you'd merge it with, ensure that the original is moreover re-encoded for it to be applied consistently. As I always record as WebM, I need to then run (for a video like the above):

ffmpeg -i video-ffmpeg-concat.webm -c:v libx264 -preset slow video-ffmpeg-concat.mp4

This yields something suitable as it must be strictly compatible in sampling, codec type, and other factors. That's a limitation in ffmpeg. This is a common issue for a lot of people and it took me hours to overcome (many trials and errors). I wished to document this as other people too got stuck (many forum posts).

Depending on which files you wish to concatenate with (and the order), write down the 'recipe', e.g. recipe.txt, containing

file file-new.mp4
file testing-6.mp4
file outro-new.mp4


Relative paths too can be prepended (e.g. file Videos/outro-new.mp4). The ffmpeg documentation explains the syntax better. There's a lot more about concat [1, 2].

Then run everything as follows:

ffmpeg -f concat -i recipe.txt output.webm

The reason the assembly of files is done with .mp4 files (to yield a WebM) is the insistence of Canva that downloaded videos are either MP4 or GIF. There must be some better ways and I'll improve this over time (this is all still very fresh in the mind; I've spent a lot of time on this).

From now on we have the ability to make videos that are 1) smaller in size because of re-encoding with strong compression and 2) have a little bit of extra context. We'll improve this over time and push to git.

Update: This is what the outcome can look like (mind start and end of clip).

Video download link

Recent Techrights' Posts

The End of Red Hat
expect many more layoffs soon
Only Hours Into the New Year People Already Discuss the Next Round of Layoffs at Red Hat/IBM
2026 will be another tough year for Red Hat and IBM
Recruiters Don't Use Microsoft LinkedIn, Spammers Use LinkedIn
One of my best friends, a university professor, lost all of his life's savings due to Microsoft LinkedIn
You've Only Wasted Your Life in Social Control Networks
In a sense, social control media is a giant delusion
2025 Was a Very Bad Year for Social Control Media
statCounter sees a gradual demise in Social Control Media access
Don't "Go Paperless", Go Paperful [sic] (for What Really Matters)
Why should we favour paper use sometimes? Well, many reasons.
 
Links 01/01/2026: "Biophobia" and Renewed Effort to Locate MH370
Links for the day
Gemini Links 01/01/2026: Bot Accounts Online and Reading in 2025
Links for the day
IBM’s and Red Hat’s "Operation Evolution initiative" Just Long, Fancy Term for Bluewashing, Redundancies, Layoffs
Gerstner is still alive, but he's shorter and more arrogant
Designing a Better Mousetrap or Tools for the SSG
Static Site Generators (SSGs) - unlike all modern Content Management Systems (CMSs) - are so simple that extending them is easy
Links 01/01/2026: 1930 Works in the Public Domain, Electricity Pricing 'a Mystery'
Links for the day
Firefox is Toast Because It Got Toasted by Mozilla
Firefox cannot keep above 2% and hasn't been able to for quite some time
Ignore the LLM Slop and the Noise, Microsoft is in a Death Spiral
So what does Microsoft have left to sell?
Red Hat is Vanishing Before Our Eyes
With some Red Hat staff "transitioning" we wonder if it's an HR hack, wherein they "reset the clock" on employment duration so as to lessen severance obligations
In 2025 Microsoft Lost Palau
Palau now has GNU/Linux at steadily high levels
Microsoft Mocked UNIX/Linux for Not Handling Dates After 2038, Microsoft Breaks Down on 2026!
Only a truly moronic company would design it that way
Another New Year's Resolution: Public Domain Sources, Credits
In addition to our first one
Combatting Slop Images (and ClownFlare)
we won't use or reuse slop images
A New Year's Resolution: Maximal Transparency
We'll do our very best to be transparent about everything that's going on, even legal matters
Gemini Links 01/01/2026: 2025 Comes to a Close and Capsular Gemlog Manager
Links for the day
Free Software Foundation (FSF) Raised About 1.3 Million Dollars in the Past Couple of Months!
the FSF's Board now has 10 people in it
2026 IBM Phaseout of Red Hat
Red Hat won't fare any better than most IBM acquisitions
Microsoft Budget Issues, XBox Thrown Under the Bus
They're cutting budget. Soon they'll cut the staff.
EPO People Power - Part XXI - Europe's Second-Largest Institution Became a Corrupt For-Profit Company Run by Drug Addicts
it'll be the demise of the Rule of Law in Europe and maybe a death blow to the EU (eventually), not just the EPO
Another Very Productive Year Commences
"a total of over 17,000 pages in a year"
Over at Tux Machines...
GNU/Linux news for the past day
IRC Proceedings: Wednesday, December 31, 2025
IRC logs for Wednesday, December 31, 2025
Fiji: GNU/Linux Has Risen From Almost Nothing to Almost 5% in Recent Years
It's not as small as people are led to believe
Gemini Links 31/12/2025: Blogosphere is Growing and New Year Begins
Links for the day
Complexity Considered Harmful: We Used to Run an Operating System on 64KB of RAM, Not 64GB of RAM (a Million Times More)
"Initially confined to single-tasking on 8-bit processors and no more than 64 kilobytes of memory"
The Slop Industry is Failing So Badly (Mountains of Debt, Losses) That It's Merging With the SPAM Industry
we reckon that Google will eventually delist all slopfarms, recognising they're just a form of SPAM
Links 31/12/2025: Cheeto Pushing for More Wars, ‘Security is a Shared Responsibility’
Links for the day
Enshittification of Postal Services Isn't Technological Advancement
Societies that say the aim is to "go digital" and eliminate paper trail aren't advanced; they're moving backwards
IBM Starts 2026 a Much Smaller Company (Not Homage to Gerstner)
People who get bluewashed out of their job (or bluewashed into unemployment) are gagged by NDAs
XBox is Likely Dead Already, But the Threat It Posed to Us All for Two Decades Isn't Over
"the Xbox was never about gaming and merely served as a test bed for DRM in commodity systems."
Ahead of 2026 Mass Layoffs at Microsoft the Tree Gets Shaken to See Who 'Falls' (Resigns/Retires)
"We had a quiet meeting last week about budget realignment. No one said layoffs, but it’s clear where the focus is shifting."
Almost 6,5000 Pages in 2025, Aiming Higher in 2026
if we can keep focused, then quantity will increase
Microsoft XBox Having a "Dog Ate My Homework" Moment: No New Console Until 3 Years From Now... Because "RAM Prices"
Who will ever remember this in 2028? Nobody.
Gemini End of Year Capsules Tally (Based on Lupa) Shows About 10% Growth
What a difference a year makes
Gemini Links 31/12/2025: New Resolution, Reverse Hexdump, and Programming Languages
Links for the day
Dr. Andy Farnell Explains Why Chatbots Became Dishonesty on Top of Dishonesty (Hiding Usage of Dishonest Salads of Words)
new article from CyberShow
Links 31/12/2025: Nvidia Faces Bubble-Bursting Moment, Saudi Oil Money Pumped Into Chatbots to Keep the Energy Waste Going (Circular Financing Again)
Links for the day
Richard Stallman's First Talk in a U.S. College Since 2018
Greetings from Georgia Tech!
EPO People Power - Part XX - Why António Campinos Chose to Put His Cokehead Friend on 'Sick Leave'
EPO Cocainegate will be covered for months to come
Over at Tux Machines...
GNU/Linux news for the past day
IRC Proceedings: Tuesday, December 30, 2025
IRC logs for Tuesday, December 30, 2025
Gemini Links 30/12/2025: FreeBSD, Gemlogs, and Xobaque
Links for the day
Get Ready for Gigantic XBox Layoffs at Microsoft (Much Bigger Than in 2025)
he unionisation drive is a sign workers already expect this
Concern Trolls: Stop Criticising Poor Gerstner Because Now He's Dead. Reality Check: Gerstner Has Found a Trick for Dodging Tax on His Hundreds of Millions in Wealth.
Maybe even billions in wealth
Samoa: GNU/Linux and ChromeOS Rose to Around 11%
based on Web access data from Samoa
DnD: Debian and Drugs
There will soon be some interesting new information about Debian
A Conundrum of Privacy/Surveillance: Will You Give Them a Stool Sample to "Feel Humane"?
What if skinnerboxes in South Korea also required that people provide urine and stool samples?
Nope, There's No Twitter "Successor"
There's a lot of horrible abuse going on in social control media
A Calm Year in IRC is a Good Year for IRC
Next year IRC will turn 38 (in August) and in 2028 it'll turn 40, just like the FSF did a couple of months ago
Slopfarms Covering Up for "Microsoft CEO Satya Nadella" After a Terrible Performance and a Terrible Year at Microsoft
How to cause many to resign/retire, hence not be counted as "layoffs"
IBM Was Never Saved, It Has Been a Downhill Journey for Decades Already
Gerstner wasn't a tech person but a fiscal butcher
Some GNU Joiners in Geminispace
Jose E. Marchesi (known for GNU poke and a bunch of other things) adopted Gemini Protocol
Jean-Slop Van Damme and the Art of Bull--- Code
it's saving neither time nor money
IBM Seems to be Doing to HashiCorp What It Did to Red Hat (Many Key People Leaving)
"Today marks my last day at HashiCorp, wrapping up an incredibly rewarding 5-year journey"
State of the Slop, Day 364
How does Phoronix feel about Google promoting slopfarms that 'rewrite' its stories and slap slop images on top?
Links 30/12/2025: "Durian Tsunami" and "Unneeded Surgeries"
Links for the day
Links 30/12/2025: Social Control Media Detox, Rage Against Slop Wasting People's Productive Capacities
Links for the day
Reality Check About IBM's Louis Grestner, Slopfarms Say He Was IBM CEO for 30 Years!
It is "hallucinating" (lying)
Debt as the New Currency?
Rich people get richer because they take money from the rest of us, if not directly then by compelling us (collectively) to borrow money at a national level, then "invest" in them
EPO People Power - Part XIX - "Berenguer Has Known of Campinos' Substance Abuse First Hand For a Long Time"
"You rightfully claimed that Berenguer is Campinos' protegee"
Gemini Links 30/12/2025: Quitting Coffee, Apartment by the Beach, and Strange Retail Ethics
Links for the day
Nintendo and Sony Outsold Microsoft XBox by 15:1!
The mass layoffs indicate Microsoft is aware of this
Over at Tux Machines...
GNU/Linux news for the past day
IRC Proceedings: Monday, December 29, 2025
IRC logs for Monday, December 29, 2025