Replace Backdrop with Bound_box
I am doing a little cleanup work on my Cartan Node Library. Unless I hear a solid objection, I am going to deprecate one current node, backdrop, and replace it with a simpler node, bound_box. These changes will occur in the next 2.3 release of the library,
Backdrop took in a shape or group of shapes and returned it surrounded by a colored backdrop rectangle. I thought this would be useful, but over the last few years I only used it once. One problem with it was that I often did not want the shape grouped within the rect, and ungrouping sometimes caused a loss of structure. Since it's easy to make a backdrop on the fly without including the shape, this node added little value and was easy to do without.
I have, however, often found myself needing to create rectangles the same size or slightly bigger or smaller than a given shape or group of shapes (without the shape inside). Sometimes I need to draw a rectangle with proportions defined by some other geometry. Other times I need to use the rect with a compound or delete node. Or, if I ever do need to make a colored backdrop, a bound_box node would get me most of the way there in a single bound.
I have included a copy of this new bound_box node in the attached demo. It takes a path or geometry, adds or subtracts a margin, and returns a rect based on the bounds of the input, colored as a transparent outline. You can then recolor it if desired and either use it as the input to another node or combine and group it with other elements. A margin of x will add x pixels around all four sides of the rect, resulting a rect with dimensions (w+2x) times (h+2x). It works nicely with my corner node for finding the outer corners of shape.
Both of these nodes are dirt simple, and are easy to make on the fly. I finally decided to include bound_box in my library, though, because I found myself reinventing that wheel again and again. And I removed backdrop because it failed the same test.
Some may ask why deprecate nodes which, though not as useful as hoped, still work. I am trying to keep the size of my library to a manageable number of nodes. Each new node adds a cognitive load and makes it harder to find the node you're looking for. So my motto is "use it or lose it."
- bound_box_screenshot.png 261 KB
- bound_box_demo.ndbx.zip 1.11 KB
|?||Show this help|
|ESC||Blurs the current field|
|r||Focus the comment reply box|
|^ + ↩||Submit the comment|
You can use
Command ⌘ instead of
Control ^ on Mac