We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e1cfff6 commit dbb3d3fCopy full SHA for dbb3d3f
1 file changed
AssetStudioUtility/SpriteHelper.cs
@@ -82,7 +82,7 @@ private static Image<Bgra32> CutImage(Sprite m_Sprite, Texture2D m_Texture2D, Re
82
var polygons = triangles.Select(x => new Polygon(new LinearLineSegment(x.Select(y => new PointF(y.X, y.Y)).ToArray()))).ToArray();
83
IPathCollection path = new PathCollection(polygons);
84
var matrix = Matrix3x2.CreateScale(m_Sprite.m_PixelsToUnits);
85
- matrix *= Matrix3x2.CreateTranslation(textureRect.width * m_Sprite.m_Pivot.X - textureRectOffset.X, textureRect.height * m_Sprite.m_Pivot.Y - textureRectOffset.Y);
+ matrix *= Matrix3x2.CreateTranslation(m_Sprite.m_Rect.width * m_Sprite.m_Pivot.X - textureRectOffset.X, m_Sprite.m_Rect.height * m_Sprite.m_Pivot.Y - textureRectOffset.Y);
86
path = path.Transform(matrix);
87
var graphicsOptions = new GraphicsOptions
88
{
0 commit comments