x


Change colour of mobile VertexLit or Deffuse

Is it possible to change the colour of a Mobile VertexLit or Mobile Deffuse shader like below ?

renderer.material.color = Color.red;
more ▼

asked Jul 15 '12 at 10:10 AM

Griffo gravatar image

Griffo
1.7k 20 48 67

(comments are locked)
10|3000 characters needed characters left

2 answers: sort voted first

to change a color of material your shader must support this color as a parameter. all parameters that shader supports you can see in material properties when you choose a shader. if there's no color property, then answer no - you can not change a color such way. add color property and modify calculation inside shader source or choose another shader that supports color change.

more ▼

answered Jul 20 '12 at 10:53 AM

ScroodgeM gravatar image

ScroodgeM
7.6k 2 6

(comments are locked)
10|3000 characters needed characters left

Thank you ..

more ▼

answered Jul 20 '12 at 06:46 PM

Griffo gravatar image

Griffo
1.7k 20 48 67

(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x273
x13

asked: Jul 15 '12 at 10:10 AM

Seen: 401 times

Last Updated: Jul 20 '12 at 06:46 PM