Zaidar Posted December 11, 2013 Share Posted December 11, 2013 Hi everyone, I have a Nexus 4 with Chrome v31. I use in my game this code :function create(){ game.stage.backgroundColor = '#87ab63';}It works fine on my desktop, but when I access it with ny nexus, I have this result : The backgroundColor doesn't apply. Same issue on this url : http://gametest.mobi/phaser/examples/_site/view_full.html?d=input&f=multi+touch.js&t=multi%20touch To debug this, I randomly tried to add a border and then the backgroundColor was displayed on my mobile, as shown in this screenshot : (I add red background to debug afterwards) : So what do you think about that ? Is it a problem somewhere else in my code (not really big just begun) ? Can you replicate the issue ? Thanks for any answer, cheers, PS : sry if I was quick, but I closed my tabs so I had to rewrote the post PS2 : going to bed as it is late here (melbourne), so I'll try to keep up with your answer PS3: sry for attachements, the forum doesnt accept png from imageshack apparently (to not use too much storage space) Link to comment Share on other sites More sharing options...
jcs Posted December 11, 2013 Share Posted December 11, 2013 guessing it's a (mobile) chrome/blink issue - perhaps with the adreno gpu. I get the same on my Nexus 5 and 7 (both w/ chrome 31); unfortunately I don't have my 2012 Nexus 7 with me to check against (same chrome, tegra gpu) Zaidar 1 Link to comment Share on other sites More sharing options...
Zaidar Posted December 11, 2013 Author Share Posted December 11, 2013 Many thanks for the testing.There surely is a way to use a background color but I will need to use my own "canvas background coding" instead of the game.stage.I don't have time time to make more testing today, but as Phaser use Pixi.js and just seems to use getter and setter to determine background color, I think it may be a pixi.js rendering issue, but I may be totally wrong. Link to comment Share on other sites More sharing options...
Zaidar Posted December 12, 2013 Author Share Posted December 12, 2013 I know a can create background color by creating a box with the width and height of the canvas, but PIXI seems to me like a big black box. Is there a way to change the way PIXI render the canvas background without having an error every line ? Link to comment Share on other sites More sharing options...
Zaidar Posted December 12, 2013 Author Share Posted December 12, 2013 I everyone, I continue with my spam, apparently this is an issue as you can see on this link : https://code.google.com/p/chromium/issues/detail?id=324404 So basically, <canvas width="800" height="600" style="background-color: rgba(0,0,0,0)"></canvas>Doesnt work on nexus 4 and 5 at least. My solution would be instead of giving the properties to the canvas, giving it to the parent (like the width, height, and background) to make it looks like it's the canvas. Link to comment Share on other sites More sharing options...
jcs Posted December 12, 2013 Share Posted December 12, 2013 just tried it on the 2012 Nexus 7 (Tegra chipset) and it works fine. as all the devices we've tried and in that bug report are qualcomm adreno GPUs, I'm guessing it's an issue with the adreno subsystem in chrome/android just part of the joys of supporting a multitude of devices Zaidar 1 Link to comment Share on other sites More sharing options...
Zaidar Posted December 12, 2013 Author Share Posted December 12, 2013 Yes, well thank you very much for testing. That's really annoying when it comes form the hardware, at I higher level I can at least try to tweak the app, but I can't change the hardware of the devices. Anyway, thanks. Link to comment Share on other sites More sharing options...
Recommended Posts