diff --git a/Pixi/Images/ImageCommands.cs b/Pixi/Images/ImageCommands.cs index 746a305..399663d 100644 --- a/Pixi/Images/ImageCommands.cs +++ b/Pixi/Images/ImageCommands.cs @@ -167,7 +167,7 @@ namespace Pixi.Images position.x += 1f; position.y += (float)blockSize; string text = PixelUtility.TextureToString(img); - TextBlock textBlock = TextBlock.PlaceNew(position, scale: new float3(Mathf.Ceil(img.width / 16), Mathf.Ceil(img.height / 16), 1)); + TextBlock textBlock = TextBlock.PlaceNew(position, scale: new float3(Mathf.Ceil(img.width / 16), 1, Mathf.Ceil(img.height / 16))); textBlock.Text = text; byte[] textHash; using (HashAlgorithm hasher = SHA256.Create()) diff --git a/Pixi/Images/PixelUtility.cs b/Pixi/Images/PixelUtility.cs index 1f05ee2..d0afdd3 100644 --- a/Pixi/Images/PixelUtility.cs +++ b/Pixi/Images/PixelUtility.cs @@ -149,7 +149,7 @@ namespace Pixi.Images public static string TextureToString(Texture2D img) { - StringBuilder imgString = new StringBuilder(""); + StringBuilder imgString = new StringBuilder(""); for (int y = img.height-1; y >= 0 ; y--) // text origin is top right, but img origin is bottom right { for (int x = 0; x < img.width; x++)