The behavior is pretty strange, I checked our code of draw function in CCSprite.
context.drawImage(image, locTextureCoord.x, locTextureCoord.y, locTextureCoord.width, locTextureCoord.height, flipXOffset, flipYOffset, locDrawSizeCanvas.width, locDrawSizeCanvas.height);When the glitches happens, the real value for this line is :
context.drawImage(image, 0, 96, 32, 48, 0, -420, 280, 420);
And (0, 96, 32, 48) is the correct value for cutting sprite from the texture.
Then I have done some test
In this image,
context.drawImage(image, 0, 48, 32, 48, 0, 0, 280, 420); draws the first sprite with one real pixel on top of the head
context.drawImage(image, 0, 49, 32, 48, 280, 0, 280, 420); draws the second one, with one original pixel lost at the top and one original pixel plus at the bottom. And if you look closely, you can still see one real pixel above the head which shouldn't be there
context.drawImage(image, 0, 48, 32, 49, 560, 0, 280, 420); draws the third one, which appears to be normal.
When I start to cover the image with white pixels, strange things happens. With the exact same rect, there always remains one pixel at the top.
Code I used was these lines:
context.fillRect(0, 0, 280, 420);
context.fillRect(280, 0, 280, 420);
context.fillRect(560, 0, 280, 420);
I think it's a bug of browser in full screen mode. In the code of engine, we can't do any thing about it. You mentioned that your own implementation of full screen doesn't do the same thing, I wonder how? If it do work, I'm interest in the difference between our implementations. Thanks