Well, Point and Rectangle are not objects - they are struct s. Thus, they do not have the presence of a heap (if they are not on the field), but, on the contrary, copying them can have an effect (not huge - they are not very large).
If you use them in a narrow loop, then fine - pre-initialize them in a variable. Of course, you can simply reorganize the current x / y and width / height to use Point , etc. For storage. Note also that (unlike most scenarios) they are actually mutable structures, so you can change your internal values inside your loop, etc.
Also note that in IIRC there are overloads of many graphical operations that take primitive values instead of structures - do you consider them?
Ultimately, however, I do not think that this will have any noticeable effect compared to actual graphics operations. Do not stress this; if your code works ...
source share