I am testing a game with 3 projectors(multi monitor) with a final screen resolution 5760 x 1080. I want to change by code Camera>Fov Axis but I can’t figure how, I got this error: “Member ‘Camera.VerticalToHorizontalFieldOfView(float, float)’ cannot be accessed with an instance reference; qualify it with a type name instead”. I have tried this codes: `
[SerializeField] Camera[] cams3;
void Update()
{
if (Input.GetKeyDown(KeyCode.End))
{
ChangeFovAxis();
}
}
void ChangeFovAxis() {
var cam = Camera.main;
cam.VerticalToHorizontalFieldOfView(1, 1); // doesn't work same error from the loop below
for (var i = 0; i < cams3.Length; i++)
{
cams3*.VerticalToHorizontalFieldOfView(90, 1); // I need to change the 3 cams*
}
Camera.VerticalToHorizontalFieldOfView(90, 1); // no error but nothing happens
}