void SetAlpha(float alpha){ Vec4 param = mMaterial->GetMaterialParameter(3); mAlpha = param.w = alpha; mMaterial->SetMaterialParameter(3, param); mMaterialParamDest[3].w = alpha; mMaterialParamDest[2].w = alpha; }
void PrepareInterpolation(float time, SkySpherePtr startFrom){ MaterialPtr srcMaterial = mMaterial; if (startFrom) srcMaterial = startFrom->GetMaterial(); for (int i = 0; i < 5; i++) { mMaterialParamCur[i] = srcMaterial->GetMaterialParameter(i); } mInterpolationTime = time; mCurInterpolationTime = 0; mInterpolating = true; }