ks-tools/doc/ks-mix.md

110 lines
3.3 KiB
Markdown
Raw Normal View History

2021-03-08 00:21:24 +01:00
ks-mix - Extract video/audio and mix video/audio files.
=======================================================
2021-03-22 18:43:19 +01:00
### Syntax:
2021-03-08 00:21:24 +01:00
2021-04-18 00:21:59 +02:00
```shell
$ ks-mix -evid <video-file> --> Extract video track
$ ks-mix -ev25 <video-file> --> Extract video track to 25 fps (H264/5 & MPEG4)
$ ks-mix -evpf <video-file> --> Extract video track & set fps (H264/5 & MPEG4)
$ ks-mix -eaud <video-file> --> Extract audio track
$ ks-mix -esub <video-file> --> Extract subtitle track (only for subrip/srt)
$ ks-mix -evti <video-file> --> Extract video from a specific hour/minute/second
2021-08-03 15:30:48 +02:00
$ ks-mix -eati <video-file> --> Extract audio from a specific hour/minute/second
2021-04-18 00:21:59 +02:00
$ ks-mix -evat <video-file> --> Extract video + audio from specific time
$ ks-mix -chec <video-file> --> Analyze tracks of video file
$ ks-mix -mixf --> Mix video and audio file
$ ks-mix -mixs --> Mix video, audio and subtitle file
```
2021-03-08 00:21:24 +01:00
### Examples (Extract video/audio):
* Extract video from video file:
2021-04-18 00:21:59 +02:00
```shell
$ ks-mix -evid /data/movies/Example.mkv
````
2021-03-08 00:21:24 +01:00
* Extract audio from video file:
2021-04-18 00:21:59 +02:00
```shell
$ ks-mix -eaud /data/movies/Example.avi
````
2021-03-08 00:21:24 +01:00
* Extract subtitles from video file:
2021-04-18 00:21:59 +02:00
```shell
$ ks-mix -esub /data/movies/Example.mkv
````
2021-03-08 00:21:24 +01:00
* Extract video from video file and change FPS to 25:
2021-04-18 00:21:59 +02:00
```shell
$ ks-mix -ev25 /data/movies/Example.mkv
````
2021-03-08 00:21:24 +01:00
* Extract video from video file and change to custom FPS:
2021-04-18 00:21:59 +02:00
```shell
$ ks-mix -evpf /data/movies/Example.mkv
````
2021-03-08 00:21:24 +01:00
2021-03-08 00:23:43 +01:00
_Note: Extracted video will be named `video.mkv` and extracted audio will be named `audio.mka`_
2021-03-24 21:26:16 +01:00
### Examples (Extract video/audio by cutting time):
* Extract video from a specific hour/minute/second:
2021-04-18 00:21:59 +02:00
```shell
$ ks-mix -evti /data/movies/Example.mkv
````
2021-03-24 21:26:16 +01:00
* Extract audio from a specific hour/minute/second:
2021-04-18 00:21:59 +02:00
```shell
$ ks-mix -eati /data/movies/Example.avi
````
2021-03-24 21:26:16 +01:00
* Extract video + audio from a hour/minute/second:
2021-04-18 00:21:59 +02:00
```shell
$ ks-mix -evat /data/movies/Example.mkv
````
2021-03-24 21:26:16 +01:00
_Note: After executing the command, an assistant will ask us from what hour, minute and second we want to cut the video. We can cut it to the end or the specified time._
2021-03-08 00:21:24 +01:00
### Examples (Mix video/audio):
* If you have extracted video and audio from different files, when you run the `ks-mix` command you will see the following:
2021-04-18 00:21:59 +02:00
```shell
+ Video file: /current/dir/video.mkv (FOUND)
+ Audio file: /current/dir/audio.mka (FOUND)
+ Subs file: /current/dir/subs.srt (NOT FOUND)
````
2021-03-08 00:21:24 +01:00
* Next, run the following command to merge the video and audio:
2021-04-18 00:21:59 +02:00
```shell
$ ks-mix -mixf
````
2021-03-08 00:21:24 +01:00
* Finally, you will see a wizard that will allow you to crop seconds of video or audio to synchronize them:
2021-04-18 00:21:59 +02:00
```shell
* [Default: 0] Set the seconds to cut in the video (0-59): 3
* [Default: 0] Set the seconds to cut in the audio (0-59): 1
* [Default: n] Finish the mix when one of the two (video or audio) finishes first? (y/n): y
* Starting mix of:`
- Video: /home/q3aql/.torrent/Conv/video.mkv
- Audio: /home/q3aql/.torrent/Conv/audio.mka
2021-03-08 00:21:24 +01:00
2021-04-18 00:21:59 +02:00
Output file: /home/q3aql/.torrent/Conv/output.mkv
````
2021-03-08 00:21:24 +01:00
### Back to README.md
2024-05-01 11:26:47 +02:00
* [Go back](https://git.q3aql.dev/q3aql/ks-tools/src/branch/main/README.md)
2021-03-22 18:43:19 +01:00