canvas: Clear vello scene if possible (#38356)

Vello scene only ever grows, so we need to clear it as soon as it's
possible (in clear rect). This PR also adds ignore_clips to
vello_backend (already exists in vello_cpu_backend).

Testing: Behavior is verified by existing tests, as this is mainly a
change for performance. There are currently no performance tests. This
makes bunnymark actually playable (from 3 FPS to 20 FPS on vello_cpu).

---------

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
This commit is contained in:
sagudev 2025-08-01 07:05:15 +02:00 committed by GitHub
parent b05d265de5
commit 09f0e20e29
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 102 additions and 34 deletions

View file

@ -0,0 +1,4 @@
[2d.path.clip.winding.evenodd.1.html]
[evenodd winding number rule works in clip]
expected:
if subsuite == "vello_canvas": FAIL

View file

@ -0,0 +1,4 @@
[2d.path.clip.winding.evenodd.2.html]
[evenodd winding number rule works in clip]
expected:
if subsuite == "vello_canvas": FAIL

View file

@ -1,5 +0,0 @@
[2d.imageData.put.clip.html]
[putImageData() is not affected by clipping regions]
bug: https://github.com/linebender/vello/issues/1088
expected:
if subsuite == "vello_canvas": FAIL

View file

@ -1,3 +1,5 @@
[2d.imageData.put.unchanged.html]
[putImageData(getImageData(...), ...) has no effect]
expected: FAIL
expected:
if subsuite == "": FAIL
if subsuite == "vello_cpu": FAIL