你可以使用类似
private static function handleResize() :void {
var deviceSize:Rectangle = new Rectangle(0, 0, stage.stageWidth,
stage.stageHeight);
// adjust the gui to fit the new device resolution
}
stage.addEventListener(Event.RESIZE, handleResize);
// call handleResize to initialize the first time
handleResize();
// Then set quality value
if(stage.stageHeight>200 && stage.stageHeight<380){myImageQualitySwitchVar=1}
if(stage.stageHeight>380 && stage.stageHeight<680){myImageQualitySwitchVar=2}
if(stage.stageHeight>800){myImageQualitySwitchVar=3}
和里面的三菱商事的要加载你想要的图像质量,我想创造的东西为你的形象装载机像
if(myImageQualitySwitchVar==1){Image01.load(new URLRequest("LowQualityIMG.jpg"));}
if(myImageQualitySwitchVar==2){Image01.load(new URLRequest("MediumQualityIMG.jpg"));}
if(myImageQualitySwitchVar==3){Image01.load(new URLRequest("HighQualityIMG.jpg"));}
其工作很多做这样,但我能想到的唯一选择就是为不同的设备创建不同的版本。即。 4版本,使用SDk x.x和以下的手机和SDk x.x以上手机的手机版本可以获得不同版本。另外2款适用于SDK x.x之上和之下的特定平板电脑。
希望这有助于。
thx的帮助,但我不认为这将工作,因为它不是关于图像的质量,但问题在于,它需要更大的手机呈现1920x1080像素,而不是800x480的事实。所以在完全相同的构建下,游戏在较低端手机480p和新手机1080p之间更顺畅 – matthy 2014-10-13 20:50:03