1.在Unity项目场景中添加一个空物体,将脚本ScreenAdaptation.cs(Please download it from:http://download.csdn.net/detail/wuming22222/7475273)添加该空物体上;
2.假设你项目的正常屏幕分辨率为:480*320(Width*Height),打开空物体的脚本ScreenAdaptation.cs将其中width赋值480f,height赋值320f,单击空物体在Inspector中的Width和Height分别设置为480和320,Cameras数组个数设为1并将UIRoot(2D)中的Camera拖到该数组中;
3.单击UIRoot(2D),在Inspector中将UIRoot(Script)的Scaling Style设为FixedSizeOnMobiles,ManualHeight设为:320;
4.运行游戏,改变Game面板的Free Aspect处的分辨率查看效果吧;
P.S.:上面的文件ScreenAdaptation.cs还可以用于3D,<To Be Continued>
GoodLuck!@@