Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,26 @@ This fork of the [original project](https://github.com/lvml/mpv-plugin-excerpt)
- `pciutils` (needed for auto-selection of GPU encoder)
- `cuda` if you're using an NVIDIA GPU or
- `intel-vaapi-driver`, `intel-media-driver` or any other appropriate package depending on your model, if you're using an INTEL GPU. See [this page](https://wiki.archlinux.org/title/Hardware_video_acceleration) for more info.

## Installation

Move the `.lua` script into the default `scripts` folder, defaults to `~/.config/mpv/scripts`.

``` bash
mkdir -p ~/.config/mpv/scripts
cd ~/.config/mpv/scripts
git clone https://github.com/morrolinux/mpv-plugin-excerpt-v2 tmp
mv tmp/excerpt.lua excerpt.lua
rm -r tmp
```

## Customize Key Bindings

You can customize the key bindings by editing the `excerpt.lua` file or by adding key bindings to your `input.conf` file. The default ones are:

| Key | Action | Description |
|----:|-------|-------------|
| `i` | Set IN point | Mark the beginning of the excerpt |
| `o` | Set OUT point | Mark the end of the excerpt |
| `x` | Export excerpt | Extract the video segment using default profile |
| `shift+E` | Export accurate | Extract using accurate encoding profile |
1 change: 0 additions & 1 deletion excerpt.lua
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,6 @@ function os.capture(cmd, raw)
end

function excerpt_on_loaded()
mp.osd_message("excerpt: use i and o to set IN and OUT points.", 3)

local operating_system = string.lower(os.capture("uname"))
installed_gpus = string.lower(os.capture("lspci -k | grep -E 'VGA|3D|Display'"))
Expand Down