If it was sperete view port or somehow render on top of UE4 window then i think that might be possible, C++ in UE4 is still normal C++ so you can technically do anything there but not everything will cooperate with engine APIs, also specific use of OpenGL will reduce portabbility capabilities, maybe not on PC and Mac but on consoles yes.
UE4 use rendering interface called RHI which you send rendering commands to it and RHI will translate it to library that it’s curretly using, DX, OpenGL, any library that consoles platfrom uses. Slate alone give you rendering options to, you can paint custom (sadly only 2D) vertieces data:
Or even inject RHI commands in to rendering system
I think those 2 above can help you out, i personally testing them out right now