Hello!
I was using meshes exported with 3Ds max and created shaders for diffuse and normalmap textures. Worked fine!
Then I exported some meshes with Blender since its free and I noticed that I had to flip the Y-coordinate of the texture in the shader for it to work.
Also when I load the normalmap it seems pretty f***ed up. Got to have something to do with the exporter for blender. What can I possible try?
Btw: I have made sure that the normalmap texture is correct and that the code worked for 3ds max models.
Printscreen:

Structure
struct SSceneVertexToPixel
{
float4 Position : POSITION;
float4 RealDistance : TEXCOORD1;
float2 TexCoords : TEXCOORD2;
float3 Light : TEXCOORD3;
float4 ShadowMapSamplingPos : TEXCOORD4;
float2 ProjectedTexCoords : TEXCOORD5;
};
struct SScenePixelToFrame
{
float4 Color : COLOR0;
};
Texture Sample
texture BumpMap01 : TEXTURE1;
sampler BumpMapSampler01 = sampler_state { texture = <BumpMap01> ; magfilter = LINEAR; minfilter = LINEAR; mipfilter=LINEAR; AddressU = clamp; AddressV = clamp;};
Vertexshader:
SSceneVertexToPixel Scene_BumpVS( float4 inPos : POSITION, float2 inTexCoords : TEXCOORD0, float3 inNormal: NORMAL0, float3 inTangent : TANGENT)
{
SSceneVertexToPixel Output = (SSceneVertexToPixel)0;
float3x3 worldToTangentSpace;
worldToTangentSpace[0] = mul(inTangent,mWorld);
worldToTangentSpace[1] = mul(cross(inTangent,inNormal),mWorld);
worldToTangentSpace[2] = mul(inNormal,mWorld);
Output.Light = normalize(mul(worldToTangentSpace,vLightDir));
Output.Position = mul(inPos, mWorldViewProjection);
Output.TexCoords = inTexCoords;
Output.TexCoords.y = 1.0 - inTexCoords.y;
return Output;
}
PixelShader
// Get the colors of the texture, normal and diffuse
float4 texCol = tex2D(ColoredTextureSampler, PSIn.TexCoords);
float3 vNormal = (2 * (tex2D(BumpMapSampler01, PSIn.TexCoords))) - 1.0;
float Diffuse = saturate(dot(PSIn.Light,vNormal)) + fAmbient + (vMaterial - 1.0f);
// Mix the colors
Output.Color = Diffuse * texCol;
Output.Color.rgb *= vLightColor;
Output.Color += ( vMaterial - 1.0f );
Output.Color = saturate(dot(PSIn.Light,vNormal));
return Output;