Alternativa3D - 勾画 3D 对象轮廓

发布于 2024-12-18 16:12:03 字数 55 浏览 2 评论 0原文

我正在尝试使用 Alternativa3D 引擎制作黑色轮廓的对象,我想要卡通外观。我该怎么做?

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

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

想你只要分分秒秒 2024-12-25 16:12:03

我简要浏览了 Alternativa3D 文档,但找不到相关的材质或着色器。您能否使用替代的 3D API,例如 Away3D
如果是这样,Away3D 已经提供了 CellShaded 材质,如您在 此示例

Away3D 单元着色示例

另外,您还有来源:

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

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 ];
甜是你 2024-12-25 16:12:03

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

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.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文