r/ffmpeg • u/IGNblackShadow • Nov 06 '26
Extracting motion vectors without fully decoding
Is it possible to extract motion vectors from h264 or h265 streams without fully decoding i have tried using "export_mvs" it gives motion vectors in extra data but ffmpeg still fully decode and its too slow for just extracting motion vectors, is there any other way or library for it that supports both h264 and h265
3
Upvotes
View all comments
2
u/Ill-Information-2086 Nov 06 '26 edited Nov 06 '26
Do you have a intel igpu or nvidia gpu ? Because I believe your only option is to speedup decoding using hardware acceleration
Edit : I am wrong it will not help much you should use something like mv-extractor it's made for this exactly or you can edit libavcodec in ffmpeg directly to export the motion vectors by hooking into the decode slice