f0e/mpv-lossless-cut
f0e/mpv-lossless-cut has 88 GitHub stars and 6 forks. GitHot measured 0 stars in 24 hours. Last checked 2026-11-15 15:41 UTC. Last push 2026-09-30.
Measured star growth
- in 24h
- 0
- in 7 days
- Update delayed
- in 15 days
- Update delayed
- in 1 month
- Update delayed
Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.
About
Cut videos incredibly quickly directly inside of the video player mpv. Fork of familyfriendlymikey/mpv-cut
Creative & MediaREADME.md
Originalmpv-lossless-cut
about
The core functionality of this script is to very quickly cut videos losslessly in mpv as an alternative to LosslessCut.
I decided to modify mpv-cut since I was looking for slightly different functionality to what the original script provided. Mainly I wanted to be able to adjust the start and end points of cuts.
Also credits to suckless-cut for inspiration & keybinds.
requirements
Besides mpv, you need ffmpeg installed, either in your PATH or set via the ffmpeg_path option.
installation
Download the latest release and move the folders in the zip into your mpv folder.
| Platform | Path |
|---|---|
| Windows | %appdata%/mpv/ |
| Windows (Scoop) | %userprofile%/scoop/persist/mpv/portable_config/ |
| Linux/macOS | ~/.config/mpv/ |
After that, the next time you run mpv the script will be loaded.
options
script-opts/mpv-lossless-cut.conf:
lossless- Whether the cut clips should be lossless. If set to yes, cuts may not be exact, as they can only occur at keyframes. Setting it to no will re-encode clips, but cut times will be exact.output_dir- The output directory for cuts, can be relative or absolute. For streamed videos (e.g. playing from a URL), relative paths are relative to mpv's working directory.- Default value:
.(will place cuts in the same directory as the original video) @cwdplaces cuts in mpv's working directory
- Default value:
multi_cut_mode- The mode for handling multiple cuts for a single video. Options:separate: Create separate cut files (default)merge: Merge cut files into a single cut
ffmpeg_path- The path to the ffmpeg executable- Default value:
ffmpeg(will find ffmpeg in your PATH)
- Default value:
usage
keybinds
g and h to set the start and end points of a cut (will use your current position)
G and H will do the same, but will place the points at the very start or end of the video
r to render cuts
ctrl+g to toggle between
separateandmergemodectrl+h to clear cuts
If you want to change the start or end position of a cut you can press the keybind again. You can also create multiple cuts from a single video.
Rendered cuts are placed next to the source file by default, see output_dir in the options.
troubleshooting
If the script doesn't work, you can try these steps.
- Make sure all of the requirements are installed
- Make sure the script is installed in the correct directory. You should end up with something like:
~/.config/mpv/scripts/mpv-lossless-cut.lua. - Run mpv using the terminal (
mpv video.mp4) and check the output, are there any errors? - Make sure you don't have multiple versions of mpv installed. You might have installed the script to the wrong version.
development
mise is used for tool/task management, and checks are configured & run with hk.
mise install # install dev dependencies
mise run setup # [optional] set up a pre-commit hook to run checks
mise run check # run checks
mise run fix # autofix issues