This is an unsolved problem.. I can can do things manually but not using an easier “A to B” feature.
VLC >
Problem: Given a video, note a start and finish point and export that clip.
I’d make a proper HOWTO with screenshots, but this does not work as-expected. I can get it roughly to work, but not smoothly enough for it to justify a proper tutorial.
- A to B loop cannot be made to stop looping. There is no “A to B’ feature.
-
Recording does not respect A to B.
- 2018-04-07 – 2.2.7 on Devuan-1.0.0-jessie-i386-DVD
2018-04-07 – 2.2.7 ∞
GUI ∞
You have to transcode..
-
Launch vlc.
- I highly recommend using nice with something like
\nice \vlc, otherwise your computer will grind to a halt while it’s working.
- I highly recommend using nice with something like
Media > Convert/Save-
File >
- Highlight your filename.
— I don’t know why it doesn’t select the file it’s actually playing. - [x] Show more options
- At the bottom append something like
—:start-time=5557.000 :end-time=6544.000
— Wherestart-timeandend-timeare measured in seconds. You can use the “Start Time” field slightly above to calculate things for you.
— For example, 1:32:37 to 1:49:04 is:start-time=5557.000 :end-time=6544.000 - Click
[Convert/Save]
- Highlight your filename.
- [x] Deinterlace
-
Profile [Video – H.265 + MP3 (MP4)]
- You may have to default back to H.264 if you get an error like the one below.
-
specify the destination file
A note on the resulting clip
– It’s time/length will NOT be accurate.
– VLC will clip to the nearest boundary, so you may end up with more stuff before and after your clip. Yes, this sucks. You can test by clipping maybe 20 seconds at the start, and seeing how much beforehand is clipped, and maybe 20 seconds at the end and seeing how much afterwards is included.
Spoiler
[aef02c80] avcodec encoder error: cannot find encoder MPEG-H Part2/HEVC (H.265) *** Your Libav/FFmpeg installation is crippled. *** *** Please check with your Libav/FFmpeg packager. *** *** This is NOT a VLC media player issue. *** [b3a44030] stream_out_transcode stream out error: cannot find video encoder (module:any fourcc:hevc). Take a look few lines earlier to see possible reason. [b3a44030] stream_out_transcode stream out error: cannot create video chain [ac4f06f8] core decoder error: cannot create packetizer output (h264) [aef20578] clock decoder error: Timestamp conversion failed (delay 400000, buffering 100000, bound 3000000) [aef20578] core decoder error: Could not convert timestamp 80771849958
[failed] – Commandline ∞
Fucked if I can figure this out..
Spoiler
#!/usr/bin/env sh input="$1" # Requires the format: hh:mm:ss start="$2" stop="$3" # TODO - make this nice output="$input"-output time_to_seconds() { # Just cheat and use `date` local epoch=$( \date --date @0 +%F --utc ) output=$( \date --date "$epoch $1" +%s --utc ) \echo "$output" } start=$( time_to_seconds "$start" ) stop=$( time_to_seconds "$stop" ) echo $start echo $stop #cvlc "$input" --start-time "$start" --stop-time "$stop" --sout-deinterlace-mode=yadif2x --sout-keep --sout-standard-path=$output #vlc in.avi --start-time 65 --stop-time 95 :sout=#file{dst=/home/myser/Desktop/out.avi} :no-sout-rtp-sap :no-sout-standard-sap :sout-keep # This works, though I don't understand why.. rm --force 00.mp4 #cvlc "$input" --start-time "$start" --stop-time "$stop" --sout=#file{dst=00.mp4} --no-sout-rtp-sap :no-sout-standard-sap --sout-keep --no-loop #cvlc "$input" --start-time "$start" --stop-time "$stop" --sout-deinterlace-mode=yadif2x --sout-keep --sout-standard-path=00.mp4 --play-and-exit --sout-rtp-sap --no-sout-standard-sap #cvlc "$input" --start-time "$start" --stop-time "$stop" --sout=file:00.mpg --play-and-exit --no-loop #vlc "$input" --start-time "$start" --stop-time "$stop" --sout=\#file{dst=00.mp4} --sout-keep --play-and-exit --no-loop #vlc in.avi --start-time 65 --stop-time 95 :sout=#file{dst=/home/myser/Desktop/out.avi} :no-sout-rtp-sap :no-sout-standard-sap :sout-keep # Don't use `cvlc` # It won't actually quit.. :<<'NOTES' # What I want: ./clip-video.sh filename.mp4 1:32:37 1:49:04 # clips, but too early and seems choppy. ./clip-video.sh filename.mp4 1:32:37 1:32:55 # bad sync ./clip-video.sh filename.mp4 1:32:39 1:32:45 # Ends early. ./clip-video.sh filename.mp4 1:32:37 1:32:55 This all seems to take a chunk, and needs to begin at a boundary. https://superuser.com/questions/250448 NOTES
2016-05-23 – 2.2.1 ∞
Using A to B ∞
- Open your video in VLC
-
Dock advanced controls
- View > Advanced Controls
-
Disable looping
- Bottom-right, it looks like two arrows going in opposite directions. Click it until it goes flat and grey.
-
Find your A-point
- Play it until you get there. Wiggle your video around a bit, or use cursor keys to find the right spot.
-
Mark your A-point
- Click the “A to B loop” icon in the bottom-left advanced controls. Only the A should highlight red.
-
Find your B-point
- Play it until you get there. Wiggle your video around a bit, or use cursor keys to find the right spot.
-
Mark your B-point
- Click the “A to B loop” icon in the bottom-left advanced controls. Now both the A and B should be highlighted red.
- The video should “snap back” to your A-point.
-
Begin recording
- It’s the circle to the left, in the advanced controls.
-
Play
What I expect to be able to do:
This does not work – The record button does not respect the “A to B” feature.
- No play bar is given
- The video does not progress.
- It does not stop playing when reaching the B-point
-
workaround – when you reach your moment, click the record button again.
Using record ∞
What I’m forced to do:
- Find my start point
- Press record
- Play until my end point
-
Press record
—
-
The video is automatically exported, in whatever random format, in your “Videos” directory.
- I was expecting an export dialog to choose a location, and for there to be (optional) export formats.
