Unlit Material?

Software: Away3D 4.x

davedev, Newbie
Posted: 29 September 2014 07:15 PM   Total Posts: 5

I’d like to have a background plane that is white using a color material and later has a texture applied. However, I want these to display with no shading, lighting, etc. Each pixel would either be pure white to begin with or later the exact pixel color of each pixel in the texture. Is this possible with Away3D? I know elsewhere I’d use an “unlit” shader.

   

davedev, Newbie
Posted: 30 September 2014 05:48 PM   Total Posts: 5   [ # 1 ]

After experimenting, I’ve found:

var colorMaterial = new ColorMaterial(0xffffff);
colorMaterial.specular 1.0;
colorMaterial.ambient 2.0

gives me a white background and

_textureMaterial.specular 1.0;
_textureMaterial.ambient 1.25

Gives me a relatively “unlit” texture. Please tell me if a better way exists for doing this. Thanks.

   

Avatar
Fabrice Closier, Administrator
Posted: 30 September 2014 07:10 PM   Total Posts: 1265   [ # 2 ]

by default materials are not recieving any light influence. Unless you add a lightPicker and fill it with lights. Color materials are when not lighted displaying only the color you give,  TextureMaterial display their diffuse map as is.

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X