Commit 3ada9c05 authored by Loren Merritt's avatar Loren Merritt

VfW: Enable weighted B prediction when max B-frames > 1. Enforce max reference frames <= 15.

patch by Riccardo Stievano.


git-svn-id: svn://svn.videolan.org/x264/trunk@135 df754926-b1dd-0310-bc7b-ec298dee348c
parent 834eac28
......@@ -222,6 +222,8 @@ LRESULT compress_begin(CODEC * codec, BITMAPINFO * lpbiInput, BITMAPINFO * lpbiO
param.rc.f_qcompress = (float)config->i_curve_comp / 100;
param.i_bframe = config->i_bframe;
if( config->i_bframe > 1 )
param.analyse.b_weighted_bipred = 1;
param.analyse.i_subpel_refine = config->i_subpel_refine + 1; /* 0..4 -> 1..5 */
/* bframe prediction - gui goes alphabetically, so 1=SPATIAL, 2=TEMPORAL */
......
......@@ -606,6 +606,11 @@ BOOL CALLBACK callback_advanced( HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lPa
break;
case IDC_REFFRAMES :
config->i_refmax = GetDlgItemInt( hDlg, IDC_REFFRAMES, FALSE, FALSE );
if( config->i_refmax > 15 )
{
config->i_refmax = 15;
SetDlgItemInt( hDlg, IDC_REFFRAMES, config->i_refmax, FALSE );
}
break;
case IDC_FOURCC :
GetDlgItemText( hDlg, IDC_FOURCC, config->fcc, 5 );
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment