8000 Update README.md · u2takey/ffmpeg-python@86d2a3b · GitHub
[go: up one dir, main page]

Skip to content

Commit 86d2a3b

Browse files
authored
Update README.md
1 parent c6ab775 commit 86d2a3b

File tree

1 file changed

+15
-11
lines changed

1 file changed

+15
-11
lines changed

README.md

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -40,15 +40,10 @@ Take for example a signal graph that looks like this:
4040

4141
The corresponding command-line arguments are pretty gnarly:
4242
```bash
43-
ffmpeg -i input.mp4 \
44-
-filter_complex "\
45-
[0]trim=start_frame=10:end_frame=20[v0];\
46-
[0]trim=start_frame=30:end_frame=40[v1];\
47-
[v0][v1]concat=n=2[v2];\
48-
[1]hflip[v3];\
49-
[v2][v3]overlay=eof_action=repeat[v4];\
50-
[v4]drawbox=50:50:120:120:red:t=5[v5]"\
51-
-map [v5] output.mp4
43+
ffmpeg -i input.mp4 -filter_complex "[0]trim=start_frame=10:end_frame=20[v0];\
44+
[0]trim=start_frame=30:end_frame=40[v1];[v0][v1]concat=n=2[v2];[1]hflip[v3];\
45+
[v2][v3]overlay=eof_action=repeat[v4];[v4]drawbox=50:50:120:120:red:t=5[v5]"\
46+
-map [v5] output.mp4
5247
```
5348

5449
Maybe this looks great to you, but if you're not an FFmpeg command-line expert, it probably looks alien.
@@ -140,13 +135,22 @@ Or fluently:
140135
)
141136
```
142137

143-
When in doubt, refer to the [existing filters](https://github.com/kkroening/ffmpeg-python/blob/master/ffmpeg/_filters.py) and/or the [official ffmpeg documentation](https://ffmpeg.org/ffmpeg-filters.html).
138+
Arguments with special names such as `-qscale:v` can be specified as a keyword-args dictionary as follows:
139+
```python
140+
(ffmpeg
141+
.input('dummy.mp4')
142+
.output('dummy2.mp4', **{'qscale:v': 3})
143+
.run()
144+
)
145+
```
146+
147+
When in doubt, refer to the [existing filters](https://github.com/kkroening/ffmpeg-python/blob/master/ffmpeg/_filters.py), [examples](https://github.com/kkroening/ffmpeg-python/tree/master/examples), and/or the [official ffmpeg documentation](https://ffmpeg.org/ffmpeg-filters.html).
144148

145149
## Contributing
146150

147151
<img align="right" src="https://raw.githubusercontent.com/kkroening/ffmpeg-python/master/doc/logo.png" alt="ffmpeg-python logo" width="20%" />
148152

149-
Feel free to report any bugs or feature requests.
153+
Feel free to report any bugs or submit feature requests.
150154

151155
It should be fairly easy to use filters that aren't explicitly built into `ffmpeg-python` but if there's a feature or filter you'd really like to see included in the library, don't hesitate to open a feature request.
152156

0 commit comments

Comments
 (0)
0