Oh I should also mention all textures I use are made seamless.
Terrain lighting seams?
If your terrain is flat, there shouldn't be any seams even if you aren't using neighbour patches. Are you sure you're calculating your normals correctly? (i have no experience with the sobel operator). Try visualizing the normals with the pixel or geometry shader.
Also, i think you're overcomplicating your calculations. The way i do it is to simply store the neighbour vertices with the patches. So if my chunk is 65x65, i store a border around it so that it's 67x67 and use the extra vertices to calculate the normals. This way you won't have to consider each case (top, left, etc..) explicitly. Here's how the final code turns out:
for (int y = 1; y <= mChunkSamples; y++)
{
for (int x = 1; x <= mChunkSamples; x++)
{
float sx = pHeights[(x + 1) + mHeightSamples*y] - pHeights[(x - 1) + mHeightSamples*y];
float sy = pHeights[x + mHeightSamples*(y+1)] - pHeights[x + mHeightSamples*(y-1)];
nor.x = -sx * mVerticalScale;
nor.y = 2 * pChunk->mScale;
nor.z = -sy * mVerticalScale;
D3DXVec3Normalize(&nor, &nor);
// ... store
}
Edit: I just realized that you are hardcoding your normal to (0, 1, 0). This only leaves the texture... Did you try rendering with lighting only?
Well I ran into some problems implementing the border vertices for sampling normals actually became quite complex. So I reverted it and now I'm back to where I was before. I'll have to tackle this bug again. I have to move onto some important features and mechanics.