Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
freem
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Openai/6957d2e8-b738-8008-987a-09a5d9f29bc8
(section)
Add languages
Page
Discussion
English
Read
Edit
Edit source
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
Edit source
View history
General
What links here
Related changes
Special pages
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Assistant: Yep β the approach I gave still works fine with milliseconds. === Yep β the approach I gave still works fine with milliseconds. You just put decimals on the cut points. ===== You can do it either as seconds with decimals: ===== * start=62.137:end=133.904 or as HH:MM:SS.mmm (ffmpeg accepts this format too, but inside trim itβs simplest to use seconds). ===== Say you decide clip 2 should be 03:17.237 β 05:26.041. ===== 03:17.237 = 197.237 seconds 05:26.041 = 326.041 seconds <syntaxhighlight lang="bash">ffmpeg -i "NEA MADALIN E DRAG QUEEN ACUM [P9gZEDOz9eE].mkv" -filter_complex \ "[0:v]trim=start=197.237:end=326.041,setpts=PTS-STARTPTS[v]; \ [0:a]atrim=start=197.237:end=326.041,asetpts=PTS-STARTPTS[a]" \ -map "[v]" -map "[a]" \ -c:v libx264 -preset veryslow -qp 0 -pix_fmt yuv420p -profile:v high -level 4.0 \ -color_range tv -colorspace bt709 -color_trc bt709 -color_primaries bt709 \ -c:a libopus -b:a 160k -ar 48000 -ac 2 \ clip_02_0317p237-0526p041.mkv </syntaxhighlight> ===== Your video is 30 fps, so frames are spaced about 33.333 ms apart. ===== That means: * You can type millisecond timestamps, * but the actual video cut can only land on a frame boundary (β33ms steps). * Audio can be trimmed much more finely (sample-level). If you want, paste the exact ms cut points you end up with (like 01:02.153β02:13.087) and Iβll rewrite all 4 commands with those exact values.
Summary:
Please note that all contributions to freem are considered to be released under the Creative Commons Attribution-ShareAlike 4.0 (see
Freem:Copyrights
for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)