(简单)2D 纹理(图块)的阴影,位于纹理后面

发布于 2025-01-06 17:25:11 字数 503 浏览 5 评论 0原文

我正在使用 XNA 为 XBOX 360 开发一个应用程序。 我试图保持它非常简单和地铁风格。

我的图块是这样排列的: http://gameplay-video.com/wp-content/uploads/2011/img_2462_xbox-360-dashboard-update-sceens-5th-dec-2011.jpg

我想要什么实现的方法是使用与图片中一样的灰色/黑色背景,但具有相同的阴影。

我相信照明点位于瓷砖后面,瓷砖本身不应该有内部阴影。然而,它们的底部应该有一个阴影,如图所示(底部的小黑线)

我不是 XNA 方面的专家,这是我的第一个应用程序(atm 运行得非常好),但我'我愿意学习。

I'm developing an app for the XBOX 360 using XNA.
I'm trying to keep it very simple and metro-style.

My tiles are arranged like this:
http://gameplay-video.com/wp-content/uploads/2011/img_2462_xbox-360-dashboard-update-sceens-5th-dec-2011.jpg

And what I want to achieve, is using a grey/black background like the one in the picture, but with the same shadow.

I believe the lighting point is behind the tiles, the tiles themself should not have an inner shadow. However, they should have a shadow at the bottom, as seen in the picture (the small darker line at the bottom)

I'm no expert in XNA, this is my first application (which is going pretty good atm), but I'm willing to learn.

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

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

发布评论

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

评论(1

无悔心 2025-01-13 17:25:11

我认为最简单的方法是绘制瓷砖两次,第二次它们将是黑色的,并使用某种模糊着色器在 y 轴上向下缩放(和偏移)。

I think the simplest way would be to draw the tiles twice, the second time they would be black and scaled (and offset) down on the y axis, using a blur shader of some sort.

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