-
-
Notifications
You must be signed in to change notification settings - Fork 291
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Gradients Node #1544
Gradients Node #1544
Conversation
- 1, 3, 4 channels (color picker widget would be nice) - horizontal, vertical, diagonal, radial, conic - up to three color levels per gradient (UI is awkward)
set channels in output type
This has made me realize how badly we need a color picker input lol |
Before we add a gradient node, we should really finally implement a proper color picker (as a separate PR prior to this one). We need this for multiple other nodes, and this node is just too much without it. My suggestion remains to implement a color picker as a Popover (https://chakra-ui.com/docs/components/popover) that activates when selecting the singular color input. Perhaps we could pick from and use one of these pre-designed React color pickers: https://casesandberg.github.io/react-color/. Even if we don't use one of these, it still offers an API for building our own. As a side note, the color and position could be implemented as a group, allowing people to add additional color inputs (like how Text Append works). |
Yeah I was thinking the exact same thing |
How about a version of this that doesn't offer any color options, and just produces a gradient from [0,1] grayscale with whatever shape options? The rest could be done with a LUT if needed. That's maybe the more modular, node-y approach anyway. |
That definitely could work |
- More modular - Can use a LUT to map colors if needed - Punts on the need for a color picker widget - NOTE: did this on my laptop without testing, so this might not actually run
That could work as a stopgap, but I think that's all that should be seen as. With a proper color picker and groups, I think we can manage something much fuller featured. |
We could have a node for turning greys to a color gradient, with specialized color picker widgets. It would be useful for the output of this and also other images. As inspiration: Blender's color ramp node |
Something color ramp-like would be cool, but I'm not sure how we could best implement it in the most chaiNNer-esque way. It would be nice to make it so users could input a colors via connection so we could have a Color Input node that could be connected to other nodes. Time for a crappy mockup (I'm so sorry): The colors swatches would be clickable to bring up the color picker. In an ideal world, the preview would have the movable squares like blender or GIMP as well so that their positions could be adjusted manually or by number input (Ignore that I drew it as output lol). There would also be dimensions and a Gradient Style dropdown like in the initial version (I was too lazy to add it to the mockup). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this looks good, and even though the overall way of creating colored gradients is limited right now i think this is a great starting point. Anyone disagree?
Could we at least add some directionality controls to horizontal, vertical, and diagonal? With that, I think it would be an okay starting step until we can get the fundamentals necessary for a more advanced gradient node implemented. |
- add "reverse" checkbox - "angle" and "width" controls for diagonal
Sounds good for now. 👍 |
A node that creates a variety of gradients.