hey guys. have a question. I recieved a fbx file from my job. and they said that the shader was showing up black in unity3d. the issue is the shader within the editor shows a black opaque circle, and it shows the model as black when in default lighting or ambient. I went into maya 2012, and changed the ambient to 150,150,150 in RGB. I also deleted the shader and reapplied to the model.I am completely stumped why this is the case. anyone else know why perhaps?? I do not have access to the original file but the engineers need the model to come up as a normal shader, or manually change the color from black to default grey. not come up black. and I am completely stumped.
finally solved it.
If you explain how you solved it, this thread might help someone in the future.
Yes, could you please explain how you solved it, as I have a somewhat similar issue, plz.
I had a similar problem with a sample shader, it turned out that i was doing something like this:
a = colorb * (1.0,0.0,0.0,1.0);
It compiled fine, but there is an error I was missing defining the vector type, and that turned my color to black because when compiling:
(1.0,0.0,0.0,1.0) becomes vec4(0.0); colorb multiplied by that gives the Black color.
So always remember to add fixed4/half4/float4 in front of the parenteses. Sometimes mistakes like these pass unobserved, in my opinion a warning should be shown when using an explicit vector but forgetting to put a fixed4 in front of it, or it could compile correctly as vec4(1.0,0.0,0.0,1.0)