You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A game featuring different kinds of consoles, each with its own resolution and unique games.
Describe the problem or limitation you are having in your project
Each console add the game running scene on a subviewport that has the console resolution, which is different from project settings resolution so when i add the camera to the console game the camera has size from project settings. So to avoid this I'm using a ReferenceRect node with a simulate the camera view, so when the game start a gamera substitue the ReferenceRect to Camera
Each console adds the game running scene to a subviewport configured with the console's resolution, which differs from the project settings resolution. However, when I add the Camera2D node to the any console game, the camera inherits the project settings resolution. To avoid this, I'm using a ReferenceRect node to simulate the camera view. When the game starts, a camera replaces the ReferenceRect.
Editor view
Red rectangle is RectangleRect
Pink rectangle is the Camera2D view
In-game view
Describe the feature / enhancement and how it helps to overcome the problem or limitation
A custom way to set the camera size helps better visualize the camera view when working with subviewport textures. This is especially useful when applying zoom in the editor, as the camera view doesn’t match the actual in-game view.
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
Add a checkbox to replace the default camera view size to a custom size, so when the checkbox is selected the camera view size is the same as defined on custom size Vector2 property.
Custom size set to false:
Custom size set to true:
How it's look on editor:
2025-01-19.16-53-20.mp4
The zoom property must work on custom size rectangle view too.
I think that this can be useful with Camera3D too.
If this enhancement will not be used often, can it be worked around with a few lines of script?
This can be achieved with a ReferenceRect that is replaced during when in-game. However, if the camera has functions that run like tool or animations, these also need to be added to the ReferenceRect to allow testing within the editor.
Is there a reason why this should be core and not an add-on in the asset library?
This enhances the workflow with subviewports, improving the ability to visualize what will be displayed by the camera.
The text was updated successfully, but these errors were encountered:
Calinou
changed the title
Add property to change the camera view rectangle.
Add a property to change the Camera2D view rectangle gizmo's size
Jan 20, 2025
Describe the project you are working on
A game featuring different kinds of consoles, each with its own resolution and unique games.
Describe the problem or limitation you are having in your project
Each console add the game running scene on a subviewport that has the console resolution, which is different from project settings resolution so when i add the camera to the console game the camera has size from project settings. So to avoid this I'm using a ReferenceRect node with a simulate the camera view, so when the game start a gamera substitue the ReferenceRect to Camera
Each console adds the game running scene to a subviewport configured with the console's resolution, which differs from the project settings resolution. However, when I add the Camera2D node to the any console game, the camera inherits the project settings resolution. To avoid this, I'm using a ReferenceRect node to simulate the camera view. When the game starts, a camera replaces the ReferenceRect.
Editor view
Red rectangle is RectangleRect
Pink rectangle is the Camera2D view
In-game view
Describe the feature / enhancement and how it helps to overcome the problem or limitation
A custom way to set the camera size helps better visualize the camera view when working with subviewport textures. This is especially useful when applying zoom in the editor, as the camera view doesn’t match the actual in-game view.
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
Add a checkbox to replace the default camera view size to a custom size, so when the checkbox is selected the camera view size is the same as defined on custom size Vector2 property.
Custom size set to false:
Custom size set to true:
How it's look on editor:
2025-01-19.16-53-20.mp4
The zoom property must work on custom size rectangle view too.
I think that this can be useful with Camera3D too.
If this enhancement will not be used often, can it be worked around with a few lines of script?
This can be achieved with a ReferenceRect that is replaced during when in-game. However, if the camera has functions that run like tool or animations, these also need to be added to the ReferenceRect to allow testing within the editor.
Is there a reason why this should be core and not an add-on in the asset library?
This enhances the workflow with subviewports, improving the ability to visualize what will be displayed by the camera.
The text was updated successfully, but these errors were encountered: