I'm relatively new to Godot. I couldn't figure out how to draw a node on a texture.
For example, in my case, I try to draw a Polygon2Ds polygon on ImageTexture:
var tex = ImageTexture.new()
var poly: Polygon2D = $Polygon2D
# how to draw poly.polygon on tex ?
I know of draw_polygon, but that method draws on the game screen directly.
I need the texture in order to pass it to another node using textures.