I saw this VertexFactory.usf is included by “BasePassVertexCommon.usf”, but can’t actually find this file anywhere. I read from document that the VertexFactory.usf contains some input variables.The reason why I wanted to find this file is that I need to access the object position and world matrix from shader file, is there any way to do this? Thanks in advance!
I think it doesn’t exist. On the C++ side of the code, while gathering the include files, this file is particularly marked to be ignored.
ShaderCore.cpp -->GetShaderIncludes
…
…
// Ignore uniform buffer and vertex factory includes
bool bIgnoreInclude = ExtractedIncludeFilename == TEXT(“VertexFactory.usf”)
|| ExtractedIncludeFilename == TEXT(“GeneratedUniformBuffers.usf”)
|| ExtractedIncludeFilename.StartsWith(TEXT(“UniformBuffers/”));
Primitive.LocalToWorld
, seems to have what you’re looking for.