can my scene be smoother than this?

i have generated a terrain using some elevation data. it looks OK when the viewpoint is far, when i zoom in, it looks a little jaggered. can i do any better than this? i have normals being generated at each vertex of the triangle in the terrain. i have a 1D texture that acts as a colorscale.
when 1D textures are used, are the colors applied per plane or per vertex?
thanx in advance

[This message has been edited by mithun_daa (edited 02-06-2004).]

Are you avaraging normals at each vertex? If you have 3 triangles connecting at vartex avarage their face normals.

If you don’t do this already, try “trilinear” filtering for your 1D texture (ie GL_LINEAR_MIPMAP_LINEAR, use glu to generate the mipmaps).

I think Madman has it, you seem to specify normals for ‘flat rendering’.
For each distinct vertex, you will have to average the normals of the 6 triangles that are adjacent. Do not forget to glEnable(GL_NORMALIZE).

Originally posted by ZbuffeR:
I think Madman has it, you seem to specify normals for ‘flat rendering’.
For each distinct vertex, you will have to average the normals of the 6 triangles that are adjacent. Do not forget to glEnable(GL_NORMALIZE).

is it 6 triangles or 3. what would give me the best result. i guess 6
now herez an image, can anyone giv me n eg. sequence of triangles. this maybe too rudimentary, but im gettin confused

[This message has been edited by mithun_daa (edited 02-09-2004).]

[This message has been edited by mithun_daa (edited 02-09-2004).]

Originally posted by mithun_daa:
[b]
is it 6 triangles or 3. what would give me the best result. i guess 6
now herez an image, can anyone giv me n eg. sequence of triangles. this maybe too rudimentary, but im gettin confused
will it be the avg. of all the 7?

[This message has been edited by mithun_daa (edited 02-09-2004).]

[This message has been edited by mithun_daa (edited 02-09-2004).][/b]

The actual number of triangles to take in account will depends if you have a corner/edge vertex or a ‘standard’ one of course.

In you example, for the vertex located right in the middle, you will need to average the normals of triangles 1,2,3,4,5,7. (quite a strange numbering, btw )

For the vertex at the up-right corner, use 6.
For the one just below, use 1,6,5.
And below again, use 5,4.

So, for each unique vertex, just take in account all the directly adjacent triangles.

Is it clearer ?

[This message has been edited by ZbuffeR (edited 02-09-2004).]