0
\$\begingroup\$

I have a giant terrain. I have grass/stone/mud/and so on...

enter image description here

As for the test I am using raw color assigned to each vertex to render triangles of terrain. When I have a terrain like that I set upper 4 vertices to red to represent, let's say "dirt" then lower dot to blue to represent "stone". Then I get this...

enter image description here what I want to get is this enter image description here

to represent upper "dirt"(red) area and lower blue "stone" area. and the upper square and lower square to blend a little in the middle like this game

enter image description here

I am stuck

\$\endgroup\$

1 Answer 1

0
\$\begingroup\$

You must either increase your grid resolution by a factor of 2, since the shared vertex color will be interpolated across the triangle/quad, or break the efficiency of triangle fan, and express duplicate vertices for each shared boundary each with its own color attribute.

\$\endgroup\$

You must log in to answer this question.

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