Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 21

Thread: can anyone reccomend a lightweight program to cut videos?

  1. #11
    Join Date
    Nov 2009
    Beans
    Hidden!
    Distro
    Kubuntu 20.04 Focal Fossa

    Re: can anyone reccomend a lightweight program to cut videos?

    well that's more interesting. are these two appended at the end or after each file (output& input)?
    Like this?

    Code:
    ffmpeg -i input.mkv -ss hh:mm:ss -t hh:mm:ss output.mkv -acodec copy -vcodec copy
    or like this?:

    Code:
    ffmpeg -i -acodec input.mkv -ss hh:mm:ss -t hh:mm:ss -vcodec output.mkv
    Read the easy to understand, lots of pics Ubuntu manual.
    Do i need antivirus/firewall in linux?
    Full disk backup (newer kernel -> suitable for newer PC): Clonezilla
    User friendly full disk backup: Rescuezilla

  2. #12
    Join Date
    Jul 2005
    Location
    I think I'm here! Maybe?
    Beans
    Hidden!
    Distro
    Xubuntu 22.04 Jammy Jellyfish

    Re: can anyone reccomend a lightweight program to cut videos?

    Quote Originally Posted by mastablasta View Post
    well that's more interesting. are these two appended at the end or after each file (output& input)?
    Like this?

    Code:
    ffmpeg -i input.mkv -ss hh:mm:ss -t hh:mm:ss output.mkv -acodec copy -vcodec copy
    or like this?:

    Code:
    ffmpeg -i -acodec input.mkv -ss hh:mm:ss -t hh:mm:ss -vcodec output.mkv
    I am not sure about that but often it does not make much difference where options are in the command. However, when I've used ffmpeg for this and other things, I always put the -acodec copy -vcodec copy options just before the output.mkv file name, not after.

    Try both using a different output file name but the same input and you'll quickly see; with the copy options it takes only a very few minutes or even seconds depending how long the clip is, but if iot encodes it will take a great deal longer and use many more CPU resources.
    Last edited by ajgreeny; September 10th, 2020 at 11:19 AM.

  3. #13
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: can anyone reccomend a lightweight program to cut videos?

    If ffmpeg uses getopts(), which it should, then only the last argument, the output filename, is positional.

    BTW, ffmpeg in copy mode is functionally equivalent to the mkvmerge command I posted. Both perform at the speed of a file copy, though having multiple start-end times is easier with the mkvmerge. 1 other thing, mkvmerge requires that the output container be an MKV container, but that really isn't any hardship, since MKV can hold anything. There is a GUI for mkvmerge, but it is just a GUI to enter the exact same data that the shell command would use. It is not some graphical mouse point/click begin-end cutting software.

    On Linux, the closest solution to the non-transcoding ffmpeg and mkvmerge commands shown above is a tool called vidcutter. The interface is a little clunky and the snap/appimage packages depend on Qt, so about 900MB get downloaded for the 32MB program. Vidcutter doesn't transcode - or it didn't last time I actually got it working.

    To me avoiding any transcoding is important, since there are almost always artifacts and increased file sized as a result for already optimized videos. For non-optimized videos like mpeg2 and real-time recorded h.264 videos, which can be huge, then transcoding can drastically reduce file size - perhaps 75% smaller. With very conservative RF settings for h.264 transcoding, the resulting files will be much smaller and artifacts barely seen. If transcoding has already been done after the source, each attempt introduces more and more artifacts.

    Openshot, Kdenlive, Shotcut will all transcode. This is why your CPU and all cores get nailed when saving/exporting files using those tools. If they have a mode that doesn't transcode, I'd love to know about it.


    I have a video recording device that saves as h.264/aac inside an mp4 file container. This device has just 1 setting for recordings and prioritizes saving the data over being efficient. Basically, it is ffmpeg on a "superfast" encoding setting, so the file sizes are huge.

    Real world example: Yesterday, recorded a 110 minute video. That mp4 file is 5.9G in size. This morning, I transcoded that file using handbrake with an RF of 19.5 to 1.3G size. Thanks to a fast CPU with lots of cores, that transcoding took about 20 minutes at +19 nice setting. I use spinning disk storage for this, not SSDs. Saving 78% of the file size is worth the effort to me. All our playback devices well support the more efficient h.264 video encoding. While I'm transcoding, I keep the AAC audio, but also add vorbis multi-channel audio too for compatibility with some devices. Anyways, figured a better explanation for when to transcode and why it can be good wouldn't hurt. I actually edit the already transcoded file, because dealing with a 2G file is easier than dealing with a 6G file. The transcoding step can be batched, which allows deletion of the huge original file sooner, that frees up storage and temporary space for other uses.
    Last edited by TheFu; September 10th, 2020 at 03:51 PM.

  4. #14
    Join Date
    Nov 2008
    Location
    Boston MetroWest
    Beans
    16,326

    Re: can anyone reccomend a lightweight program to cut videos?

    The output filename must be the last item in an ffmpeg command.

    https://linux.die.net/man/1/ffmpeg
    If you ask for help, do not abandon your request. Please have the courtesy to check for responses and thank the people who helped you.

    Blog · Linode System Administration Guides · Android Apps for Ubuntu Users

  5. #15
    Join Date
    Feb 2014
    Location
    Yes
    Beans
    298
    Distro
    Ubuntu 18.04 Bionic Beaver

    Re: can anyone reccomend a lightweight program to cut videos?

    Avidemux might work for you, be careful to do cuts at keyframes which the double arrow buttons go to. It's in the Ub 18.04 repository.

  6. #16
    Join Date
    Mar 2020
    Beans
    69

    Re: can anyone reccomend a lightweight program to cut videos?

    it can't get any lighter than this :

    https://online-video-cutter.com/

  7. #17
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: can anyone reccomend a lightweight program to cut videos?

    Quote Originally Posted by ipv View Post
    it can't get any lighter than this :

    https://online-video-cutter.com/
    Except the required browsers to use it are all hogs. Doubt it supports dillo or lynx.

  8. #18
    Join Date
    Nov 2009
    Beans
    Hidden!
    Distro
    Kubuntu 20.04 Focal Fossa

    Re: can anyone reccomend a lightweight program to cut videos?

    the shotcut is using ffmpeg (as well as a few others) and after you do what you want and before you run the task it will say what commands will run and how ffmpeg was set. i am not sure if it has option to do it without transcoding.
    Read the easy to understand, lots of pics Ubuntu manual.
    Do i need antivirus/firewall in linux?
    Full disk backup (newer kernel -> suitable for newer PC): Clonezilla
    User friendly full disk backup: Rescuezilla

  9. #19
    Join Date
    Mar 2020
    Beans
    69

    Lightbulb Re: can anyone reccomend a lightweight program to cut videos?

    Quote Originally Posted by TheFu View Post
    Except the required browsers to use it are all hogs.
    point taken.

    Quote Originally Posted by TheFu View Post
    Doubt it supports dillo or lynx.
    i use neither so i know not, works with falkon & firefox.

    am assuming you use them so why not give it a shot & give feedback.

  10. #20
    Join Date
    Apr 2011
    Beans
    18
    Distro
    Xubuntu

    Re: can anyone reccomend a lightweight program to cut videos?

    I've written a prog that you could download here: https://github.com/kanehekili/VideoCut. The lightweight comes from using the ffmpeg libraries to create a real fast remuxer. It does no any fancy stuff, just cutting video precisely. The idea behind it: Do not try to re-encode, just take the I frames and copy them. Makes my 15 year old Thinkpad seem to be fast....

Page 2 of 3 FirstFirst 123 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •