jamesearnest244 Posted June 5, 2022 Share Posted June 5, 2022 (edited) Hi, I have a FLIP color mixing situation, but I'm using more than two colors. Let's say four, for now. My basic approach is this: 1) Create four attributes on all source particles, so a single particle would have for example all of these: f@blue =0; f@green = 0; f@yellow = 0; f@red = 1; 2) Find a way to mix the attributes during the sim 3) Transfer these attributes to the mesh, and then modulate the shader color with this input. I'm looking for advice on how to get them mixing correctly in the sim. Attribute Transfer in a SOP solver might play a role here, but the issue is I need to find a way to normalize the influence of these attributes so they'd always add up to 1. That is, if one attribute increases, its influence is subtracted from another. Kind of like when painting weights in rigging. I've watched a bunch of tutorials on color mixing, but they're always with just two colors, which simplifies things greatly. Been wrestling with this one for a while and I'd really appreciate any ideas on how to achieve this. Thanks very much for any advice! Edited June 5, 2022 by jamesearnest244 Quote Link to comment Share on other sites More sharing options...
j00ey Posted June 13, 2022 Share Posted June 13, 2022 To do the normalising step you can do something like this [in a wrangle in your SOP solver] - float total = f@blue + f@green + f@yellow + f@red; f@blue /= total; f@green /= total; f@yellow /= total; f@red /= total; Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.