Little problem while calculating vertex normals (OpenGL ES)

Started by
10 comments, last by amadeux 13 years ago
I'm American, amadeux, and was probably speaking English well before you were born. Your original post consisted primarily of "Here's some images. I think something's happening with my normals around Z=0. What's wrong?" You don't mention what API you're using and, with so little else to go on, I asked questions to try to get more information, which you seem hesitant to provide, looking for something of a technical nature. You assume everyone will know what you're doing and how you're doing it when you say you're "calculating normals for adjacent triangles," "disabling the calcs for the adjacents" and "using a normal buffer," seemingly assuming people are psychic. You post some more pictures showing the same behavior as the previous images and.. finally post all of 7 lines of code extracted from some routine, saying only (after being asked several times): "The indexing is correct."

The likelihood of someone looking at some images and a few lines of code, and pinpointing the problem is slim-to-none. Without any further information, I can only make general suggestions.

1. [s]Ensure there are no duplicate vertices along the Z=0 line[/s]. Oops. Sorry. You said the indexing was correct.

2. Check the data is being loaded correctly.

3. Check that the math functions such as vec3Add, vec3Subtract, vec3Cross, etc., are correct and you're using them correctly.

4. Check the logic and code elsewhere (other than the 7 lines of code you posted).

5. Check that all your variables are initialized.

Please don't PM me with questions. Post them in the forums for everyone's benefit, and I can embarrass myself publicly.

You don't forget how to play when you grow old; you grow old when you forget how to play.

Advertisement

I'm American, amadeux, and was probably speaking English well before you were born. Your original post consisted primarily of "Here's some images. I think something's happening with my normals around Z=0. What's wrong?" You don't mention what API you're using and, with so little else to go on, I asked questions to try to get more information, which you seem hesitant to provide, looking for something of a technical nature. You assume everyone will know what you're doing and how you're doing it when you say you're "calculating normals for adjacent triangles," "disabling the calcs for the adjacents" and "using a normal buffer," seemingly assuming people are psychic. You post some more pictures showing the same behavior as the previous images and.. finally post all of 7 lines of code extracted from some routine, saying only (after being asked several times): "The indexing is correct."

The likelihood of someone looking at some images and a few lines of code, and pinpointing the problem is slim-to-none. Without any further information, I can only make general suggestions.

1. [s]Ensure there are no duplicate vertices along the Z=0 line[/s]. Oops. Sorry. You said the indexing was correct.

2. Check the data is being loaded correctly.

3. Check that the math functions such as vec3Add, vec3Subtract, vec3Cross, etc., are correct and you're using them correctly.

4. Check the logic and code elsewhere (other than the 7 lines of code you posted).

5. Check that all your variables are initialized.



OK, man... you exagerrated without knowing me. "speaking English well before you were born"... uahuaha... I'm sure not... how many years you think I have? 26 or 30?... no... more than it... unfortunately... but anyway... let's focus on the question here.

Maybe I should make another question, more directly. Has any problem related to Z = 0 on the normals calculation?
If Yes, great.
If not, great too.

Review my own code is something a little obvious, don't you think?
"Oh, yeh, just now, few days later, after asking a lot, posting images, register in many foruns... I'll try to review my own code!!!"
What do you think I'm doing all these days???

OK, so if there is no exception to Z = 0, great, I'll follow by myself.

About everything else you said... bullshit!!!!

Thanks again.

This topic is closed to new replies.

Advertisement