<div dir="ltr">Hi x264 developers,<br><br>I want to dump the Motion Vector(MV) during x264 encodes the video. I don't care about the output video's quality. Instead, I care about the MV's quality and speed. Ideally, I want the program to only do the motion estimation. Using input frame n for the current frame, and input frame n-1 for the reference frame. Other stuff such as DCT, quantization, entropy encoding is not important to me. Like the top left part of this picture(*).<br><br>From the H.264 standard, I knew we use the reconstructed frame instead of the original frame as the reference frame. Instead of modifying x264's execution flow, I suppose set qp to 0 could be a workaround. Lossless compressed and decompressed the input frame, getting the reconstructed frame as the reference frame, to get better quality MV than lossy compression.<br><br>For the speed, I want to execute only the necessary part of the program. I studied all options of x264, referring to the "ultrafast" preset, and generated the following command. <br><br><span style="background-color:rgb(204,204,204)">./x264 --log-level debug --input-res 64x64 -b 0 --partitions none --ref 1 --keyint infinite --no-scenecut --qp 0 --me tesa --merange 16 --rc-lookahead 0 --lookahead-threads 1 --subme 0 --no-chroma-me --weightp 0 -o /dev/null /path/to/the/video/input.yuv</span><br><br>Does the option of my setting achieve my goal, getting good quality MVs as fast as possible? Without commenting out the unnecessary code, is there any improvement I can do? Thank you!<br><br>*: <a href="https://drive.google.com/file/d/1XyKxiJfu_Ixf300fc_xVE5QVsVCKGMl2/view?usp=sharing">https://drive.google.com/file/d/1XyKxiJfu_Ixf300fc_xVE5QVsVCKGMl2/view?usp=sharing</a><br><div><br></div><div>- dmvictor</div></div>