// Tests for game::glare (runtime/game/glare.h): the sun's glow, a square of // frame pixels the game builds around the sun, fitted to the view scales so // that on a screen of any shape (video::FitPicture's picture) it is still a // square, at the game's angle, in the same place, and as large against the // 16:9 band as at 16:9. From the repo root: // clang++ -std=c++20 -O2 -UNDEBUG -Iruntime tests/glare_fit_test.cpp runtime/video/picture_fit.cpp -o build/glare_fit_test // build/glare_fit_test // The shape checks run again with planted wrong fits (none, the inverse // scale, the axes swapped, about the frame's corner instead of the centre): // each must fail at least one case. #include #include