3
\$\begingroup\$

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!

\$\endgroup\$
1
  • 4
    \$\begingroup\$ I believe this artifact is called "ghosting" but I'm not experienced in iOS development so I don't think I could help you. Is there a difference in refresh rate on the iPad? \$\endgroup\$
    – Ray Dey
    Commented Feb 8, 2011 at 19:40

2 Answers 2

1
\$\begingroup\$

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)

http://code.google.com/p/cocos2d-iphone/issues/detail?id=631&q=glClear%28GL_COLOR_BUFFER_BIT&colspec=ID%20Type%20Status%20Priority%20Milestone%20Component%20Owner%20Summary

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.

\$\endgroup\$
1
  • \$\begingroup\$ Interesting... I'll try this. The Texture2D class I'm using is the old one from Apple sample code... and the Cocos2D Texture2D is based on this same code. \$\endgroup\$
    – MrDatabase
    Commented Feb 14, 2011 at 16:22
1
\$\begingroup\$

Judging from a quick google search at least some (possibly defective, or at least less-than-perfect) iPads suffer from ghosting. Is this what you're seeing?

The youtube link above says the person has replaced his ipad with a functional one, and the other link suggests if you see clear ghosting, you should return your ipad.

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .