Closed Wither362 closed 1 week ago
This looks interesting, I already need to redesign image views to work with arbitrary shapes & functions. This might need to wait though, since this stuff is performance critical (image views are taken into account each time you manipulate a pixel)
This looks interesting, I already need to redesign image views to work with arbitrary shapes & functions. This might need to wait though, since this stuff is performance critical (image views are taken into account each time you manipulate a pixel)
Ok, I know some ways to make the image stay in the right position, I could add them too (but only if you like the idea)
Another thing, I think the approach of having more view stats (such as rounded
) is probably preferred, since it makes the most sense with the current way of calculating views & probably includes the least overhead.
Another thing, I think the approach of having more view stats (such as
rounded
) is probably preferred, since it makes the most sense with the current way of calculating views & probably includes the least overhead.
Yeah, you’re right, but I can’t find a way to calculate a rounded rectangle, I asked my friends, and they told me this:
@ShaharMS, I have a question, how do I use these functions for this code to work:?
MathTools.radiansFromPointToPoint2D(start, end);
MathTools.radiansToSlope(radians);
MathTools.radiansToDegrees(radians);
I’ve seen them in Line2D.hx, and it may help with this
The first function returns the angle between two points in radians, the second and third functions convert between different notations of angles - degrees, slopes and radians. You could see how I use these functions in other files
Squircle? https://en.m.wikipedia.org/wiki/Squircle
TODO:
trace
, I don’t know if it will work)It’s a cool feature I would like to be added, it uses an algorithm I’ve "created" because I don’t find information for doing it…
I created this pull request for you (Marcus) to see if this could be added, or if this code break everything, and I need help doing this…
So, @ShaharMS, if you can help me with this, it would help me a lot