- Home /
What is the best way to tween Alpha
Hi there,
I have a series of background images that are attached to a plane. There are two planes, the back one changes to the new texture and then the front one fade out to reveal the new background, then they switch. Basically I am fading in and out a plane with a material on it.
Currently I am using DOTween like so:-
frontBgPlane.GetComponent<Renderer>().material.DOFade(0f, mainScript.mainSwipeFadeSpeed).OnComplete(doSwitch);
I believe this targets the alpha channel of the material and fades it.
I read somewhere that this essentially creates 10 copies of the material at the different alpha states and so eats up a lot of memory. I also read that using vertex colours to do the alpha is the best way to do this.
Can anyone give me any more information on this. Is the above statement true and could I see a large increase in performance if I tween the vertex alpha directly? Also how would I go about doing this?
Thanks a lot for your help
Will
Your answer
![](https://koobas.hobune.stream/wayback/20220611230525im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
normal map, mask different areas? 0 Answers
Alpha Texture Issue 1 Answer
GPU Memory : Impact of Grayscale Textures 0 Answers
Texture memory footprint: is this broken? 0 Answers
Alpha problem with textures on a plane 2 Answers