mirror of
https://github.com/emilk/egui.git
synced 2026-09-03 07:10:04 -04:00
Change Harness::run to run until no more repaints are requested (#5580)
Previously, `Harness::run` just called `Harness::step` 3 times. If that wasn't enough, tests would often call run multiple times so all animations would finish properly. Also, I introduced `HarnessBuilder::with_step_dt` to customize with how big of a dt each frame is called. I set the default to 1.0 / 6.0 (~6fps) so we don't waste cpu in tests waiting on animations. `HarnessBuilder::max_steps` allows us to control how many steps `Harness::run` should run before panicing. The default is 6, so we run for up to 1.0 logical seconds (six frames at 6 fps), which should be enough to finish most animations. Turns out a lot of snapshots where rendered before fully shown and had a light opacity, those are now fixed. * [x] I have followed the instructions in the PR template
This commit is contained in:
@@ -1,3 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:ed2a356452d792e32bea57f044da9d86da27fd8504826dd6b87618a53519ea6a
|
||||
size 522556
|
||||
oid sha256:3562bb87b155b2c406a72a651ffb1991305aa1e15273ce9f32cedc5766318537
|
||||
size 554922
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:0d04a5854528c6141f7def6f9229c51c6d2d4c87e2f656be4d149e7b2b852976
|
||||
size 729056
|
||||
oid sha256:ba6c0bd127ab02375f2ae5fbc3eeef33a1bdf074cbb180de2733c700b81df3e5
|
||||
size 771069
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:e6e5c1a745e357faa7b98f7a2cd1ca139c4a14be154b9d21feb8030933acfdb7
|
||||
size 867552
|
||||
oid sha256:d85ab6d04059009fd2c3ad8001332b27e710c46c9300f2f1f409b882c49211dc
|
||||
size 918967
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:7d9f4a37541fd1a0754c1cb1f3a2d4a76f03d67ca4e5596c8e6982d691d29dea
|
||||
size 980286
|
||||
oid sha256:a64f1bdec565357fe4dee3acb46b12eeb0492b522fb3bb9697d39dadce2e8c21
|
||||
size 1039455
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:4d1c99867202e16500146b7146a32fd83d70d60f5ac94aae4ca405a6377e4625
|
||||
size 1066559
|
||||
oid sha256:5ca008dca03372bb334564e55fa2d1d25a36751a43df6001a1c1cf3e4db9bcd4
|
||||
size 1130930
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:08fc1c89fd2d04aa12c75a1829dacfff090e322c65ad969648799833e1b072eb
|
||||
size 1235574
|
||||
oid sha256:7f695127e7fe6cb3b752a0acd71db85d51d2de68e45051a7afe91f4d960acf27
|
||||
size 1311641
|
||||
|
||||
Reference in New Issue
Block a user