Choosing Light Probe positions 选择灯光探测器位置Remember to place probes where you want to sample light or sample darkness. The probes need to form a volume within the scene for the space subdivision to work properly.记得放置好你的灯光探测器的位置,哪里是照亮的地方,哪里是黑暗的地方。场景中的探测器需要达到一定的数量才能烘培,这样做的目的是场景能够被合理的细分。The simplest approach to positioning is to arrange them in a regular 3D grid pattern. While this setup is simple and effective, it is likely to consume a lot of memory (each light probe is essentially a spherical, panoramic HDR image of the view from the sample point). It is worth noting that probes are only needed for regions that players, NPCs or other dynamic objects can actually move to. Also, since lighting conditions are interpolated for positions between probes, it is not necessary to use lots of them across areas where the light doesn't change very much. For example, a large area of uniform shadow would not need a large number of probes and neither would a brightly lit area far away from reflective objects. Probes are generally needed where the lighting conditions change a***ptly, for instance at the edge of a shadow area or in places where pieces of scenery have different colors.最简单的探测器定位方式是将探测器排列成一个规则的3D网格样式,这样设置简单而高效,但是会消耗大量的内存。(从采样点每个灯光探测器本质上是一个球形的,全景的HDR图像)。值得注意的是,探测器仅用于实际上可以移动到所需地区的玩家、NPC或其他动态物体。此外,由于光照条件下插值探测器之间的位置,没有必要使用大量跨区域,灯光不会改变太多。例如,大面积均匀的阴影也不太明亮的区域远离反射物体不会需要大量的探测器。探测器一般需要照明条件的突然改变,比如在一个阴影区的边缘或在背景块的位置有不同的颜色。In some cases, the infras***cture of the game can be useful in choosing light probe positions. For example, a racing game typically uses waypoints around the track for AI and other purposes. These are likely to be good candidates for probe positions and it would likely be straightforward to set these positions from an editor script. Similarly, navigation meshes typically define the areas that can be reached by players and these also lend themselves to automated positioning of probes.在这种情况下, 游戏中的一些基础设施可以被用来作为生成光照探测器的位置参考。例如在赛车游戏中通常我们会在赛道上设置路径点,供AI或者其他方面使用。这些路径点位置就是生成光照探测器的绝佳参考物体。通过编辑器脚本我们可以利用这些资源简单高效的生成理想的光照探测器。同样,地形网格通常被用来规定玩家可以到达的地方。我们也可以利用他们来自动生成光照探测器的位置。Here light probes have been baked over surfaces where our characters can walk on, but only where there are interesting lighting changes to capture:这里我们在角色可以走过的物体表面烘培了光照探测器。但仅仅在有光照变化的地方进行光照信息的捕捉。
Flat 2D levels 平面化As it is now, the light probe system can't bake a completely flat probe cloud. So even if all your characters move only on a plane, you still have to take care to position at least some probes in a higher layer, so that a volume is formed and interpolation can work properly.目前光照探测器系统无法烘培使用完全平面的探测器集。所以,即使你所有的角色只在一个平面上移动,你仍然需要照顾位置至少有一些探测器在一个更高的位置。这有这样布局探测器才能有效的工作。



The probe interpolation requires a point in space to represent the position of the mesh that is receiving light. By default, the centre of the mesh's bounding box is used but it is possible to override this by dragging a Transform to the MeshRenderer's Light Probe Anchor property (this Transform's position will be used as the interpolation point instead). This may be useful when an object contains two separate adjoining meshes; if both meshes are lit individually according to their bounding box positions then the lighting will be discontinuous at the place where they join. This can be prevented by using the same Transform (for example the parent or a child object) as the interpolation point for both MeshRenderers.探测器差值需要使用空间中的一点来表示接受灯光的网格的位置。通常情况下使用包围盒的中心来表示。我们也可以使用自定义的位置覆盖默认的位置只需要将一个Transform(变换)拖拽到MeshRenderer组件的 LightProbeAnchor(光照探测器锚点)插槽上。(这个Transform的位置将被用来表示计算差值的物体中心点)。当我们的游戏物体是由两个分离的相邻网格组成的时候,这个功能非常有用,如果这个这些网格都按照各自独立的包围盒中心作为光照差值点的时候,光照会在他们结合的位置断开。这也能使由多个MeshRenderer组件的组成的游戏物体公用一个Transform(比如使用一个父物体或者子物体)。When an object using light probes is the active selected object in the Light Probes Scene View mode, its interpolated probe will be rendered on top of it for preview. The interpolated probe is the one used for rendering the object and is connected with 4 thin blue lines (3 when outside of the probe volume) to the probes it is being interpolated between:当一个使用了光照探测器的物体在Light Probes Scene View(在场景中查看光照探测器)。模式下被高亮选择以后,它的差值探测器将被渲染到物体的前面这样用户就能够预览到探测器的位置。差值探测器通常被渲染为一个物体,并在探测器的差值范围内显示四条蓝色的线(当物体超出探测器的覆 的范围后将显示三条)。
Dual Lightmaps vs. Single Lightmaps mode| 欢迎光临 纳金网 (http://go.narkii.com/club/) | Powered by Discuz! X2.5 |