normal & tangent

I have a custom hlsl directx shader, it takes vertex normals for rim light calculation. and vertex tangent(it stores unified normals) for edge render(enlarge model & cull front).

I can export one fbx with auto smooth normals, and one fbx with unify normals, combine them in unity, it works but the process is slow. I just wonder if I can do it directly in 3ds max, so 3d artist can preview the result directly in their tools.

I tried storing unify normals data in texture coordinate or vertex color, but the data will be wrong once bone animation is running. So I believe normal + tangent is the only way to go if I want to have rim lighting & edge render together for a animated character model use in Unity3D.

I guess FBX SDK will help, but I have no experience in using it.

I wish someone could tell me a way to store vertex normals data into tangent. or tell me is it not possible so that I should consider another solution.

thanks you.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.