I have hundreds of unique HLSL (USF) code files that utilise HLSL parameters such as VertexId, most of which are not available within the material editor. I also have equally hundreds of static meshes that use these unique USF shader files. I have attempted to use the custom expression node, but I’ve found this quite limiting and not fit for my purpose.
I need to avoid modifying the engine directly, so I’ve looked into things like custom VertexFactory and SceneViewExtensionBase. I think the SceneViewExtension ->PostRenderBasePass_RenderThread approach is most likely to work here for taking the static mesh data, rendering it, and applying the VS and PS shaders with the given parameters.
My main question regarding this is it feels like the simplest approach would be to make a child of StaticMeshComponent, and recognise that child component inheritance within the render pass and instead of using the material override it with my custom shaders. Is anything like this possible without modifying the engine?
Does anyone here have any more info or ideas about how this could best be approached?
Many thanks