Texture:getRect accept a resultRect as param

- optimized getRect for texture and subtexture
- fix wrong getRect result for subtexture