x


LineRenderer not affected by material alpha setting

Why does the LineRenderer not appear to respect the material alpha value set in SetColors? I'm setting it to values from 0.9 to 0.0, but the opaqueness never seems to vary. Why is this?

more ▼

asked Dec 27 '09 at 03:49 AM

james.jeffers gravatar image

james.jeffers
5 3 4 4

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

1 answer: sort voted first

Check your shader. The following worked for me:

Shader "line" { Properties { _Color ("Color Tint", Color) = (1,1,1,1) _MainTex ("SelfIllum Color (RGB) Alpha (A)", 2D) = "white" } Category { Lighting On ZWrite Off Cull Back Blend SrcAlpha OneMinusSrcAlpha Tags {Queue=Transparent} SubShader { Material { Emission [_Color] } Pass { SetTexture [_MainTex] { Combine Texture * Primary, Texture * Primary } } } } }

more ▼

answered Dec 29 '09 at 01:15 PM

jbishop gravatar image

jbishop
16 2

(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:

x275
x243

asked: Dec 27 '09 at 03:49 AM

Seen: 1327 times

Last Updated: Dec 27 '09 at 03:49 AM