What saved openGL ultimately was that directx only runs on microsoft devices. Mac/Unix/Linux/Android/PS3.... All use OpenGL.
All good... you know, part form the fact that Android uses OpenGL|ES (aka OpenGL's saner relation) and the PS3 doesn't use GL at all.
(An OGL|ES layer exists for the PS3 but no one in their right mind uses it...).
Directx only became king because microsoft partnered with game companies and funded hundreds of game titles in the late nineties. They flooded the markets with windows only games and this set the standard from that point onward.
OpenGL was still the renderer of choice in the late 90s and very early 2000s; I was still playing Counter Strike on the
(edit: correction to my earlier brain fart with regards to HL/Source engine confusion)