[Texture Creation] Controllable OneMinus

Greetings, I am going to make this short.
I am working on a rather complex master-material and need some help with a controllable OneMinus. Sort of like a toggle parameter.
Now, I am going to use the OneMinus in order to be able and flip the texture.

How can I do it efficiently?
Where can I add the OneMinus?
How do I make it toggle-able?
Here is my setup for the system:

This is how I would do it :smiley:

016d624a79b6fc9d150c54ac93a1de89f5e401f5.jpeg

The switch will probably cause dynamic branching, And this means it is BAD news for performance.

You would probably be better off makeing a custom implementation of one minus that uses a float to scale its use.
You could use a float to lerp between two outputs, One from before the one minus and one after.
I could post a picture if you want.

HTH

I thought so myself until recently…
However, I learned that only the material shaders get compiled that are used

Anyways… I forgot to add an append vector to make the tiling effective also for non fliiped textures…

500ca497d460d19c6ea1cb46174f309dea9958a8.jpeg

Solved it

Thank you so much sir for helping!

That’s the static switch then?
if so: Ahhhh…

It would be interesting if you could examine the HLSL output to look over for any glaring performance issues that you have caused.

You can examine the HLSL pretty easily. It’s right under the menu.