英文:
Why can I see invisible mesh faces through transparent faces?
问题
以下是翻译好的部分:
标题可能不太准确,因为我不太确定发生了什么。我正在开发一个体素引擎,并且正在使用LibGDX。我正在构建每个16x16的区块,并且只在网格的每个面与空气接触的地方,或者非实体块旁边紧挨着实体块的地方创建面。所以如您在附图中所见;在水下,您看不到每个区块的任何面,但在水上方,您只能通过水的透明度来看到它。我不应该在水下看到任何奇怪的矩形,因为它们都应该是透明的。
因为目前这个问题对我来说毫无意义,所以我不太确定还应该分享什么。
有人对此有深入了解吗?
英文:
The title might be off, because I'm not 100% sure what is going on. I am working on a voxel engine, and am using LibGDX. I'm constructing each chunk of 16x16 and am only creating faces on my mesh where the sides touch air, or if a non-solid is next to a solid. So as you can see in the attached images; underwater, you don't see any sides of each chunk, but above water you can see it only through the water's transparency. I shouldn't be seeing any of those strange rectangles under water, as it should all be see-through.
I'm not sure what else to share because currently this issue makes no sense to me.
Does anyone have insight into this?
专注分享java语言的经验与见解,让所有开发者获益!
评论