extends Control onready var viewport := $'%viewport' func _draw(): draw_texture_rect(viewport.get_texture(), Rect2(Vector2.ZERO, rect_size), false) # texture = viewport.get_texture()