I see that a new projection policy was added to nDisplay that allows you to specify a mesh to warp rendered output in 4.25 instead of using a PFM or MPCDI. I assume this is the new AssignWarpMeshToViewport function but there is no documentation on how to use it or how it interacts with the nDisplay config file.
Entry in the 4.25 release notes:
“We’ve made it easier to set up nDisplay to render to curved surfaces. Instead of using PFM or MPCDI to configure how nDisplay needs to warp the final output in order to project it onto curved surfaces, we’ve implemented a new projection policy that warps the rendered output automatically according to a mesh that you specify in the nDisplay Blueprint API.”
I am also having trouble with this. My warp mesh is a single quad for now; obj file at the bottom of the post. Unreal Engine imports the mesh and it displays well. The config file [projection] is set to use the ‘warp’ type. I used the AssignWarpMeshToViewport blueprint function. But when the application starts, I get an out of bounds error; suggesting the engine is having trouble handing off the mesh data to nDisplay. The error is:
Assertion failed: At >= 0 && At < (uint32)IndexStorage.Num()
[File: ....\public\RawIndexBuffer.h] [Line: 177]
Here is the .OBJ file that contains a single quad
# an obj file
v 1.0 0.0 1.0
v 1.0 0.0 -1.0
v -1.0 0.0 1.0
v -1.0 0.0 -1.0
vt 1.0 0.8
vt 1.0 0.2
vt 0.0 1.0
vt 0.0 0.0
f 1/1 3/3 2/2
f 3/3 4/4 2/2