I create a CanvasItem through RenderingServer. CanvasItemCreate() and RenderingServer has a method called CanvasItemSetTransform(), but it doesn’t have a method called CanvasItemGetTransform(). How can I get the Transform for this RID?
If you have just created a CanvasItem through the rendering server, the transform will be equals to Transform2D.Identity until you call the set transform method.
If you create a CanvasItem-derived Node, then you can access the transform as the transform property. Otherwise you have to set the transform manually from the RenderingServer, so you must have had it at some point. You just have to keep track of that manually if it’s that important. I cannot conceive a use case for this, tho. You’re omitting crucial details about your intent.