浏览代码

Merge pull request #135 from Unity-Technologies/zxw/update_readme

Zxw/update readme
/siyaoH-1.17-PlatformMessage
GitHub 3 年前
当前提交
ec710b66
共有 2 个文件被更改,包括 18 次插入13 次删除
  1. 18
      README-ZH.md
  2. 13
      README.md

18
README-ZH.md


# UIWidgets
# UIWidgets 2.0 (preview)
## 介绍

UIWidgets主要来自[Flutter](https://github.com/flutter/flutter)。但UIWidgets通过使用强大的Unity引擎为开发人员提供了许多新功能,显著地改进他们开发的应用性能和工作流程。
UIWidgets 2.0是UIWidgets的最新版本,它主要着力于UI绘制相关的整体性能优化。经测试,UIWidgets 2.0在iPhone 6等部分机型上的帧率相对1.0版本可以取得10%左右的提升。如果因为各种原因您还需要使用UIWidgets 1.0,请在Releases中下载对应的包或者使用uiwidgets_1.0分支。
#### 效率
通过使用最新的Unity渲染SDK,UIWidgets应用可以非常快速地运行并且大多数时间保持大于60fps的速度。

```
在unity的PackageManager中,选择添加添加local file。选中```/com.unity.uiwidgets```下的```package.json```。
对于windows,请用在```com.unity.uiwidgets/Runtime/Plugins/x86_64```下的 ```libEGL.dll, libGLESv2.dll```替换编辑器中中相应文件
对于windows,请用在```com.unity.uiwidgets/Runtime/Plugins/x86_64```下的 ```libEGL.dll, libGLESv2.dll```替换编辑器中相应文件
#### 运行环境
UIWidgets目前暂时只支持MacOS(Metal),iOS(Metal),Android(Armv7,OpenGLes)以及 Windows(Direct3D11)。我们后续会针对更广泛的运行环境进行适配,敬请期待。
## 入门指南

首先,请打开或创建Unity项目并使用Unity编辑器打开它。
然后打开Project Settings,转到Player部分并**将“UIWidgets_DEBUG”添加到Scripting Define Symbols字段中。**
这样就启动了UIWidgets的调试模式。 在之后发布版本的时候清空这个字段。
#### 二、 场景构建

#### 五、如何加载图像?
1. 将你的图像文件,如image1.png,放在StreamingAssets文件夹中。
2. 使用Image.File(“image1.png”)加载图像。
2. 使用Image.file("image1.png")加载图像。
2. 使用Image.file(“loading1.gif”)加载gif图像。
2. 使用Image.file("loading1.gif")加载gif图像。
#### 六、在安卓上显示状态栏
当一个Unity项目运行在Android设备上时,状态栏是默认隐藏且无法在编辑内进行调整的。

13
README.md


# UIWidgets
# UIWidgets 2.0 (preview)
[中文](README-ZH.md)

UIWidgets is mainly derived from [Flutter](https://github.com/flutter/flutter). However, taking advantage of
the powerful Unity Engine, it offers developers many new features to improve their Apps
as well as the develop workflow significantly.
As the latest version, UIWidgets 2.0 aims to optmize the overall performance of the package. Specifically, a performance gain around 10% is observed on mobile devices like iPhone 6 after upgrading to UIWidgets 2.0. However, if you still want to use the original UIWidgets 1.0, please download the archived packages from Releases or switch your working branch to uiwidgets_1.0.
#### Efficiency
Using the latest Unity rendering SDKs, a UIWidgets App can run very fast and keep >60fps in most times.

for windows, please replace ```libEGL.dll, libGLESv2.dll``` in Editor from ones in ```com.unity.uiwidgets/Runtime/Plugins/x86_64``
#### Runtime Environment
Currently UIWidgets only supports MacOS(Metal), iOS(Metal), Android(Armv7, OpenGLes) and Windows(Direct3D11). More devices will be supported in the future.
## Getting Start
#### i. Overview

First of all, please open or create a Unity Project and open it with Unity Editor.
And then open Project Settings, go to Player section and **add "UIWidgets_DEBUG" to the Scripting Define Symbols field.**
This enables the debug mode of UIWidgets for your development. Remove this for your release build afterwards.
#### ii. Scene Build
A UIWidgets App is usually built upon a Unity UI Canvas. Please follow the steps to create a

UIWidgets supports Gif as well!
1. Put your gif files in StreamingAssets folder. e.g. loading1.gif.
2. Use Image.asset("loading1.gif") to load the gif images.
2. Use Image.file("loading1.gif") to load the gif images.
#### Show Status Bar on Android
Status bar is always hidden by default when an Unity project is running on an Android device.

正在加载...
取消
保存