Image source 图片来源
LOD stands for level of detail, and it’s the process of making less detailed versions of your models that are viewed when they’re further away from the camera.
LOD代表细节水平,它是制作不太详细的模型版本的过程,当它们远离相机时,可以查看这些版本。
This lowers the strain on the computer allowing it to render more objects while maintaining a high frame rate.
这降低了计算机的压力,使其能够在保持高帧速率的同时渲染更多对象。
There are generally 2 parts of the model that get optimized for LOD. These are the geometry (polygon count) and the texture resolution (lower resolution textures = smaller file size).
模型通常有 2 个部分针对 LOD 进行了优化。这些是几何图形(多边形计数)和纹理分辨率(分辨率较低的纹理 = 较小的文件大小)。
LODs are usually numbered within the real time engine that you use. LOD0 is the full detail model that is viewed closest to the camera. From there LOD1 is a lower detail version, followed by LOD2, etc.
LOD 通常在您使用的实时引擎中编号。LOD0 是最靠近相机查看的完整细节模型。从那里,LOD1是一个较低的细节版本,其次是LOD2等。
LOD’s in Real 3D Work
真实 3D 工作中的 LOD
LODs are used in any AAA 3D game you’ve played.
LOD 用于您玩过的任何 AAA 3D 游戏。
They can be occasionally noticed in what is called “pop-in” when the change happens too close to the camera and an object seems to slightly change very fast. This is considered to be an undesirable result that is tried to be avoided.
当变化发生在离相机太近的地方并且物体似乎变化非常快时,偶尔会注意到它们被称为“弹出式”这被认为是一个试图避免的不良结果。
Image source 图片来源
Most modern real time engines have the built-in functionality to support LODs, so the only thing you really need to do is point the correct models in the LOD numbers and designate the distance from the camera.
大多数现代实时引擎都具有支持LOD的内置功能,因此您真正需要做的就是在LOD编号中指向正确的型号并指定与摄像机的距离。
Some engines such as Unreal Engine 4 even have the built-in functionality to automatically create LODs out of the textures you use, which saves a lot of time.
一些引擎(如虚幻引擎4)甚至具有内置功能,可以从您使用的纹理中自动创建LOD,从而节省大量时间。
Creating LODs is a fairly simple process.
For your model you simply have to remove some of the geometry. If you are using some variation of turbosmooth switch this off for your LODs. You could also manually remove loops of polygons to decrease the count.
创建 LOD 是一个相当简单的过程。
对于模型,您只需删除一些几何图形即可。如果您使用的是涡轮增压滑板的某些变体,请为您的LOD关闭此功能。您也可以手动移除多边形的循环以减少计数。
Most 3D packages have optimizing options which are also worth trying. However, this can ruin your UV’s and damage your model depending which you use so it’s always best to test and keep backups of your work.
大多数3D软件包都有优化选项,也值得一试。但是,这可能会破坏您的UV并损坏您的模型,具体取决于您使用哪种模型,因此最好始终测试和保留工作的备份。
Image source 图片来源
Making LODs out of textures is a much simpler process.
从纹理制作 LOD 是一个简单得多的过程。
Example: if you’re using a 4096×4096 for LOD0, simply save a version as 2048×2048 for LOD1. Then keep cutting the resolution in half as needed.
示例:如果您使用 4096×4096 作为 LOD0,只需将版本另存为 2048×2048 即可表示 LOD1。然后根据需要将分辨率减半。
Remember that game engines generally prefer power of 2 textures, so make sure you follow those rules when resizing images.
请记住,游戏引擎通常更喜欢 2 种纹理的强大功能,因此请确保在调整图像大小时遵循这些规则。
Some modern shaders no longer require manual creation of LODs, having the ability to change the rendered geometry within the GPU. This can procedurally optimize models in real time.
一些现代着色器不再需要手动创建 LOD,能够在 GPU 中更改渲染的几何图形。这可以实时在程序上优化模型。
This newer method can be much more difficult to achieve, so at first you may be better off manually creating your LODs. But automation is something to consider on larger projects.
这种较新的方法可能更难实现,因此起初您可能最好手动创建LOD。但是自动化是大型项目中需要考虑的事情。
If you are producing a 3D game or other large 3D project then you should definitely learn to use LODs.
如果您正在制作3D游戏或其他大型3D项目,那么您绝对应该学习使用LOD。
Even if your game isn’t a huge open world that renders hundreds of objects at once, LODs will always help it perform better, making it run smoother on lower-end hardware.
即使您的游戏不是一个同时渲染数百个对象的巨大开放世界,LOD 也始终可以帮助它更好地运行,使其在低端硬件上运行得更流畅。