private void OnDrawGizmos() { if (m_SerializableVolumes == null) { return; } foreach (SerializableVolume volume in PortalPrepareUtil.FilterVolumeDataNoChildren(m_SerializableVolumes)) { PortalDebugUtil.DrawCube(volume.positionWS, volume.rotationWS, volume.scaleWS, PortalDebugColors.volume); } }
private void OnDrawGizmos() { if (m_SerializableOccluders == null) { return; } foreach (SerializableOccluder occluder in m_SerializableOccluders) { PortalDebugUtil.DrawMesh(occluder.positionWS, occluder.rotationWS, occluder.scaleWS, occluder.mesh, PortalDebugColors.occluder); } }
private void OnDrawGizmos() { if (m_OccluderProxies == null) { return; } foreach (MeshCollider proxy in m_OccluderProxies) { var transform = proxy.transform; PortalDebugUtil.DrawMesh(transform.position, transform.rotation, transform.lossyScale, proxy.sharedMesh, PortalDebugColors.occluder); } }
private void OnDrawGizmos() { if (raySource == null || m_PassedRenderers == null) { return; } PortalDebugUtil.DrawRay(raySource.position, raySource.forward, 10, PortalDebugColors.raycast); PortalDebugUtil.DrawSphere(raySource.position, 0.25f, PortalDebugColors.raycast); foreach (MeshRenderer renderer in m_PassedRenderers) { PortalDebugUtil.DrawMesh(renderer.transform.position, renderer.transform.rotation, renderer.transform.lossyScale, renderer.GetComponent <MeshFilter>().sharedMesh, PortalDebugColors.white); } }
private void OnDrawGizmos() { if (raySource == null || m_PassedRenderers == null) { return; } PortalDebugUtil.DrawRay(raySource.position, raySource.forward, 10, PortalDebugColors.raycast); PortalDebugUtil.DrawSphere(raySource.position, 0.25f, PortalDebugColors.raycast); PortalDebugUtil.DrawCone(raySource.position, raySource.forward, 10, maxAngle, PortalDebugColors.black); foreach (MeshRenderer renderer in m_StaticRenderers) { bool isPassed = m_PassedRenderers.Contains(renderer); PortalDebugUtil.DrawLine(raySource.position, renderer.bounds.center, isPassed ? PortalDebugColors.white : PortalDebugColors.black); } foreach (MeshRenderer renderer in m_PassedRenderers) { PortalDebugUtil.DrawMesh(renderer.transform.position, renderer.transform.rotation, renderer.transform.lossyScale, renderer.GetComponent <MeshFilter>().sharedMesh, PortalDebugColors.white); } }
private void OnDrawGizmos() { if (m_SerializableVolumes == null || m_PassedRenderers == null || m_Rays == null) { return; } foreach (MeshRenderer renderer in m_PassedRenderers) { PortalDebugUtil.DrawMesh(renderer.transform.position, renderer.transform.rotation, renderer.transform.lossyScale, renderer.GetComponent <MeshFilter>().sharedMesh, PortalDebugColors.white); } foreach (SerializableVolume volume in PortalPrepareUtil.FilterVolumeDataNoChildren(m_SerializableVolumes)) { PortalDebugUtil.DrawCube(volume.positionWS, volume.rotationWS, volume.scaleWS, PortalDebugColors.volume); } foreach (RayDebug ray in m_Rays) { PortalDebugUtil.DrawRay(ray.position, ray.direction, 10, PortalDebugColors.raycast); PortalDebugUtil.DrawSphere(ray.position, 0.1f, PortalDebugColors.raycast); } }