Open vitorbalbio opened 4 years ago
This is likely already resolved in 4.0, because texture flags are set per each CanvasItem (so ViewportContainers too).
This is likely already resolved in 4.0, because texture flags are set per each CanvasItem (so ViewportContainers too).
That's great to know but see that every single project currently in development can't use it and many never will so a solution for the current problem is yet needed if feasible.
Implementation notes:
GLES3 Nearest is specified for the blit here: https://github.com/godotengine/godot/blob/677b63d7656fd0f11e224e0858fcf9479486595d/drivers/gles3/rasterizer_gles3.cpp#L302
Vulkan Sampler for blit is created here with default settings (defaults to nearest) https://github.com/godotengine/godot/blob/78193788d0e779e1471f632bae61adad4adbc078/servers/rendering/renderer_rd/renderer_compositor_rd.cpp#L148
Describe the project you are working on: Space Tactical RPG https://twitter.com/ZeroPointGame
Describe the problem or limitation you are having in your project: Currently ViewportContainers don't have a way to set the interpolation filter what makes it limited to 3D applications.
The usual workaround is to use TextureRects instead as a ViewportContainer but it's not a perfect replacement and there's no point in not expose this property.
On top of it pointing the TextureRect to the same Viewport that is set in the ViewportContainer you can setup their Filter flag what while not be considered a bug (They are the same texture at the end) only shows how much simpler it would be if only this property was exposed in the ViewportContainer directly.
Describe the feature / enhancement and how it helps to overcome the problem or limitation: Expose the Filter flag in the ViewportContainer would just fix this.
Describe how your proposal will work, with code, pseudocode, mockups, and/or diagrams: Just a bool in the ViewportContainer inspector.
If this enhancement will not be used often, can it be worked around with a few lines of script?: I can't be workarounded by code. It's not exposed in GDScript/C# either.
Is there a reason why this should be core and not an add-on in the asset library?: It's a Core Feature of the engine.