I’m sorry, but I also didn’t fully understand what you’re asking.
I don’t want to hijack the actual sender’s subject here, but simply put:
local draw_options_world = set_camera_world(state) returns nothing in build-in render.script but sets the one of the cameras as main_camera at state. So, the draw_options_world is simply empty, and the state contains only one (the last) camera view/projection/frustum. You may call this a habit, but I like to know which camera’s values are being used (since I sometimes use two cameras in the same render script), so I prefer to get exactly what I needed.
Basically, I would like(this was my suggestion) to access all my cameras and their properties in render.script without needing any get operations. I’m specifically talking about the built-in render.script here. I know we can customize it as we like, but it could be easier for newcomers to get started.
I also need those view/projection matrices and their inverted versions elsewhere. So I had to get and invert them one way or another, and I chose to do it in the render script. Is this the wrong thing to do?
I might not fully understand render.set_camera() -I haven’t used it yet or read its docs- but I have to change the projection/view multiple times (in this case, after the light projection, I set them to the camera’s). Since draw_options_world is empty, I don’t see the point of using the state’s main camera frustum. I can simply set it myself, especially when I have constants. Also sometimes at some places I might prefer not to use frustum at all. My knowledge might be limited on this subject, so please feel free to share any suggestions. I’ll be glad to learn more deeply if I’m mistaken.