毛刺阴影问题(Dx11) [英] Problems with glitchy shadows (Dx11)

查看:80
本文介绍了毛刺阴影问题(Dx11)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在关注这些教程: rastertek.com 但是我在做#48教程时遇到了一个问题,因为某些原因影子没有不匹配对象的形状,并且是地形上的随机故障,我已经尝试了所有内容,从教程中复制+粘贴文件和着色器,我查了大约100次代码检查它是对的,但我不能让它正常工作,我希望有人可以提供帮助!



(链接到VS2010项目): Mediafire



编辑:我认为这是渲染到纹理设置或阴影着色器的问题,我将平面模型的纹理设置为渲染到纹理输出,它显示的是一个大的黑色图像,中心有一个小的白色到黑色渐变,慢慢旋转,还有地形和阴影看起来完全没有像我在渲染到纹理上看到的那样,这引导我相信阴影着色器没有正确读取阴影贴图



如果您不能打扰运行代码,这是我的问题的图像:

< img src =http://i.imgur.com/4YpzVyW.pngtitle =由imgur.com主办/> ;



如你所见,阴影非常迟钝。

I've been following these tutorials: rastertek.com but I have encountered an issue while doing tutorial #48, for some reason the shadows don't match the shape of the objects and are random glitches on the terrain, I've tried everything, copy+pasting files and shaders from the tutorials, I went over the code about 100 times checking it was right, but I can't get it to work correctly, I hope someone can help!

(Link to VS2010 project): Mediafire

I believe this is an issue the render-to-texture setup or the shadow-shaders, I set the texture of a plane model to the render-to-texture output and all it showed was a large black image with a small white-to-black gradient in the center, that was slowly rotating, also, the terrain and shading looked absolutely nothing like what I saw on the render-to-texture, which lead me to believe the shadow shader wasn't reading the shadowmap properly

If you can't be bothered running the code, here's an image of my problem:
<img src="http://i.imgur.com/4YpzVyW.png" title="Hosted by imgur.com"/>

As you can see, the shadows are pretty retarded.

推荐答案

I设法通过从网站下载源代码并将其更改为适合我需要呈现的内容来修复它。
I managed to fix it by downloading the source code off of the website and changing it to suit what I needed to render.


这篇关于毛刺阴影问题(Dx11)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