dimakl
2nd July 2009, 19:57
Hi.
I work with x264, and run few testings to build "Rate-Distortion" curves for different video sources.
I work with constrained QP, i.e. rate-control is off.
My video clip is saved in raw format": YUV 4:2:0, size 720x480, 30fps
The source video sampled by interlaced camera, and the sampled lines are stored by sequence 1,2,3,4,5,6 ... where lines 1,3,5,... belong to field0, and lines 2,4,6,... belong to field1.
When I display whole frame, I can indicate "steps" on diagonal moving lines.
I want to activate x264 on this source.
1) Should I separate every frame to 2 consecutive fields? So I will get lines 1,3,5,... (field0) appear together, and lines 2,4,6,... (field1) will appear right after them?
2) Should I turn ON the interlacing option of x264?
I made testing encoding with the same parameters (fixed QP) the only different was:
1) Source = YUV video (I didn't touch the lines order), interlacing flag is default (progressive)
2) Source = like (1), interlacing flag is ON (--interlace)
3) Source is separated to 2 fields, interlacing flag is default (progressive)
4) Source = like (3), interlacing flag is ON (--interlace)
I got the results:
1) PSNR Mean = 39.018 Bitrate=2351.31 kbps
2) PSNR Mean = 38.773 Bitrate=2351.43 kbps
3) PSNR Mean = 38.900 Bitrate=2358.44 kbps
4) PSNR Mean = 38.773 Bitrate=2761.39 kbps
The PSNR seems quite similar, and bitrate of the last running is higher.
But also I wanted to compare this results to x264 compression over CIF size that produced from the same source. As I understand, the even (or odd) lines was thrown out, and also horizontal dimension was reduced twice. I supposed, that I expect to get bitrate reduced in 4 times (more or less), with similar PSNR.
The result was Bitrate=331kbps, PSNR=40.035
That is the reason of this unexpected difference between bitrate on SD and CIF?
Bitrate @ SD = 2350kbps
Bitrate @ CIF = 330kbps
Thank you,
I hope I didn't complicate my long explanation too much.
Dima
I work with x264, and run few testings to build "Rate-Distortion" curves for different video sources.
I work with constrained QP, i.e. rate-control is off.
My video clip is saved in raw format": YUV 4:2:0, size 720x480, 30fps
The source video sampled by interlaced camera, and the sampled lines are stored by sequence 1,2,3,4,5,6 ... where lines 1,3,5,... belong to field0, and lines 2,4,6,... belong to field1.
When I display whole frame, I can indicate "steps" on diagonal moving lines.
I want to activate x264 on this source.
1) Should I separate every frame to 2 consecutive fields? So I will get lines 1,3,5,... (field0) appear together, and lines 2,4,6,... (field1) will appear right after them?
2) Should I turn ON the interlacing option of x264?
I made testing encoding with the same parameters (fixed QP) the only different was:
1) Source = YUV video (I didn't touch the lines order), interlacing flag is default (progressive)
2) Source = like (1), interlacing flag is ON (--interlace)
3) Source is separated to 2 fields, interlacing flag is default (progressive)
4) Source = like (3), interlacing flag is ON (--interlace)
I got the results:
1) PSNR Mean = 39.018 Bitrate=2351.31 kbps
2) PSNR Mean = 38.773 Bitrate=2351.43 kbps
3) PSNR Mean = 38.900 Bitrate=2358.44 kbps
4) PSNR Mean = 38.773 Bitrate=2761.39 kbps
The PSNR seems quite similar, and bitrate of the last running is higher.
But also I wanted to compare this results to x264 compression over CIF size that produced from the same source. As I understand, the even (or odd) lines was thrown out, and also horizontal dimension was reduced twice. I supposed, that I expect to get bitrate reduced in 4 times (more or less), with similar PSNR.
The result was Bitrate=331kbps, PSNR=40.035
That is the reason of this unexpected difference between bitrate on SD and CIF?
Bitrate @ SD = 2350kbps
Bitrate @ CIF = 330kbps
Thank you,
I hope I didn't complicate my long explanation too much.
Dima