(Since several folks have asked about essentially the same problem for Process List
and Build List
, I'm posting this question+answer as a reference. If you're having trouble with Process List
and Build List
, make sure you understand "Tip: How to use the Process List node" in http://vuo.org/node/870 and this question+answer.)
This composition with a Process List
works as expected. It shows a row of rainbow-colored spheres.
But when I add mouse interaction, something's not right. When I move the mouse, some of the spheres (esp. on the ends of the row) flicker with the wrong color. It looks like the list output by the Process List
node's Processed List port is out of order or has repeated items.
Comments
The Process List node's
The
Process List
node's Processed Item input port needs to receive exactly as many events as the Process Item port fired. Too few, and the Processed List port won't fire. Too many, and the Processed List port will fire a list containing unintended items.In the composition above, the problem is too many events hitting the Processed Item input port. The extra events are coming from the
Receive Mouse Moves
node.To fix the problem, insert a
Hold Value
node, as in the composition below. TheHold Value
node's New Value port blocks events (it has a wall), so the events fromReceive Mouse Moves
no longer go throughMake HSL Color
andMake Sphere
to hit theProcess List
node's Processed Item port. TheHold Value
node's refresh port allows events through, so the event from theProcess List
node's Process Item port can grab the value stored inHold Value
and pass it along toMake HSL Color
. (If you're not familiar with the terms or concepts in this paragraph, see the Vuo Manual under the Vuo Editor's Help menu.)In general, there are several ways to troubleshoot problems with
Process List
/Build List
and events. One is just to look carefully at your composition and see if there are any extra cables going into theProcess List
/Build List
node's feedback loop; if so, do they all haveHold Value
or other event-blocking nodes? Another strategy is to temporarily disconnect all cables into theProcess List
/Build List
node's Fire port, turn on the Show Events button in the toolbar, and run the composition; do any nodes in the feedback loop light up?ProcessList-good.vuo
ProcessList-good.png
@jstrecker - Thanks for this!
Jaymie - Thanks for this!
I had posted this bug report regarding this very issue. Of course, after reading this explanation I was able to go back to my composition and add a few
Hold Value
nodes to make the issue go away.Since my bug report no longer appears to report a bug, I'll go to it and add a comment there that includes a fixed example composition and a link back here. Hopefully that will increase the number of people who come across this helpful Q&A.
I'm finding that when i add
.
Yep, this stuff has been
Yep, this stuff has been confusing, thanks so much for this.
I thought I had figured out this issue related to my ToriRings composition, but my solution ended up slightly different for the subcomposition version pictured here (
Hold
nodes in different place), and seems to work fine.To clarify this concept, I was hoping that the event blocking parentheses between
Process Item
and theHold
nodes could be my guide for where to insertHold
nodes when I feed things into the feedback loop. Should I also make sure to insert aHold
after theProcess Item
in this pic? (All hidden cables here are published ports, not shown because it's messy to look at).Screen Shot 2016-02-21 at 7.21.37 PM.png
@jersmi, your composition
jersmi, your composition looks OK to me. Looks like all of the extra events potentially coming into the
Make Torus
node from published input ports are successfully blocked at theHold Value
nodes.