How to fill the entire drawing shape with colour in VL openCV

How can I fill the entire shape with colour when using the draw nodes (such as draw polygon) in openCV VL? It just seems to show the border outlines.

Try Floodfill. Use the centre of you shape and the colour as input.

However, you will have far more flexibility using Skia.

Thank you for the fast reply.
I tried Floodfill and got it working for single shapes but would it be possible to use it for the spread version of the draw nodes like drawPolygons? Because I have many in my scene…

I will try exploring Skia as well.

I cannot check the patches right now, but there is something like StrokeWidth -1 which would fill them up if I remember properly.

use a foreach region, put the Floodfill node in it and accumulate image for each shape, center and color.

it is called “Thickness”

I am not sure if it is a bug on my side but I can’t seem to be able to set the thickness to -1 for the DrawPolygon/s node (it becomes a red node).
It works fine for the DrawCircle and DrawRectangle nodes.

true, doesn’t work for polygons. so is there any reason for why you’re not using skia for drawing?

Yea, I will try use skia for it then.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.