首先,我想让你了解我的英语。
我使用源代码手动将相机的投影更改为正交。请参考下面的代码。
using UnityEngine;
using System.Collections;
public class CameraOrthoController : MonoBehaviour
{
private Matrix4x4 ortho;
private Matrix4x4 perspective;
public float near = 0.001f;
public float far = 1000f;
private float aspect;
public static CameraOrthoController Instance
{
get
{
return instance;
}
set { }
}
//-----------------------------------------------------
private static CameraOrthoController instance = null;
//---------------------------------------------------
// Use this for initialization
void Awake()
{
if (instance)
{
DestroyImmediate(gameObject);
return;
}
// ? ????? ??? ?? ????? ???
instance = this;
}
private void …Run Code Online (Sandbox Code Playgroud)