FOVE SUPPORT CENTER

Changing the field of view of the cameras

Comments

4 comments

  • Official comment
    Avatar
    Scott Harper

    The perceived FOV is determined at runtime by the FOVE plugin and SDK via manipulating each camera's projection matrix in order to minimize user sickness, and so the FOV number shown in the inspector has very little bearing on that.

    However it can be useful to change the cameras' FOV values to correctly indicate information to Unity for culling and rendering shadow buffers, etc... The value specified on the camera prefab should be copied over correctly, however if you are not using a camera prefab, then the value will likely be whatever Unity's default is.

    If you are trying to use a camera prefab but its values and components aren't appearing on the generated objects, make sure that "Use Camera Prefab" is checked in the inspector.

    However, you've indicated that you want to be using two cameras, which means you should make sure that "Use Camera Prefab" is NOT checked, and that "Use Camera Override" IS checked, and the camera you want for the left camera is attached at "Left Eye Override" and the camera for the left eye is attached at "Right Eye Override".

    Let me know how that goes for you.

    Cheers!
    -- Scott

    Comment actions Permalink
  • Avatar
    cimagn

    Thanks for the reply Scott.

    We are using FOVE for a research study and need a slightly larger field of view at runtime.

    I have tried doing the following things but they all end up in a FOV of 70 at runtime:

    1) Changing the value of FOV in the supplied camera prefab ("Use Camera Prefab" is checked) - does not work, the two cameras attached have the FOV set to 70.

    2) Since the above did not work, I created two cameras in the scene and set their FOV values. These were then used as inputs to the left and right camera overrides. In this case "Use Camera Prefab" was unchecked and "Use Camera Override" was checked. --- Running in this configuration resulted in four cameras appearing in the scene (2 which I had created and 2 attached by plugin at runtime).

    3) I then tried to rename my two scene cameras with the name of cameras that are attached at runtime and this seemed to work resulting in only two cameras attached to the interface. However these cameras reset the FOV to 70 again.

    Please let me know if I can try any other methods since we have been stuck on this for a while now.

    Thanks again for the reply and your help.

     

    0
    Comment actions Permalink
  • Avatar
    Scott Harper

    Okay, so if you need a wider field of view, you SHOULD be able to (this is an undocumented configuration used only for internal dev, so I don't know how well it will work) open (or create if it's not there) C:\ProgramData\Fove\FoveVR.config, and add "FOV_IN_DEGREES=100.0" or whatever you want your FOV to be. The fefault value at the moment is 95.0. Changing this config value will change the FOV for all FOVE applications, so I don't know if that is sufficient for your needs or not?

    There is no way to change the HMD's FOV real-time at the moment, but it sounds like you maybe want the whole experience to have a higher FOV, in which case the above change might work for you.

    As for what you're seeing in Unity's inspector, it appears to be a hardcoded value at the moment, which is probably a bug. However, as I said previously, the value you see in Unity's inspector panel has no actual bearing on the perceived FOV in the headset, it's only used by Unity's internal object culling and shadow drawing functions because we are overriding the the projection matrix on the cameras directly, and according to their docs, "If you change this matrix, the camera no longer updates its rendering based on its fieldOfView. This lasts until you call ResetProjectionMatrix."

    I'll think about the correct path to take for the inspector's FOV -- there might be an override I can work out by the next version of the plugin, but I'll have to look deeper into our runtime internals.

    0
    Comment actions Permalink
  • Avatar
    cimagn

    That's outstanding Scott, worked perfectly! Thanks!

    We do not need a real-time change in FOV, we keep it the same throughout the experiment.

    Thanks again :)

    0
    Comment actions Permalink

Please sign in to leave a comment.