Commit f559d245 authored by Damien Fouilleul's avatar Damien Fouilleul

- directx, direct3d: for non-overlay surfaces, remove the background brush...

- directx, direct3d: for non-overlay surfaces, remove the background brush after first frame is displayed to avoid flickering during repaints
parent da7bbf93
......@@ -624,6 +624,12 @@ static void Display( vout_thread_t *p_vout, picture_t *p_pic )
HRESULT hr = IDirect3DDevice9_Present(p_d3ddev, NULL, NULL, NULL, NULL);
if( FAILED(hr) )
msg_Dbg( p_vout, "%s:%d (hr=0x%0lX)", __FUNCTION__, __LINE__, hr);
/* if set, remove the black brush to avoid flickering in repaint operations */
if( 0UL != GetClassLong( p_vout->p_sys->hvideownd, GCL_HBRBACKGROUND) )
{
SetClassLong( p_vout->p_sys->hvideownd, GCL_HBRBACKGROUND, 0UL);
}
}
/*****************************************************************************
......
......@@ -857,6 +857,12 @@ static void Display( vout_thread_t *p_vout, picture_t *p_pic )
return;
}
DirectXUnlockSurface( p_vout, p_pic );
/* if set, remove the black brush to avoid flickering in repaint operations */
if( 0UL != GetClassLong( p_vout->p_sys->hvideownd, GCL_HBRBACKGROUND) )
{
SetClassLong(p_vout->p_sys->hvideownd, GCL_HBRBACKGROUND, (ULONG)0UL);
}
}
}
......
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