Perhaps not, as a graphics programmer, rewriting the rendering system is comparatively simple, enjoyable, and perhaps not worth 5% of a moderately successful game.
However, UE4 is much more than just a graphics library. I'd argue that it's editor alone is worth many times more than their rendering features. And IMO, it's trivially worth the 5% of revenue.
Writing a rendering system or this rendering system? I think you're underestimating the tech here. Could you match their real time global illumination, radiosity, physically based rendering, etc with good performance? I get the impression you'd need to go over like 100 different papers to even get a baseline implementation, without any clever optimizations, for a modern engine like UE4.
Yeah, any reasonably skilled programmer can write a pretty graphics engine as a hobby project, since that is the fun part of making an engine. It's all of the other boring stuff that is worth (arguably) more than 5%. Writing the resource management system and the editors takes a long time and a lot more effort and is not as fun or glamorous as writing a rendering engine.