0
\$\begingroup\$

I have a set of 3D points that I need to "blend" between. Lets say I have points [A,B,C] and I have the amount I want to blend each as [0.5, 0.2, 0.8], how can I blend between these points with the amount I need? I asked this previously and got an answer.

But, when all values are 0, I need to return to a Default point, so all blending must take effect as if deviating from the Default.

How do I calculate this? I'm sure its not just a weighted barycenter anymore?

\$\endgroup\$

1 Answer 1

1
\$\begingroup\$

Calculate the relative offset from Default to each point and add them on top of Default with the given weights. This means that you can't divide by the sum of the weights unlike in the previous answer you got.

deltaA = A - Default;
deltaB = B - Default;
deltaC = C - Default;
point = Default + deltaA * weightA + deltaB * weightB + deltaC * weightC;
\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .