Camera Facing Materials

Hey guys,

I’ve been having some problems lately working with trying to get materials to face the camera, I have been using the system that is used in the maths example in the content example project but with strange effects, the main problem being that the texture is rendered upside down, and far above the bottom of the plain that is applied to even with adjusting the height parameter the texture is then rendered the correct way up but far below the plain.

Any help with this would be really appreciated, and if you need any more info just let me know

Thanks guys!


It could depend on the UVs of the mesh you are using. If you are in doubt you can always find one of the meshes in engine called “1_unit_plane” and use that.

With the Y coordinate set up like that - assuming good 0-1 UVs - the ‘sprite’ should have its pivot on the bottom or top. if you want it to have its pivot in the middle (like the x-axis) then simply use the same constant bias scale to bring the Y axis into the -1 to 1 range.