OptiPainting Reloaded
这个模组是做什么的?
该模组通过不渲染画作侧面那些永远不可见的部分,来优化画作的渲染。
它是如何优化的?
如果你仔细观察一幅画作,你会发现其侧面有一个向内凹陷 2px 的边框,使得它从墙壁上凸出。在原版游戏中,画作所包含的每一个方块都会渲染这些侧面。这是一种资源浪费,因为这些内部面永远不会被看到。该模组通过不渲染这些面来解决这个问题。
这看起来可能是一个微小的优化,但这些细小的面等同于完整的面块,因此:
- 前面 - 4 个顶点
- 后面 - 4 个顶点
上面 - 4 个顶点
下面 - 4 个顶点
左面 - 4 个顶点
右面 - 4 个顶点
在原版中,每个方块总共有 24 个顶点。而在 OptiPainting 中,每个方块只有 8 个顶点。
顶点数量减少了 66%!
- 如果你有一幅 16x16 的画作,那就是 256 个方块,原版中有 6144 个顶点,而 OptiPainting 中为 2048 个顶点。
- 如果你有一幅超大的 64x64 的画作,那就是 4096 个方块,原版中有 98304 个顶点,而 OptiPainting 中为 32768 个顶点。
| 使用 OptiPainting |
未使用 OptiPainting |
 |
 |
此示例在未渲染背面的情况下展示,以演示该模组的作用。你可以看到原版和模组中画作的背面。
显然,如果你的世界中只是偶尔有几幅画作,你不会注意到太大的差异,但这毕竟是一种免费的优化!
这是 isXander 的 OptiPainting 模组的分支版本!
OptiPainting Reloaded
What's this mod do?
This mod optimizes the rendering of paintings by not rendering the sides of the painting that are never visible.
How's it optimized?
If you have a look at a painting, you'll notice that on the sides there is a 2px indented frame,
so it sticks out from the wall. In vanilla, these faces are rendered for every single block that the painting is made of.
This is a waste of resources, as the inner faces are never visible. This mod fixes that by not rendering these faces.
This may seem like a small optimization, but these tiny faces are equivalent to the full block face, so:
- Front - 4 vertices
- Back - 4 vertices
Top - 4 vertices
Bottom - 4 vertices
Left - 4 vertices
Right - 4 vertices
Makes a total of 24 vertices per block on vanilla. And 8 vertices per block on OptiPainting.
That's a 66% reduction in vertices!
- If you have a 16x16 painting, that's 256 blocks, which is 6144 vertices in vanilla, and 2048 vertices in OptiPainting.
- If you have a super-large 64x64 painting, that's 4096 blocks, which is 98304 vertices in vanilla, and 32768 vertices in OptiPainting.
| With OptiPainting |
Without OptiPainting |
 |
 |
This example is rendered without the back face to demonstrate what the mod does.
You can see the back of the painting in vanilla and with the mod.
Obviously, if you only have the occasional painting in your world, you won't notice much of a difference, but it is free optimization none-the-less!
This is a fork of isXander's OptiPainting mod!
评论 0
登录后参与评分
还没有评论,来抢沙发吧