Question

I'm trying to make black-outlined objects using the Alternativa3D engine, I'm going for a cartoonish look. How can I do this?

Was it helpful?

Solution

I had a brief look through the Alternativa3D documentation and couldn't find materials or shaders for that. Would you be able to use an alternative 3D API, like Away3D ? If so, Away3D already offers a CellShaded material, as you can see in this sample:

Away3D Cell Shading Example

Also, you have the source for the above example:

var material : ColorMaterial = new ColorMaterial(0xfbcbc1);
material.ambientColor = 0xdd5525;
material.ambient = 1; //0xdd5525;
material.specular = .25;
material.diffuseMethod = new CelDiffuseMethod(3);
material.specularMethod = new CelSpecularMethod();
material.addMethod(new OutlineMethod(0x000000, 2/50));
CelSpecularMethod(material.specularMethod).smoothness = .01;
CelDiffuseMethod(material.diffuseMethod).smoothness = .01;
material.lights = [ _light, _light2, _light3 ];

OTHER TIPS

I don't know if A3D has a built-in solution, but in general case you should make the second model, place it under the existing one and apply entrude and tint to black shaders to it.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top