I had the assumption that, when drawing into a Node2D (with draw_line or others) , Godot was internally creating a texture cache , and draw directly on this texture. Then this texture was passed to the video card, so the draw function doesn't need to be executed on every frame.
But, if I made 500 calls to the draw_line function inside the on_draw( ) call back, it became super, super slow (on my android at least). So my assumption is somewhere wrong.
Are the draw_line operations are executed directly by the video card on every frame ?
How this is working.
I think it is important that I understand the basic so my code is optimized.
Thanks for your help.