I'm porting an iPhone game to the iPad. When I move textures "quickly" (5.0 pixels every update at a rate of 60 Hz) I start to see little "artifacts" or remnants of where the texture used to be. I'm not sure if I know the correct terminology for this... imagine a texture at some location on the screen... then next to it is the same texture but faded a bit... then the same texture again just faded a bit more.
I'm using CADisplayLink to drive my update loop if that helps. Also I didn't see this issue on the 3G or the iPhone 4. Any ideas?
Cheers!
Answer
I don't know whether you mean this or not ..but i have this problem when i'm using render Texture in cocos2d.When the player sprite is moved,the sprites residue used to be ther for 3-5 frames.Clearing the alpha of the render texture fbo fixed the problem.Please mention the problem clearly if you have still problems.
[Updated]
Once have a look at the below link (please check the afterRender method)
Here the fix was to clear the RenderTextures's Alpha channel with 1.0 so that it will not have artifact when you draw other nodes on RenderTexture.That clearing should be done once you are done drawing on the renderTexture. Please let me know if you need further clarification.
No comments:
Post a Comment