Hi,
I’m using a vertex coloured sky plane model from Blender to create a sky gradient.
I’ve painted near black at the bottom vertices and near white at the top, and I am controlling the sky colour itself via Playmaker/script.
So I require a mobile shader which can read the vertex colours from my Blender mesh, and it also needs a colour. The only shader I can seem to find that does this is a shader called “Simple Texture” (still has a texture slot), and I’m not sure how fast/slow this is.
It does look extremely simple:
Shader "Simple Texture" {
Properties {
_Color ("Main Color", Color) = (1, 1, 1, 1)
_MainTex ("Base (RGB)", 2D) = "white"
}
SubShader {
Pass {
SetTexture [_MainTex] {
constantColor [_Color]
Combine texture * constant
}
}
}
}
Since it fills the whole screen a lot of the time, I’d like to be sure! I have absolutely no idea with shaders I’m afraid! Does iOS play nice without a texture being used, and if that slot is unused, does it affect performance at all?
If you could confirm for me that this is a suitable shader, or know of something better, I’d love to hear it.
Thanks,
Jay