Reset prediction engine after size has changed (i.e. after Resize is applied)
This commit is contained in:
@@ -388,6 +388,13 @@ void PredictionEngine::cull( const Framebuffer &fb )
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ( (last_height != fb.ds.get_height())
|
||||||
|
|| (last_width != fb.ds.get_width()) ) {
|
||||||
|
last_height = fb.ds.get_height();
|
||||||
|
last_width = fb.ds.get_width();
|
||||||
|
reset();
|
||||||
|
}
|
||||||
|
|
||||||
uint64_t now = timestamp();
|
uint64_t now = timestamp();
|
||||||
|
|
||||||
/* control srtt_trigger with hysteresis */
|
/* control srtt_trigger with hysteresis */
|
||||||
|
|||||||
@@ -191,6 +191,8 @@ namespace Overlay {
|
|||||||
|
|
||||||
unsigned int send_interval;
|
unsigned int send_interval;
|
||||||
|
|
||||||
|
int last_height, last_width;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
enum DisplayPreference {
|
enum DisplayPreference {
|
||||||
Always,
|
Always,
|
||||||
@@ -227,6 +229,7 @@ namespace Overlay {
|
|||||||
glitch_trigger( 0 ),
|
glitch_trigger( 0 ),
|
||||||
last_quick_confirmation( 0 ),
|
last_quick_confirmation( 0 ),
|
||||||
send_interval( 250 ),
|
send_interval( 250 ),
|
||||||
|
last_height( 0 ), last_width( 0 ),
|
||||||
display_preference( Adaptive )
|
display_preference( Adaptive )
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user