[Interest] Transparent rectangle with radius in one side

Julien Cugnière julien.cugniere at gmail.com
Tue Oct 5 10:52:53 CEST 2021


Le mar. 5 oct. 2021 à 04:28, Murat ŞEKER via Interest
<interest at qt-project.org> a écrit :
> We have a Quick scene where we draw a lot of semi-transparent rectangles and those rectangles are rounded in one side. As a representative :
> ...
> As it can be seen from the snippet above we use clipping to achieve rounding in one side however that comes with a significant cost in batching as
> the number of those rectangles are quite high.

Have you considered BorderImage ? You could use an image with rounded
borders only on one side, and it would look the same, with a single
item. Not convenient if the radius is not fixed, though.

-- 
Julien Cugnière


More information about the Interest mailing list