Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

[Solved]Any simple mp4 Video cutter/Splitter available?

If none of the specific sub-forums seem right for your thread, ask here.
Post Reply
Message
Author
bkpsusmitaa
Posts: 485
Joined: 2009-07-04 06:32
Location: Home: Barrackpore and Mysore
Has thanked: 5 times

[Solved]Any simple mp4 Video cutter/Splitter available?

#1 Post by bkpsusmitaa »

Specific chunks of downloaded YouTube videos are to be used for note-making purposes.

OpenShot video editor is an Overkill. Like using an H-bomb to kill a mosquito. Then there are problems associated and the complexity involved with compression and bitrate setup for the sliced portions with OpenShot.

My simple purpose is to watch a video in smplayer. Note down the timeline for the chunks needed. Then use a video cutter to cut out those required slices. At the same compression bitrate as that of the parent file.

Linux split command helps in splitting binary files. But there is a problem. The Mime- and compression- data of the sliced files are only in the first slice. The rest don't have them. So renaming the intermediate slices won't make them playable mp4 videos.

vlc media player could have been used, but my laptop has non-standard components, making audio stream recording impossible. The matter has been discussed in one of my earlier posts.

So any suggestion would be welcome. In the year 2000 there was a simple window application called vcdcutter. I require something simple like it.
Last edited by bkpsusmitaa on 2022-09-09 15:16, edited 1 time in total.
Freedom is impossible to conceive.
Books that help:
Dale Carnegie's How To Win Friends And Influence People and Emilie Post's Etiquette In Society, In Business, In Politics, And At Home

bin
Posts: 56
Joined: 2019-03-07 12:02
Been thanked: 6 times

Re: [?]Any simple mp4 Video cutter/Splitter available?

#2 Post by bin »

I use Lossless Cut - you can watch and mark at the same time, then just chop off the rubbish. It does take a little practice but does the job. I'm using the Appimage.

bkpsusmitaa
Posts: 485
Joined: 2009-07-04 06:32
Location: Home: Barrackpore and Mysore
Has thanked: 5 times

Re: [?]Any simple mp4 Video cutter/Splitter available?

#3 Post by bkpsusmitaa »

bin wrote: 2022-09-09 05:55 I use Lossless Cut - you can watch and mark at the same time, then just chop off the rubbish. It does take a little practice but does the job. I'm using the Appimage.
Thank you. Good. Downloaded LosslessCut-linux-x86_64.AppImage. libappimage0 wasn't installed. Required another, libsquashfuse.
After installation of these packages, tried to run from terminal. Error message:
./LosslessCut-linux-x86_64.AppImage: error while loading shared libraries: libz.so.1: cannot open shared object file: No such file or directory
Checking if libz is zlib which is installed. Any suggestions?
Freedom is impossible to conceive.
Books that help:
Dale Carnegie's How To Win Friends And Influence People and Emilie Post's Etiquette In Society, In Business, In Politics, And At Home

User avatar
oswaldkelso
df -h | grep > 20TiB
df -h | grep > 20TiB
Posts: 1490
Joined: 2005-07-26 23:20
Location: UK
Has thanked: 1 time
Been thanked: 58 times

Re: [?]Any simple mp4 Video cutter/Splitter available?

#4 Post by oswaldkelso »

ffmpeg. Almost certainly already installed.

search for ¨ffmpeg trim video¨ with your favourite search engine or video site
Free Software Matters
Ash init durbatulûk, ash init gimbatul,
Ash init thrakatulûk agh burzum-ishi krimpatul.
My oldest used PC: 1999 imac 333Mhz 256MB PPC abandoned by Debian

User avatar
canci
Global Moderator
Global Moderator
Posts: 2502
Joined: 2006-09-24 11:28
Has thanked: 136 times
Been thanked: 136 times

Re: [?]Any simple mp4 Video cutter/Splitter available?

#5 Post by canci »

I use ffmpeg these days, like this:
https://superuser.com/questions/138331/ ... t-up-video
Image Stable / Asus VivoBook X421DA / AMD Ryzen 7 3700U / Radeon Vega Mobile Gfx (Picasso) / 8 GB RAM / 512GB NVMe

READ THIS:

* How to Post a Thread Here
* Other Tips and Great Resources

bkpsusmitaa
Posts: 485
Joined: 2009-07-04 06:32
Location: Home: Barrackpore and Mysore
Has thanked: 5 times

[Solved]Any simple mp4 Video cutter/Splitter available?

#6 Post by bkpsusmitaa »

canci wrote: 2022-09-09 13:06 I use ffmpeg these days, like this:
https://superuser.com/questions/138331/ ... t-up-video
Yes,Mr. cancl, thank you. I needed the line.
The following would skip the first 30 seconds, and then extract the next 10 seconds to a file called output.wmv:

Code: Select all

ffmpeg -ss 30 -i input.wmv -c copy -t 10 output.wmv
In the above command, the timestamps are in seconds (s.msec), but timestamps can also be in HH:MM:SS.xxx format. The following is equivalent:

Code: Select all

ffmpeg -ss 00:00:30.0 -i input.wmv -c copy -t 00:00:10.0 output.wmv
OR(corrected on the basis of the above link on 24Jun23)
Example: If you want to make a 1-minute clip, from 9min0sec to 10min 0sec in Video.mp4, you could do it both quickly and accurately using:

Code: Select all

ffmpeg -ss 00:08:00 -i Video.mp4 -ss 00:01:00 -t 00:01:00 -c copy VideoClip.mp4
The first -ss seeks fast to (approximately) 8min0sec, and then the second -ss seeks accurately to 9min0sec, and the 00:01:00 -t takes out a 1min0sec clip.
Thank you too, Mr. oswaldkelso. The search for "ffmpeg trim video" (without the quotation signs) led to the webpage: https://shotstack.io/learn/use-ffmpeg-to-trim-video/ and a near identical solution as above:

Code: Select all

$ ffmpeg -i input.mp4 -ss 00:05:20 -t 00:10:00 -c:v copy -c:a copy output1.mp4
Just one question to ask: does the encoding remain untouched for the cut/trimmed video?

I am also expecting a reply from Mr. bin.

Thank you all for your inputs. Much appreciated. I admire your upholding the Social Contract and of FSF.

BTW, please draw the attention of the forum administrators and moderators, because I can't see the "Thank" sign on your posts. So I can't officially post my Thanks for you.
Last edited by bkpsusmitaa on 2023-06-24 04:23, edited 3 times in total.
Freedom is impossible to conceive.
Books that help:
Dale Carnegie's How To Win Friends And Influence People and Emilie Post's Etiquette In Society, In Business, In Politics, And At Home

User avatar
canci
Global Moderator
Global Moderator
Posts: 2502
Joined: 2006-09-24 11:28
Has thanked: 136 times
Been thanked: 136 times

Re: [Solved]Any simple mp4 Video cutter/Splitter available?

#7 Post by canci »

If you give 'copy' instead of naming a codec, then ffmpeg will indeed only cut the length and not recode anything, so quality will remain unchanged. In the examples that you picked above you can see that both video and audio remain unchanged. If you change media containers, the video won't typically be reencoded, but be aware that not all containers can take every codec, so just leave the container as is if you don't care about it.
Image Stable / Asus VivoBook X421DA / AMD Ryzen 7 3700U / Radeon Vega Mobile Gfx (Picasso) / 8 GB RAM / 512GB NVMe

READ THIS:

* How to Post a Thread Here
* Other Tips and Great Resources

User avatar
stevepusser
Posts: 12930
Joined: 2009-10-06 05:53
Has thanked: 41 times
Been thanked: 71 times

Re: [Solved]Any simple mp4 Video cutter/Splitter available?

#8 Post by stevepusser »

For Pete's sake--just use VLC. Enable the Advanced Controls in VLC, and you get a "Record" button. Begin and stop recording to cut out your desired chunk of video. Yes, you need to play that whole section to record it.

There's another applet called Vidcutter https://www.omgubuntu.co.uk/2017/01/vid ... -linux-app which is dead simple, too, but is not in Debian. You could use the MX 21 build, which I did on generic Debian QEMU virtual machines using pbuilder. (that means they work fine in Debian)
MX Linux packager and developer

bkpsusmitaa
Posts: 485
Joined: 2009-07-04 06:32
Location: Home: Barrackpore and Mysore
Has thanked: 5 times

Re: [Solved]Any simple mp4 Video cutter/Splitter available?

#9 Post by bkpsusmitaa »

stevepusser wrote: 2022-09-09 19:52 For Pete's sake--just use VLC. ...
I have told you, Steve, earlier and here too, that my laptop has non-standard components, because of which pulseaudio doesn't work in duplex mode, playing and recording audio simultaneously. So vlc won't help.
But thank you for your intent to help, which is noted.
Last edited by bkpsusmitaa on 2022-09-10 01:12, edited 2 times in total.
Freedom is impossible to conceive.
Books that help:
Dale Carnegie's How To Win Friends And Influence People and Emilie Post's Etiquette In Society, In Business, In Politics, And At Home

