From 70499cbd627d84c3502b84f37b928b9735b19da0 Mon Sep 17 00:00:00 2001 From: proller Date: Fri, 25 Oct 2019 19:36:13 +0300 Subject: [PATCH] timelapse_stay --- src/client/tile.cpp | 2 ++ util/autotest/auto.pl | 10 ++++++++++ 2 files changed, 12 insertions(+) diff --git a/src/client/tile.cpp b/src/client/tile.cpp index b6cbdf072..f992f078b 100644 --- a/src/client/tile.cpp +++ b/src/client/tile.cpp @@ -2233,6 +2233,8 @@ video::SColor TextureSource::getTextureAverageColor(const std::string &name) video::IImage *image = driver->createImage(texture, core::position2d(0, 0), texture->getOriginalSize()); + if (!image) + return c; u32 total = 0; u32 tR = 0; u32 tG = 0; diff --git a/util/autotest/auto.pl b/util/autotest/auto.pl index 6aa83e63e..429b9f42a 100755 --- a/util/autotest/auto.pl +++ b/util/autotest/auto.pl @@ -290,6 +290,15 @@ our $options = { enable_damage => 0, continuous_forward => 1, }, + fps1 => { + fps_max => 2, + viewing_range => 1000, + #viewing_range_max => 1000, + wanted_fps => 1, + }, + stay => { + continuous_forward => 0, + }, fast => { fast_move => 1, movement_speed_fast => 30, }, @@ -694,6 +703,7 @@ qq{$config->{vtune_amplifier}amplxe-cl -report $report -report-width=250 -report timelapse_play => [{-options_int => 'timelapse',}, \'play', 'timelapse_video'], #' fly => [{-options_int => 'fly_forward', -options_bot => '',}, \'bot',], #' timelapse_fly => [{-options_int => 'timelapse,fly_forward', -options_bot => '',}, \'bot', 'timelapse_video'], #' + timelapse_stay => [{-options_int => 'timelapse,fly_forward,stay,far,fps1', -options_bot => '',}, \'bot', 'timelapse_video'], #' bench1 => [{-options_int => 'bench1,fly_forward,fast',}, \'bot'], #' up => sub { my $cwd = Cwd::cwd();