Replies: 1 comment
-
If your working with Vectors/IPath instances then IPath has a Transform methods that takes a Matrix3x2 that can be used to translate and scale the vector from your base coordinate system to that used by the image. It also has a couple of extension methods Other option you have is make use of the PS. For drawing over and over again you will want to try and reuse |
Beta Was this translation helpful? Give feedback.
-
Is there a build-in way to transform/scale coordinate system? Let's say, image ix 1000x1000, but my mapped coordinate system is from 0..1. Of course, I can multiply/divide them manually, but the question is, is there a build-in way?
The reason is, in my engine I introduced now a new resolution-independent coordinate system, so every drawn UI objects (OpenGL) will scale automatically if resizing the screen. this works fine except for the texture generation (via image sharp).
so, if I want to draw a line from 0.1x0.1 to 0.9x0.9, it should draw a line from 100x100 to 900x900 (if the image is 1000x1000). It's just a sample
otherwise, I need to wrap every Mutate draw call.
Beta Was this translation helpful? Give feedback.
All reactions