Skip to content

Skia renderer#6574

Draft
bjornharrtell wants to merge 15 commits intoMapServer:mainfrom
bjornharrtell:skia
Draft

Skia renderer#6574
bjornharrtell wants to merge 15 commits intoMapServer:mainfrom
bjornharrtell:skia

Conversation

@bjornharrtell
Copy link
Contributor

@bjornharrtell bjornharrtell commented Jul 13, 2022

Rationale:

  • Likely (much?) better performance
  • Well supported

Notes:

  • Requires C++ 17 as minimum
  • Currently working against local Skia compiled with bin/gn gen out/Static --args='is_official_build=true cc="clang" cxx="clang++" skia_pdf_subset_harfbuzz=false skia_use_libwebp_decode=false skia_use_libwebp_encode=false skia_use_gl=false' is_debug=false

@sdlime
Copy link
Member

sdlime commented Jul 14, 2022

Well this is an interesting addition. Are there advantages over AGG?

@bjornharrtell
Copy link
Contributor Author

@sdlime I have reason to believe Skia can significantly outperform AGG.

@bjornharrtell
Copy link
Contributor Author

bjornharrtell commented Jul 14, 2022

When I began on this I didn't know if it would be achievable without too much effort.. but it is now capable of producing:

ttt

So I'm motivated to continue. :)

@bjornharrtell
Copy link
Contributor Author

bjornharrtell commented Jul 14, 2022

Did some early benchmarking on 3+ million polygon squares. AGG is a lot faster on that case... somewhere 50% - 80% faster. I believe I've compiled Skia with the optimal settings so currently I can't explain this other than that Skia isn't as fast as I had assumed/thought.

@sdlime
Copy link
Member

sdlime commented Jul 14, 2022

Did some early benchmarking on 3+ million polygon squares. AGG is a lot faster on that case... somewhere 50% - 80% faster. I believe I've compiled Skia with the optimal settings so currently I can't explain this other than that Skia isn't as fast as I had assumed/thought.

Still seems like an interesting option as it is maintained and under active development.

@jmckenna
Copy link
Member

jmckenna commented Aug 2, 2022

@bjornharrtell I'll do some Windows testing on this this week. I agree with Steve here, the benefits of using a library that is so well maintained can outweigh other limitations.

@jmckenna jmckenna added this to the 8.2.0 Release milestone Apr 23, 2023
@jratike80
Copy link

@pelord , could you clarify what you want to say?

@jmckenna jmckenna removed this from the 8.2.0 Release milestone May 6, 2024
@jmckenna
Copy link
Member

jmckenna commented May 6, 2024

removing the 8.2.0 milestone label due to recent discussion.

@jmckenna
Copy link
Member

@bjornharrtell just letting you know that the next release plan is coming together, for 8.4.0, in case you have time available before the release to tackle this again. See here for the release plan dates.

(judging by the earlier responses you got about this, I'd say that you have something very interesting, potentially, to others ;)

@oshawa-connection
Copy link

Did some early benchmarking on 3+ million polygon squares. AGG is a lot faster on that case... somewhere 50% - 80% faster. I believe I've compiled Skia with the optimal settings so currently I can't explain this other than that Skia isn't as fast as I had assumed/thought.

Just to add my $0.02. I’ve tried something similar with blend2d graphics library, and I get similar results to you with skia: it’s slower than agg despite all benchmarks saying it’ll be faster.

Consider that most benchmarks are run in programs where the context only has to be setup once as part of a continuously running program, generating several frames as part of some animation.

My theory is that for fast draws of e.g. simple polygons, the overhead of setup of the graphics library context makes the overall render slower than agg. and because CGI that affects all renders. Don’t know if that matches up with what you’ve seen?

@bjornharrtell
Copy link
Contributor Author

@oshawa-connection yeah it could be that the architecture of skia that allows för gpu accel is a disadvantage. That said, I believe they have optimized the software pipeline to great lengths regardless. But I've not dived deep enough to know anything really.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants