-
-
Notifications
You must be signed in to change notification settings - Fork 112
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
Performance Comparison #3
Comments
It would also be extremely interesting to see a comparison with Skia. The currently compared libraries are "old", although Qt has perhaps evolved the most of them architecturally. |
NVPR: I'm interested in this technology, but I think it would be fair to wait for multithreading before starting the comparison of software-based 2D against dedicated GPUs. As written on the website, Blend2D was written to make software-based 2D rendering faster so at the moment we compare with other software-based 2D renderers. I cannot comment ARM platforms atm as the work on ARM hasn't started yet. SKIA: I tried building SKIA twice and was not successful with that. Since they use build system that I don't understand and that has minimum documentation I decided to not spend more time on this. Now when Blend2D is finally out anyone is welcome to contribute SKIA module to |
Skia's build system is indeed somewhat esoteric and non-friendly to outsiders. I have a functional CMake setup to build Skia in my Skui project here (it's inside the third party submodule and currently at a somewhat older version of Skia: m67): If you run cmake in a recursive clone of skui, and then build the "skia" target you should be good to go. I haven't done anything wrt installing it as a separate lib with headers though (on my todo list) so perhaps reusing the "3rdparty" repo is the easiest way to get a build of Skia working. I can't promise anything on implementing a benchmark in blend2d, but I'm interested so if I find the time to help, something might pop up here. |
I retrieved the page https://www.slideshare.net/Mark_Kilgard/22pathrender p41 p42 should come from a Nvidia talk |
Currently, we are offsetting curves to stroke a path. It means that the rendering of Blend2D from page 41 will look similar to Skia and Qt. According to SVG this is expected behavior (https://www.w3.org/TR/SVG2/painting.html#StrokeShape). I think it would be technically possible to make it look like e.g. OpenVG Reference but it might be expensive to do so. The rendering from page 42 should be no problem :) |
I'm wondering about the path from page 42, is there any data? |
It would be nice to add Fastuidraw to the benchmarcks, it seems to be the only 2D renderer to have benchmarcks being many times faster than the current state of the art: Skia. |
Well better add EDIT: GTK4 is moving away from Cairo and directly using OpenGL/Vulkan calls. So keep an eye on them. Also Qt / Qt Quick is moving away from their QPainter and using hardware rendering as well (like using Scene Graph). |
@Danger89 interesting, I'm not an expert but does that means they'll switch from a retained renderer to an immediate mode? If so it is known to be suboptimal for 2D guis and scrolling. |
I think it's the opposite - GTK is abandoning the immediate rendering model by introducing a scenegraph toolkit, which makes sense for UI where you only want to redraw what actually changed, or to redraw everything if there was changed too much. With scenegraph this becomes manageable. However, I'm not sure how this could be used to benchmark Blend2D, which implements immediate rendering model at the moment - I'm not sure it would make sense to add scene-graph to Blend2D, more likely to have another library that implements it. I think the best comparison would be with something GPU optimized which implements immediate mode, fastuidraw and SKIA would be good candidates. |
Time has passed and Skia comparison would be really interesting. |
The benchmarking suite and samples will soon use Conan to fetch dependencies (both Cairo and Qt, and maybe even AGG). If anyone is willing to add a SKIA recipe to conan-center-index (issue here: conan-io/conan-center-index#2389) then I would implement the rest (SKIA benchmark module). I would like to avoid maintaining build scripts to build SKIA and its dependencies, it's just too fragile and I prefer doing more interesting things instead. |
I totally support this. I think it would be of enormous value even if the SKIA benchmark would be unmaintained (i.e. would become "old" soon) after benchmarking. |
A benchmark comparison with ThorVG would be very interesting, too. ThorVG is a dependency-free lightweight software renderer that utilizes threading. It's scene-based, but currently no partial redraw is supported as far as I know, so comparisons would be fair :) I've just been working on updating the ThorVG renderer for Rive files (here), and I am wondering if I should try a Blend2D version next. |
I think Blend2D would beat ThorVG SW renderer significantly, because ThorVG is basically using FreeType code, which was not written for performance. I would assume ThorVG and Qt to give you similar performance (ThorVG maybe worse in some cases as it has very limited SIMD use, Qt at least has SIMD composition). |
I agree. ThorVG was created to run on low resource devices, like smart TVs, so performance was not the top priority. However I would be interested to see exactly what the difference is :) |
I have managed to build Skia via vcpkg and I have already a local branch that can test Skia with bl_bench. After this is merged I would close this issue as I'm not planning to test against Direct2D or FastUIDraw in near future (I don't really have time for that). If there is anyone willing to add Direct2D to bl_bench I would be happy though. |
I think this issue can finally be closed, because:
|
I'm closing this issue, please open a new one if you miss a library to be benchmarked against, and if possible, provide an implementation as well, as for me the currently benchmarked libraries are enough to get an overview of Blend2D performance and optimization opportunities. |
As far I remember, NVidia peoples of the NVPath project did interesting comparisons with libraries like Cairo etc. especially cases where rendering was wrong.
Also it would be interesting to benchmark on GPU-less ARM platforms, Qt do benchmark driven optimisations on such platforms (with or no OpenGL GPU).
Edited by Blend2D Team:
Performance comparison of the following libraries would be welcome:
The text was updated successfully, but these errors were encountered: