Api to render immediate mode shapes to help with coding and debugging

It would be very usefull to be able to render lines, cubes , spheres gizmos and kind of debug helpers.
Most of these things are just being used by the editor but are not exposed in lua.
also the way edito outline selected entities could be quite useful if exposed.