m-chrzan.xyz
aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcin Chrzanowski <marcin.j.chrzanowski@gmail.com>2018-05-26 11:06:09 +0200
committerMarcin Chrzanowski <marcin.j.chrzanowski@gmail.com>2018-05-26 11:06:09 +0200
commit472219bbb7aea178cbe29a9eabbccc7acfc4bfe7 (patch)
treec8c0fe628604766402ff246a8edddfe635e1ec6f
parent488d9ccc4c1141bb9bcbc81466166c5e45141b4b (diff)
Add new tricks
-rw-r--r--video.md6
-rw-r--r--vim.md5
2 files changed, 11 insertions, 0 deletions
diff --git a/video.md b/video.md
index dddccb0..d885d12 100644
--- a/video.md
+++ b/video.md
@@ -4,3 +4,9 @@
ffmpeg -i in.mp4 -codec:v copy -codec:a copy -ss START_TIME -t DURATION out.mp4
ffmpeg -ss START_TIME -t DURATION -i in.mp4 -codec:v copy -codec:a copy out.mp4
+
+## Resize
+
+ ffmpeg -i in.mp4 -s 720x480 out.mp4
+ # -1 means to automatically preserve aspect ratio
+ ffmpeg -i in.mp4 -filter:v scale=720:-1 out.mp4
diff --git a/vim.md b/vim.md
index c11e771..c69b9c4 100644
--- a/vim.md
+++ b/vim.md
@@ -12,3 +12,8 @@
| `/` | `:h /\r` | search pattern (in this case, `:h \r` also works |
| `'` | `:h 'ro'` | option |
| `-` | `:h -r` | Vim argument (starting Vim) |
+
+## Using vim as a hex editor?
+
+ :%!xxd
+ :%!xxd -r