Original Post
I was playing around with bump maps today, trying to get a result without the TBN basis, and got the following. The first image is a low res mesh and the second a higher res mesh.


The edges are quite prominent though, but I think it would look fine in a scene with dynamic tessellation. Any ideas on how I could smooth out those edges?


The edges are quite prominent though, but I think it would look fine in a scene with dynamic tessellation. Any ideas on how I could smooth out those edges?
float4 PS(VS_OUT pIn) : SV_Target
{
float duv = 1.0f * ( 1.0f / 512.0f );
float f = 0.09f;
float g = 0.05f;
float3 n = pIn.normalW;
float thisbump = gSpecMap.Sample( gTriLinearSam, pIn.texC ).x;
float rightbump = gSpecMap.Sample( gTriLinearSam, pIn.texC + float2( duv, 0 ) ).x;
float upbump = gSpecMap.Sample( gTriLinearSam, pIn.texC + float2( 0, duv ) ).x;
float3 tangent = normalize( ddx( pIn.posW ) );
float3 bitangent = normalize( ddy( pIn.posW ) );
float3 thisPos = pIn.posW + n * thisbump * f;
float3 rightPos = ( pIn.posW + g*tangent ) + ( n * rightbump * f );
float3 upPos = ( pIn.posW + g*bitangent ) + ( n * upbump * f );
float3 pnormal = normalize( cross( rightPos - thisPos, upPos - thisPos ) );
float3 LightDir = normalize( float3( 1, 1, 0 ) );
return dot( LightDir, pnormal );
}