openGL shader: two object and one line to connect them
===

I'm using shaders and the programmable pipeline, I need to connect two meshes with a line (maybe colored) but I just have the model matrices of these two objects. The line should start at the center of these objects so I assume the object-coords of the two points should be:

    start point: 0,0,0
    end point: 0,0,0

to connect the two objects I assume I'll have to multiply these points in the shader by their respective object's model matrix. And then multiply everything by the view matrix (this is common to the two objects). And eventually by the projection matrix.

I've always used shaders with vertex arrays, how would I pass two different vertices to a shader? Should I use uniforms for them too? And what function should I use to draw the line since both glDrawElements and glDrawArrays require a data array?