bkpsusmitaa
Posts: 485
Joined: 2009-07-04 06:32
Location: Home: Barrackpore and Mysore
Has thanked: 5 times

Re: [Solved]Any simple mp4 Video cutter/Splitter available?

#10 Post by bkpsusmitaa »

canci wrote: 2022-09-09 17:31 If you give 'copy' instead of naming a codec, then ffmpeg will indeed only cut the length and not recode anything ... ... so just leave the container as is if you don't care about it.
Thank you, Mr. Canci, for your note.
Freedom is impossible to conceive.
Books that help:
Dale Carnegie's How To Win Friends And Influence People and Emilie Post's Etiquette In Society, In Business, In Politics, And At Home

User avatar
canci
Global Moderator
Global Moderator
Posts: 2502
Joined: 2006-09-24 11:28
Has thanked: 136 times
Been thanked: 136 times

Re: [Solved]Any simple mp4 Video cutter/Splitter available?

#11 Post by canci »

stevepusser wrote: 2022-09-09 19:52 just use VLC.
This never really worked for me and was way too much hassle to troubleshoot than ffmpeg.
And if I were to use GUI, then I'd just go all the way and use something where I can visually cut things on a timeline, so vidcutter or something similar. But ffmpeg works best for me and I don't need to go hunt down external packages.
Image Stable / Asus VivoBook X421DA / AMD Ryzen 7 3700U / Radeon Vega Mobile Gfx (Picasso) / 8 GB RAM / 512GB NVMe

READ THIS:

* How to Post a Thread Here
* Other Tips and Great Resources

yodamin
Posts: 23
Joined: 2022-10-03 20:42
Has thanked: 7 times
Been thanked: 2 times

Re: [Solved]Any simple mp4 Video cutter/Splitter available?

#12 Post by yodamin »

avidemux

cut/append/convert containers/re-encode

extremely easy to use

https://avidemux.sourceforge.net/
avidemux.png
avidemux.png (49.87 KiB) Viewed 2068 times

User avatar
canci
Global Moderator
Global Moderator
Posts: 2502
Joined: 2006-09-24 11:28
Has thanked: 136 times
Been thanked: 136 times

Re: [Solved]Any simple mp4 Video cutter/Splitter available?

#13 Post by canci »

I thought Avidemux was dead. I used that a lot in the past.
Image Stable / Asus VivoBook X421DA / AMD Ryzen 7 3700U / Radeon Vega Mobile Gfx (Picasso) / 8 GB RAM / 512GB NVMe

READ THIS:

* How to Post a Thread Here
* Other Tips and Great Resources

User avatar
stevepusser
Posts: 12930
Joined: 2009-10-06 05:53
Has thanked: 41 times
Been thanked: 71 times

Re: [Solved]Any simple mp4 Video cutter/Splitter available?

#14 Post by stevepusser »

Avidemux is still alive--just recently pushed out a 2.8.1 release, I think.

It'll never get into Debian until some of the MPEG group's problematic mp4 container patents patents expire.
MX Linux packager and developer

CwF
Global Moderator
Global Moderator
Posts: 2638
Joined: 2018-06-20 15:16
Location: Colorado
Has thanked: 41 times
Been thanked: 192 times

Re: [Solved]Any simple mp4 Video cutter/Splitter available?

#15 Post by CwF »

stevepusser wrote: 2022-10-05 00:07 mp4 container patents
...expire next year or so.
I've been using avidemux since stretch. Every version a little better! I think the last upgrade netted a volume control! ...at the same time gnutv broke.

bkpsusmitaa
Posts: 485
Joined: 2009-07-04 06:32
Location: Home: Barrackpore and Mysore
Has thanked: 5 times

Re: [Solved]Any simple mp4 Video cutter/Splitter available?

#16 Post by bkpsusmitaa »

One note: LosslessCut-linux-x86_64.AppImage appears to be corrupt. Downloaded from the GitHub link https://github.com/mifi/lossless-cut#download, chmod +x done and opened with ark, ark reports:
Loading the archive /home/knoppix/Downloads/LosslessCut-linux-x86_64.AppImage failed with the following error:
No suitable plugin found. Ark does not seem to support this file type.
On the other hand, avidemux_2.8.1_legacy.appImage is functional with ark. But doesn't run.
Freedom is impossible to conceive.
Books that help:
Dale Carnegie's How To Win Friends And Influence People and Emilie Post's Etiquette In Society, In Business, In Politics, And At Home

Post Reply