ViewportRect

Asked 2 years ago, Updated 2 years ago, 48 views

As stated in the title, I would like to change the value of Camera's ViewportRect within C#Script.
What should I do?
Professor, please.

c# unity3d

2022-09-29 20:28

1 Answers

When I tried Unity 4.x, it was configurable using the following methods:

var camera=Get Camera in some way
camera.rect = new Rect(0.0f, 0.0f, 1.0f, 1.0f);


2022-09-29 20:28

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.