How to know the Memory usage of a Node?

Godot Version

Godot v4.2.1


Hello, I’m working on a mobile app where you can organize your weekly activities in an Excel like grid system, performance is good, but in the cell entity (the cell node) I used a label node for the text that can be edited in real time using a LineEdit which is invisible and its text_change signal is connected to modify the label. The thing is, at first I wanted to use a TextEdit Node, I couldn’t make it work in the way I wanted, recently I tested it again and now it works, but I started wondering that since TextEdit is a more complex node maybe it has a grater memory usage and as I have several cells in my structure I wanted to know if there is a place where I can find each node’s memory usage to consider it or not; or maybe I just need to test with the monitors which would be a bit difficult because I already have developed a lot of features involving the label. I know that memory usage also depends on context because of referenced resources, but in my case that is not an issue, what about the nodes itself?

Also, I was thinking about use a CodeEdit Node for its text autocompletion, because TextEdit hasn’t it, but again seems an even more complex node that I must use several times and maybe is not a good option and I should make my own system, (I was already working on that and in the extend I need, is not as hard as a complete autocompletition like in a document program)

You can always use the debugging tools and check the memory usage. I don’t think using Label or TextEdit would make such difference, but you can monitor it.

One approach you might want to try, but I believe it’s more challenging, is to use the Servers directly, like in this demonstration where GDQuest uses PhysicsServer directly to multiply the amount of bullets in the screen at the same time.

In your case, you might want to try using TextServer:

1 Like

Okey, I going to test the node’s memory by myself, and wow I already know about the use of servers, but I didn’t know about the text server, it’s a very good idea, probably I’ll check it!

1 Like

I already made some test of Memory Usage and other things for the future of my project and in fact the Memory usage of nodes even on several instances is very small, even if the node’s amount is bigger with the TextEdit Node (Labels reduce it to the half LOL).

With Label:

With TextEdit:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.