Wilfrick Posted October 24, 2021 Share Posted October 24, 2021 Dear All Is it possible to control whether a node within a marionette network is enabled from within the object info palette of the marionette object? eg: I've got a network in which sometimes I want the symbol mirrored and sometimes I don't. Can I achieve something like a 'Mirrored: Y/N' within the object info palette? Thanks all Will Quote Link to comment
Jesse Cogswell Posted October 24, 2021 Share Posted October 24, 2021 @Wilfrick You can totally do this. What you will need is a Boolean input node named "Mirror" attached to a Valve node. At the very end of your network, add a Mirror node attached to the Valve. What's important is that all of your geometry nodes appear BEFORE the Valve so that it gets generated properly before getting flipped. 2 Quote Link to comment
willofmaine Posted October 25, 2021 Share Posted October 25, 2021 In what I think is a similar vein... Is there a simple, or at least reliable, way to include or exclude specific geometry within a Marionette object via the OIP?? I've struggled with this pretty much since day one. I've had limited success with the "If" node, and my few successes I can't seem to incorporate into other networks. This morning I was yet again struggling with this when I stumbled across this thread; not sure I'd ever heard of the "Valve" node before. After several attempts (different locations in the network) I was able to get it to work. But when I wrapped the network and used it as a node in a larger network, I believe it killed the rest of that larger network. Is there a simple True / False node that will either pass whatever's put into it if True, or just exclude / destroy / make nonexistent whatever's put into it if False? (I.e., "pass this thing," or, "pass nothing"... without crippling the rest of the network and without the need to (confusingly and rarely successfully) delete unwanted duplicates). As an example, I have a simple stair run Marionette, which includes geometry to indicate minimum head height (you know, super-sophisticated clash detection...). It would be nice to make that geometry optional with a checkbox in the OIP. Thanks for any thoughts! Quote Link to comment
Jesse Cogswell Posted October 25, 2021 Share Posted October 25, 2021 @willofmaine I think the only way I've found to reliably do what you are asking is to use either Valve or If nodes to block off input data. A Symbol node won't place a symbol if it doesn't have the string symbol name input, a Circle node won't produce a circle if it doesn't have a a radius input. But if a geometry-creating node exists and has enough of its parameters filled, it will generate geometry regardless of its placement within the network. 1 Quote Link to comment
willofmaine Posted October 25, 2021 Share Posted October 25, 2021 @Jesse Cogswell Ah! Okay, that is tremendously helpful. With a couple of "If" nodes I was able to stop both the symbol name and the width (set to zero) of an associated extrude's rectangle, and that seems to have done the trick. I suspect my previous successes were only when I unknowingly did as you've described. Thanks!! 1 Quote Link to comment
KingChaos Posted November 1, 2021 Share Posted November 1, 2021 Sry, why Block off input data? Quote Link to comment
Jesse Cogswell Posted November 1, 2021 Share Posted November 1, 2021 @KingChaos You would block off input data to prevent geometry from being drawn. Let's say that you have a Marionette object that can either be a circle or a rectangle based off of a drop-down or radio button in the OIP. You would need a Circle node and a Rectangle node in the network to achieve this, but if you supply enough input data into either node (radius for Circle, width and height for Rectangle) both objects would be drawn. So you would use some way of preventing the input data from reaching the nodes to ensure that only the desired object is drawn using either Valve or If nodes. I personally prefer to use Valve nodes for this, as they are simpler. I've attached a small demo showing how this works (in VW2019 format, it's what I had open when I read this post. I did quickly test it in VW2022 and it seemed to work fine). The named input variables are a Radio Button node named "Shape" (custom edits to name the options) and a Real node named "Size". The "Shape" node will output either a 0, 1, or 2 based on what option is chosen in the OIP. I use three Equal nodes to check the "Shape" output and will pass a TRUE if it matches. The "Size" node is plugged into the input of Valve nodes, which will allow the input to be passed on if it receives the TRUE input from the Equal nodes. The div nodes just halve the "Size" data since the Circle and Regular Polygon nodes use radius instead of diameter. In summary, the Valve nodes are preventing the "Size" input data from reaching the Object nodes unless they're the chosen shape. Marionette Valve Demo.vwx 1 Quote Link to comment
KingChaos Posted November 1, 2021 Share Posted November 1, 2021 But what for is it? What u have and what u need? I wann know, why u doing such a stuff? U want to detect, what geometry is in the input? Quote Link to comment
KingChaos Posted November 2, 2021 Share Posted November 2, 2021 Is it possible, to inhibit that VW will show a variable in the OIP? Maybe i make such similiar situation like your network. Input is a selector, rectangle, circle or hexagon. IF it is a circle, you can input a radius, if rectangle u can input a & b and a hexagon u can input edge count and inner/outer radius? So i dont need a&b in a circle or hexagon, so i am looking for a way that u can "hide" the named input variables which u define as not needed? br KC Quote Link to comment
Jesse Cogswell Posted November 2, 2021 Share Posted November 2, 2021 Unfortunately, I don't think there's any way to toggle the visibility of an OIP parameter with Marionette. You can certainly do it with Plug-in Objects scripted in Python or Vectorscript, but I can't think of a way to do it in Marionette. Any input node given a name will appear in the OIP, but there's no way to change a node's name from within a Marionette network. 1 Quote Link to comment
KingChaos Posted November 2, 2021 Share Posted November 2, 2021 Thank, you. I thought in a different way -> they dont appear in the OIP if they are not connected to the network. With an if node it seems that they are not connected IF if is not true. Quote Link to comment
KingChaos Posted November 2, 2021 Share Posted November 2, 2021 i get a circle and a square Quote Link to comment
KingChaos Posted November 2, 2021 Share Posted November 2, 2021 Why you dont make 3 parametrical marionettes (a square, a circle and hexagon) and select them with radio button? Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.