浏览代码

fix invalid texture size issue

unity will report error if the external texture's width or height is 0. In this PR, we fix it
/main
xingweizhu 3 年前
当前提交
3a622dec
共有 1 个文件被更改,包括 3 次插入0 次删除
  1. 3
      com.unity.uiwidgets/Runtime/engine/UIWidgetsPanelWrapper.cs

3
com.unity.uiwidgets/Runtime/engine/UIWidgetsPanelWrapper.cs


}
bool _recreateRenderTexture(int width, int height, float devicePixelRatio) {
width = Mathf.Max(1, width);
height = Mathf.Max(1, height);
if (renderTexture != null && _width == width && _height == height &&
this.devicePixelRatio == devicePixelRatio) {
return false;

正在加载...
取消
保存