How to draw a line between two points in LibGDX, in 3D
<p>I'm trying to learn the 3D side of LibGDX, and I've came to a problem. I want to draw a line from <code>0, 0, -5</code> to <code>0, 0, 5</code>. I've tried a few things to make this work.<br>
First I looked to see if I could create a line as a <code>Model</code>. As far as I can see, I can't do this.<br>
What I then realised is that theoretically I can draw a line using a <code>ShapeRenderer</code>. Here's my code to try to do this.</p>

<pre><code>public class Main implements ApplicationListener {
    ...
    public ShapeRenderer srend;
    ...
    @Override
    public void create() {
        ...
        srend = new ShapeRenderer();
        srend.setColor(Color.RED);
        ...
    }

    @Override
    public void render() {
        ...
        srend.begin(ShapeType.Line);
        srend.line(0, 0, -5, 0, 0, 5);
        srend.end();
        ...
    }
    ...
}
</code></pre>

<p>But for some reason this doesn't appear to work. I use ShapeRenderers a lot, but it's possible that I'm making a mistake initializing or using it, I don't think that's the problem though.<br>
I've only just started using the 3D part of LibGDX, so I assume the problem is around where I'm drawing the actual line.</p>