[Libav-user] Source parameter of motion vector specifies -1/1 (past or future) and not the exact reference frame number.

Sandra VS Nair sandravsnair at gmail.com
Mon Oct 11 09:37:23 EEST 2021


Hi,

I'm trying to extract the motion vector information from an H.264 video. I
got every information I needed except one. The "source" parameter of a
motion vector is either -1 or +1 depending on whether the reference frame
used is in the past or future. But I need the exact reference frame number
which is used as a reference for each of the macroblocks/motion vectors. Is
there any way to do that?

In libavutil/motion_vector.h, the source parameter is specified as given
below:


typedef struct AVMotionVector {
/**
* Where the current macroblock comes from; negative value when it comes
* from the past, positive value when it comes from the future.
* XXX: set exact relative ref frame reference instead of a +/- 1
"direction".
*/
int32_t source; }
Expecting a positive response.
-- 
Regards
Sandra VS Nair
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://ffmpeg.org/pipermail/libav-user/attachments/20211011/0bcbdeea/attachment.htm>


More information about the Libav-user mailing list