Contour line issue

I try to get clear contour from cv but get those extra lines … thought it caused by border spreads so i tried using distance and delete/set spread, but its still there :/

no way to tell whats wrong from your screenshot. post the patch

here it is
oCV.v4p (288.8 KB)

and this ContourCV.vl (16.4 KB)

When drawing multiple line segments in vvvv you need to provide their bin sizes, otherwise you end up drawing lines between the segments too. thats where these extra lines came from. Beside this you had already a spread of values in the bin size pin of line, you probably forgot about.

So 1. When you flattend the point spread to normalize the values in VL you lost already the bin size info. I corrected that by inserting a second for each loop, so you keep the bin size info.
2. Connected the bin size output to the bin size input of line.
I have removed a lot of nodes from your patch i was not sure what they do, to get a better understanding on whats going on. sorry for that.
ContourCV.vl (17.0 KB) oCV.v4p (81.6 KB)

1 Like

yay big thanks,i knew it was something to do with bin size … just didnt got it was in .vl file issue…thanks again

the only thing left is how to bring back b-spline cause it does’nt have bin

you want to smooth the shape?

yes, i used b-spline before

b-splines need control points. how did you use it?
my best guess for smoothing is: Curve Fitting

i’ve used linear spread with amount of points just like in the first attachment (oCV.v4p) …got nice result besides that glitch you have fixed,cover11

Curve Fitting never heard before,gonna check it !

1 Like

isk but its in read in VL

There might be an other missing dependency. Go to Dependencies and see if there is something red, if so, there will be a command to install it. Also search for the help patch in the Help Browser to see a working demo.

its working in gamma but in vl integrated beta its not for me…i’ve installed nuget through beta-vl also


ok found it

You can try with vvvv alpha builds

System.Numerics.Vectors were missing, now its fine… now have to think how to connect spread of spread to sequenceFitCurve

You could also use ResampleBSpline in VL. Not sure how close it comes to your initial method.
Take a look: ContourCV.vl (23.7 KB)
If you just need to get these solo silhouettes out of the image, you could also try to filter the spread of contours in VL just for the longest one (so no bin sizing) and keep the B-Spline approach. Although B-Spline has bin size pins (Inputs/Controls per Curve) i could not get it to work properly with multiple segments.

very nice, this is what i was trying to do with Distance in the first patch in beta…works good, instead of opencv detects the border when its aligned to main shape, have to remove those manualy i thinkCapture312313