Open bvanevery opened 8 years ago
D3D11VertexDeclaration.cpp logs those errors. I used TortoiseGit to pull up a log of changes to it. It doesn't look like any of that code has changed recently. A long time ago, back in March, there was an entry:
* Fix LitSolid & LitParticle shaders failing to create input layout (missing normals.) Log more detailed error when input layout creation fails.
In that commit was a change to LitSolid.hlsl that went from:
float3 iNormal : NORMAL,
to:
#ifndef BILLBOARD
float3 iNormal : NORMAL,
#endif
So, I'm betting this is the general nature of the error. A shader written for Urho3D requires various defined symbols for all the permutations possible according to user selection. The shaders provided by USP probably do not implement all of the needed permutations correctly. Probably nothing wrong on Urho3D's end, just USP's.
This would be a tough learning curve for a new user of Urho3D. I'll review whether these requirements are documented. It would also be good if Urho3D could detect whether various symbols are defined, for its rather specific shader requirements.
The following notation was added to the Urho3D docs yesterday: "Direct3D11 is strict about vertex attributes referenced by shaders. A model will not render (input layout fails to create) if the shader for example asks for UV coordinates and the model does not have them. For this particular case, see the NOUV define in LitSolid shader, which is defined in the NoTexture family of techniques to prevent the attempted reading of UV coords."
Cadaver wrote a bit about that issue in http://urho3d.prophpbb.com/topic1644.html
USP is junked with highly fragmented rendering errors. Doesn't matter if built against Urho3D 1.5 or the latest GitHub pull. The same 3 log errors are given:
I swear I had everything working with a Urho3D pull maybe 2 days ago. Need to figure out if this is Urho3D's bug or USP's.