Update: Yes, you can put in some dynamic branching. I had some time to mess around and quickly made a simple IF switch custom node. I put it through the ringer and it works great! To benchmark it, I just set up an overkill lerpfest between four 8k textures for the complex part and just a plain color for the simple part. Within the level BP, I made a simple loop that alternates between the two states every 10 seconds (to ensure the graph settles).
One caveat that I’ve found is that if you have any sort of animating going on behind the “deactivated branch,” like a panner, it will keep the textures “hot” in the cycles and they will still contribute to frame time. Though I did only put one of these custom functions in and it was right before the material attributes. It’s a pretty cheap little function, so it probably wouldn’t hurt too badly to throw more of them into the mix; like before things like panners if needed.
[branch] if ( A >= B)
{
return ThroughA;
}
else
{
return ThroughB;
}
When it’s on: ~90ms
When it’s off: ~67ms
So it’s definitely working!
