BinSize spreadMax error

Hey devvvs

i’m getting issues with spreadMax being passed into

void IPlugin.Evaluate(int spreadMax)

(and subsequently into my node)

The situation is:
2 inputs (enum and value) have 6 slices entering, both with BinSize set to -1
We expect spreadMax to report 1 (as all elements from both inputs should be packed into single respective slices). This is true most of the time but sometimes it switches to 6 every few frames (no user input).

hmm…
there must be something sporadic influencing it
it’s in my VideoIn (CLEye) node

spreadMax doesn’t work properly in case of spread of spreads, as the unmanaged side isn’t aware of it and only looks at the pins, so if one pin has 6 slices, spreadmax is at 6.
you can use the extension method CombineWith to compute the spreadmax value manually on your spreads.