Compare commits
2 Commits
f933c8d1c4
...
3dafb6e8a9
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3dafb6e8a9 | ||
|
|
49c7ca4792 |
@ -7,6 +7,7 @@ using TMPro;
|
||||
using UnityEngine.EventSystems;
|
||||
using DG.Tweening;
|
||||
using System;
|
||||
using Org.BouncyCastle.Asn1;
|
||||
|
||||
namespace QFramework.Example
|
||||
{
|
||||
@ -169,8 +170,9 @@ namespace QFramework.Example
|
||||
float sizeY = ((float)Screen.height / (float)Screen.width) * size;
|
||||
ScreenShotPainter.instance.SetEraserSize(size, sizeY);
|
||||
|
||||
float width = Screen.width / size;
|
||||
float height = Screen.width / size;//不缩放y轴了
|
||||
float width = 1920 / size;
|
||||
float height = 1920 / size;//不缩放y轴了
|
||||
Debug.LogError($"{width} : {height}");
|
||||
Icon.transform.localScale = new Vector3(width / Icon.rectTransform.rect.width, height / Icon.rectTransform.rect.height, 1);
|
||||
}
|
||||
else
|
||||
@ -180,8 +182,8 @@ namespace QFramework.Example
|
||||
float sizeY = ((float)Screen.height / (float)Screen.width) * size;
|
||||
ScreenShotPainter.instance.SetPaintingSize(size, sizeY);
|
||||
|
||||
float width = Screen.width / size;
|
||||
float height = Screen.width / size;//不缩放y轴了
|
||||
float width = 1920 / size;
|
||||
float height = 1920 / size;//不缩放y轴了
|
||||
Icon.transform.localScale = new Vector3(width / Icon.rectTransform.rect.width, height / Icon.rectTransform.rect.height, 1);
|
||||
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user