2011-12-01 88 views
1

我试图用Alternativa3D引擎制作黑色轮廓的对象,我要做一个卡通化的外观。我怎样才能做到这一点?Alternativa3D - 概述3D对象

+0

呵呵,[边疆]( http://g-ecx.images-amazon.com/images/G/01/videogames/detail-page/borderlands.02.lg.jpg)。 – Marty

回答

1

我对Alternativa3D文档进行了简要介绍,并找不到材料或着色器。你能够使用替代的3D API,如Away3D? 如果是这样,Away3D中已经提供了CellShaded材料,你可以在this sample看到:

Away3D Cell Shading Example

而且,你有source对于上面的例子:

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 ]; 
1

我不知道A3D是否有内置解决方案,但是通常情况下,您应该制作第二个模型,将其放置在现有模型下,并将黑色着色器应用于其着色和着色。

+0

我认为这是一个可怕的想法。加倍你的聚合计数只是为了得到一个轮廓?当然,这是着色器可以处理的或某种其他形式的后处理。 – 2014-07-08 06:05:25