Problem with IOboxes and values incoming order

Hi ! :)

I got a problem with some IOboxes. In fact, I linked several IOboxes (values advanced) on a Contour boxes (to get x,y,witdh, height… for each tracked shapes). Those IOboxes display 10 values (because Contour can track 10 shapes at once) so I got 0 to 10 values varying in those IOboxes.

The problem is that when a new shape is detected, there is a new value appearing in the IObox (the “x” one for example) but it’s not appearing in the right line. for example if I’m already tracking 3 shapes, so I got 3 “x” values in the IObox, then a new shape is detected, so a 4th value income in the iobox, but instead of coming after the first three ones (on the 4th line) it come on the 1st line (if I put slice numbers in the box, that mean that when a new shape is detected by Contour’Box, the 1st shape become the 2nd shape, the 2nd one become the 3rd one…)

I’ll make a little schema (cause my english isn’t vry clear I think)

what vvvv do in IOboxes :

1| 1st value
2| 2nd value

then a new value
income in the IObox:

1| new value
2| 1st value
3| 2nd value

and I want it to be like this :

1| 1st value
2| 2nd value


1| 1st value
2| 2nd value
3| new value

Is it possible to set it like that ?

thats in fact a problem of the contour tracker and not of the io boxes…

you can sort the order with a sort node attached to the id output of the contour, then use former index to sort the rest of the values…

i made a module wich fixes exactly that problem, but i dont have it here ill upload it later this day…


wha ! thanks elektromeier, so glad to ear that its possible to solve this problem :D

I didn’t really know what is a “former index” (i’m still a beginner i think ^^ ) so if you have time, could you please explain me the method you spoke about above (and also I tried to find by myself a sort node in node’lists, but it seem that I didn’t manage to find the right one, which one do you mean ? )

see the attached patch…
just ask if you need help with the patch…

ContourSorted (Freeframe DShow9 ).v4p (24.3 kB)

it’s perfect dude ! It works :)

thanks so much