Add built-in renderdoc support
This should make debugging graphical issues with renderdoc a bit more easy, especially on the native backend. It should probably be expanded beyond a single one-shot function that can only be used via lg.
Renderdoc currently also is limited in usefulness because glEGLImageTargetTexture2D
is not supported and that means importing dmabuf and EGLImages does not work.