-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Use stressGraphics
for SVG content tests
#20118
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
linev
wants to merge
10
commits into
root-project:master
Choose a base branch
from
linev:stress_svg
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
+252,015
−71
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Test Results 21 files 21 suites 3d 20h 16m 48s ⏱️ For more details on these failures, see this check. Results for commit 2cd6f17. ♻️ This comment has been updated with latest results. |
couet
approved these changes
Oct 16, 2025
d7e8fb6
to
d384a51
Compare
Create SVG files in compact or full form and then compare them with reference files
In SVG mode use only GMT time to have reproducible time on all platforms in all time zones. To exclude variation of %Z output of strftime on different platforms just always printout GMT directly
Avoid deviation on graphics due to fit
When caclucating number of extra ticks which need to be placed on left or right side of axis add `epsilon` to avoid possible rounding problems. Ensure that minor tick on very begin or very end of axis range is painted
On some platforms FindVisibleDraw returns different result for same data. Either line is not visible at all or extremly small segment from the line is visible. In last case do not call paint for gPad Has effect on 3D axis grid painter and lego painter for several stressGraphics tests - but only when checking PS/SVG/PDF content, size reduction is very small
There order of triangles drawing defined by calculated Z value. For many triangles such Z value is very close to each other and "flip" on different platforms because of float precision. To exclude such flipping, add minimal epsilon in Z comparasion. When both Z are close to each other render order of triangles is not important
To avoid rounding effects in TGraph exclusion points optimization, use small epsilon in values comparasion.
If relative position changes only by small value - ignore this change. Let exclude rounding effects for testing when compact SVG form created
First provide SVG mode in stressGraphics to let generate only SVG files. Such SVG created in compact form which is now provided with TSVG class. When check reference files, compare line by line and print difference Some canvases disabled because of huge size which should be optimized first Content of reference SVG files must be exactly the same on all platforms.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
stressGraphics
already has different graphics objects so one can test them in SVG generation.But not only size of produced SVG, but also exact content must match.
So add reference SVG files, created in compact mode, and check that they remains the same.
There are several "known" problem why SVG files differ on different platforms.
Like unnecessary rounding when paint text on the canvas.
Therefore this is draft, which will be permanently tested and modified until reasonable results will be produced.
Once it is working, it will be able replace tests in
roottest/graphics/
directory.Later web mode of SVG content testing will be activated.