Relative and global coordinates

If I draw, for example, a point at a coordinate (0,0) after successively using translate(), scale(); rotate() many times,

Is there a possibility to have the coordinates of the point in the starting reference frame (with the sum of all rotations and scales )?

Another way to ask the same question: how to have the running transformation matrix (not by printing it but by having it in the code)???

N.B. I had found a way to do it that works in Processing (by calculating transformations from near to near) but the same code does not work in P5js (I don’t know why and I have no error in the console!). That’s why I’m looking for another solution to this problem (which would work in Processing AND in P5js).

Hello @EricRogerGarcia,

Look these up in the references:

:)

Thank you very much, I had not seen these functions.
I will look at that…

(I will ask the question again on the P5js category because these functions do not exist in the JS version).