Pregunta

I've updated my perfectly working app (build in Xcode 4.x when iOS 6 was the latest), this time building it with Xcode 5.0.2 and for the first time I've got this terrible 'after submission effect':

  • when testing on real device everything looks fine

  • after submitting to App Store I download the app to the same device and randomly get 3 different behaviours of glLightfv (yep, I'm using OpenGL ES 1):

1) all ok;

2) everything is overexposed;

3) everything is dimmed.

I can put the lighting code here (my suspicion is that the problem is with the lightning), but see no fault in the code since it works well until it hits the App Store. What is the real reason of this irrational situation?

¿Fue útil?

Solución

Yeah, my bad: I didn't give the fourth argument to the light position:

GLfloat light0Position[] = {first, second, third, fourth};
glLightfv(GL_LIGHT0, GL_POSITION, light0Position);

So probably previous compilers have always put zero for missing argument (so it worked), but the latest compiler gives 'random' numbers and random effect.

This issue was only visible after submitting to App Store, because I didn't test it in Release mode (thanks @medvedNick).

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top