I considered using Apple’s GLPaint example (http://developer.apple.com/library/ios/#samplecode/GLPaint) to do some finger painting.
However, I noticed that the playback of the recorded data in the sample is VERY slow. I stepped through the code and couldn’t find any artificial delays (there’s a 0.01 second delay before drawing each line segment, but this doesn’t explain why the whole playback is so slow, and performance doesn’t change if this delay is removed).
I need to be able to record the data in my app and show it when the user asks, but the data should be displayed immediately rather than being animated.
I can’t just save the final image because I need the actual points.
Is drawing in OpenGL ES really that slow, or am I missing something?
The drawing mechanism is set up to call
-presentRenderbuffer:after connecting every touch point. If you want to draw everything at once, remove the 0.01s delay, loop through all the geometry and draw it at the same time, and move the set up/present of the renderbuffer out of the loop so you only do it once.