Working through some tests I came across this issue. Before thinking of it as a bug I wanted to make sure I was not doing anything wrong on my side with my init/setup procedures.
I have tested on a few iOS devices (iPad1/2, iPod touch 4th gen) and Android devices (Galaxy S3, Droid Incredible, Nexus 10). The content shows up as expected everywhere- except on the Nexus 10.
I am adjusting the viewPort on stage resize. The issue is that (only on the Nexus 10), a black box appears on stage where nothing is rendered. It looks as as if a Flash display list item was dropped over the top, but the only such item in the test app is one hires stat box (which I removed for a test, to no avail.)
The black box is the same size (roughly 645x860) and appears in the same location of the screen each time (roughly 826x702 within the Nexus 10's 1600x2650 resolution, in portrait mode.)
I've attached a few screenshots with the viewport at 2x, stretched to fit, and stretched uniformly to illustrate what's happening. Strange that it only appears on this one Android device (maybe the crazy-high resolution of the Nexus 10 has something to do with this?)
http://thinkspring.net/share/screenshots/nexus10_stretched_052313.png
http://thinkspring.net/share/screenshots/nexus10_uniform_052313.png
http://thinkspring.net/share/screenshots/nexus10_doubled_052313.png
Pasting my startup class below.
package {
import flash.display.*;
import flash.events.Event;
import flash.display.StageAlign;
import flash.display.StageScaleMode;
import flash.display.Sprite;
import flash.geom.Rectangle;
import net.hires.debug.Stats;
import screens.SpriteSheetExample;
import starling.core.Starling;
import starling.display.Sprite;
[SWF(width="480", height="678", frameRate="60", backgroundColor="#000000")]
public class SpriteSheet extends Sprite
{
private static const APP_WIDTH:int = 480;//480
private static const APP_HEIGHT:int = 678;//678
private var stats:Stats;
private var myStarling:Starling;
public function SpriteSheet()
{
stage.align = StageAlign.TOP_LEFT;
stage.scaleMode = StageScaleMode.NO_SCALE;
addEventListener(Event.ADDED_TO_STAGE, onAddedToStageEventHandler);
stage.addEventListener(Event.RESIZE, resizeStage);
}
private function init():void
{
stats = new Stats();
addChild(stats);
var viewport:Rectangle = new Rectangle( 0, 0, APP_WIDTH, APP_HEIGHT );
var myStarling:Starling = new Starling( SpriteSheetExample, stage, viewport, null, "auto");
myStarling.start();
}
private function onAddedToStageEventHandler( e:Event ):void
{
removeEventListener( Event.ADDED_TO_STAGE, onAddedToStageEventHandler );
init();
}
private function resizeStage(evt:Event):void {
trace('resizeStage');
var viewPortRectangle:Rectangle = new Rectangle();
var widthChange = stage.stageWidth/APP_WIDTH;
viewPortRectangle.width = stage.stageWidth;
viewPortRectangle.height = APP_HEIGHT*widthChange;
Starling.current.viewPort = viewPortRectangle;
}
}
}