Jump to content
This forum will be closing down. Please move to the respective dedicated project forums.

cocoon blank white screen


erich
 Share

Recommended Posts

Hi

Quick question - I am in the process of creating my first game / app (http://www.html5gamer.mobi/PIXI/TEMPLATE1/index.html) with PIXI and when I run it in windows and browers everything is fine, when I use phonegap and build it I can run it on my samsung note3 (Android version 5), but not my galaxy tabs (tab10.1 ( Android version 4.0.4) and tab 3 (Android version 4.4.2 ), I just get a white screen. (I havent tried an Apple device as I dont have a developer account to test it)

When I use cocoon I get a white screen on all 3 devices, I have tried :

PIXI.autoDetectRenderer

PIXI.webGLRenderer

PIXI.CanvasRenderer

but no joy - has anyone else experienced this problem

thanks in advance

Eric

Link to comment
Share on other sites

Hi Ivan,

I have done up a very basic demo script, this will now work in my older android tablet  v4.4, but only in CanvasRenderer not WebGLRenderer. But the frame rate is terrible, is there a way around this or is version v5 tablets the only solution, I dont want to eliminate my older system users ?

var Container = PIXI.Container,
    autoDetectRenderer = PIXI.autoDetectRenderer,
    Graphics = PIXI.Graphics,
    Sprite = PIXI.Sprite,
    MovieClip = PIXI.extras.MovieClip,
    TilingSprite = PIXI.extras.TilingSprite,
    loader = PIXI.loader,
    resources = PIXI.loader.resources,
    Text = PIXI.Text;
    TextureCache = PIXI.utils.TextureCache,
    Texture = PIXI.Texture,
    BitmapText = PIXI.extras.BitmapText,
    w = 1024,//window.innerWidth,
    h = 512; //window.innerHeight;    
    
//Create a Pixi stage and renderer
var stage = new Container(),
    renderer = new PIXI.CanvasRenderer(w, h);
document.body.appendChild(renderer.view);

// create a texture from an image path
var texture = PIXI.Texture.fromImage('images/blade.png');

// create a new Sprite using the texture
var bunny = new PIXI.Sprite(texture);

// center the sprite's anchor point
bunny.anchor.x = 0.5;
bunny.anchor.y = 0.5;

// move the sprite to the center of the screen
bunny.position.x = 200;
bunny.position.y = 150;

stage.addChild(bunny);

// start animating
animate();
function animate() {
    requestAnimationFrame(animate);

    // just for fun, let's rotate mr rabbit a little
    bunny.rotation += 0.1;

    // render the container
    renderer.render(stage);
}

Thanks in adavnce

Eric

Link to comment
Share on other sites

yep I tried both settings in cocoon (webGL+ and cavas), I seem to get a better working app using phonegap - it actually shows the stage, with cocoon I just get a white screen.

I suppose both technologies are young enough - pixi and cocoon / phonegap, Maybe I will have to sacrifice below android v5 systems for a game app to run correctly.

Thanks for all the help it is appreciated

Eric

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...