Skip to main content
Up and Coming
August 16, 2013

v0.2.4 overrides custom Far Clip Plane settings?

I've been using some rather large FarClipPlane settings, and the recent 0.2.4 release ignores these settings, unless I hardcode them into the default values of the OVRCameraController.cs script.

Bug in the new UpdateCamerasDirtyFlag system, or am I doing something wrong? I used to edit FarClipPlane in OVRCameraController.
    This topic has been closed for replies.

    5 replies

    Inspiring
    August 16, 2013
    I think the problem is that in the new Unity integration, private member variables are getting set to an initial value. This will override anything you put into those fields in the inspector as a result.
    Titans of Space PLUS for Quest is now available on DrashVR.com
    Up and Coming
    August 17, 2013
    Yeah. A new bug.
    You can add "[SerializeField]" right before the private fields to force unity to serialize the private field.

    Hope this gets fixed.
    I also hope they'll optimize the scripts. Hate to see the likes of:
    gameObject.camera.transform.rotation.eulerAngles;

    when you can simply call:
    transform.rotation.eulerAngles;

    Or even cache the transform.
    Inspiring
    August 19, 2013
    You need to edit OVRCameraController.cs around line 106 and add:

    [SerializeField]


    On the line immediately above the private declarations of the near and far clip planes.

    This will be fixed in the next version of the SDK.
    AMD Ryzen 7 1800X | MSI X370 Titanium | G.Skill 16GB DDR4 3200 | EVGA SuperNOVA 1000 | Corsair Hydro H110i Gigabyte RX Vega 64 x2 | Samsung 960 Evo M.2 500GB | Seagate FireCuda SSHD 2TB | Phanteks ENTHOO EVOLV
    Up and Coming
    December 4, 2013
    I am having a similar problem where I use a game object called "Pilot" and attach the OVRCameraController to it. Inside the object I attach a left and right camera.

    When I run the game, I have a blue culling square directly in front of me because of how big the area is. If the game is running and I change the far plan value to make it larger it fixes the problem. however, if I change the default value to be, say, 3000 instead of the default 1000, when i run the game there is no change and I still see a blue square.

    However, in the scene view, if I select the object holding the pilot and cameras, it's clear that the view should cover the skybox I'm using and no square should be seen.

    Weirder still, if I select the pilot, which is holding the OVRcameraController script, it fixes my issue.

    What seems to be happening is that the farplane is defaulting to 1000.0f until i actually select the object in the hierarchy, which fixes the issue.

    Obviously this is a problem because if I build an executable, I have no way of accessing the hierarchy.
    Up and Coming
    December 4, 2013
    I am having a similar problem detailed here:

    viewtopic.php?f=37&t=3650&p=73694#p73694