Function Viewport.getTexture

Returns the viewport's texture. Note: Due to the way OpenGL works, the resulting ViewportTexture is flipped vertically. You can use Image.flipY on the result of Texture.getData to flip it back, for example:

godot.d.reference.Ref!(godot.viewporttexture.ViewportTexture) getTexture() nothrow @nogc const;

var img = get_viewport().get_texture().get_data() img.flip_y()