Line renderer not visible in camera views

Hi,

I have two cameras in a viewport, viewing the same portion of a scene. I am using renderLine() to create a line between two points. The line is visible in only one camera (the one with lowest priority). Is there a work around for this so that I can display it in both cameras.

Thank you.

This issue has been raised before indeed. Immediate Rendering features are just for debugging really.

For now there is no easy fix. You could make your own lines and render them, but that is a bit less “easy” :frowning:
I’ll create an issue for engine to be able to specify this.

1 Like

I’ve created github ticket for this: https://github.com/playcanvas/engine/issues/720

1 Like

Thanks max. Will implement the less easy method now.:wink:

I get a similar problem in VR work but it looks even worse because it’s only rendered in one eye!
I switched to using a elongated box.

Basically I calculate the mid point position of the box based on the required line length and change it’s orientation to be in the direction I want the line to run and then change it’s scale to the required length.