- Home /
Question by
MariuszD · Jan 20, 2016 at 08:21 PM ·
cameraeditorsceneviewonscenegui
Camera properties jitter in OnSceneGUI
Hi there, so, I've got an Editor Script in which I have a code:
[CustomEditor(typeof(TestTest))]
public class TestTestEditor : Editor
{
public void OnSceneGUI()
{
Debug.Log("OnSceneGUI: " + SceneView.GetAllSceneCameras()[0].orthographicSize + "\n");
}
}
And the output for this fragment is:
OnSceneGUI: 294.4149
OnSceneGUI: 294.1218
OnSceneGUI: 294.4149
OnSceneGUI: 294.1218
OnSceneGUI: 294.4149
And so on... Do you have an idea what causes this and how to eventually fix this? It messes up with my custom level editor in which I need precision. Scene View is set to 2D.
Any help would be much appreciated.
Comment