Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is a continuation of a now dormant PR draft, #8024. This is intended to be a more streamlined and simplified version, and currently I am only focused on adding three logic nodes involving booleans for the moment.
Boolean Logic Gate
In the original PR, these were all a bunch of nodes that were simply cumbersome to go through. This node effectively combines it into one node right here. We can select NOT, AND, OR, NAND, NOR, XOR, and XNOR, all the logic functions we could ask for.
Boolean Switch
A simple switch node, that surprisingly somehow doesn't exist as a core node. Takes any input, outputs any output, it is agnostic to input and output types and is generally simple and streamlined. I made the inputs optional for a simple reason: somebody could turn off a group or such that this node connects to, and set it to true, which enables it to still just work, and this leads right into the fourth node to be added:
Output Exists
And here is the most dead-simple, yet a node I would argue is quite helpful, the Output Exists node. Does an output from a node exist? Then it's true. If it doesn't? Then it's false, simple as that. To actually defend why this node should exist, I'll give a simple example with the Boolean Switch node:
Here, we have connected the latent outputs to the switch, and connected the switch's boolean to the output exists node. Let's now see what happens when we just disable the HiresFix node here:
Now, we have seamlessly got the initial KSampler to be the image used by the output image here, which also shows the overall usage for the switch node in these types of circumstances.