What does HackerNews think of bgfx?
Cross-platform, graphics API agnostic, "Bring Your Own Engine/Framework" style rendering library.
Ie, you might prefer bgfx[0], cinder[1] or openframeworks[2].
Gitlab, Bitbucket.
I don't really know what to expect. You want to see good production code, and the FOSS community is way way WAY better at this than some of the bubble gum you'd see in a professional setting.
Your question is too general, so I can't exactly give you a specific repository. I could direct you to BGFX[1] for a decent architecture of a cross platform renderer, but if you're not a graphics programmer, that may be a bad exercise, as you'd spend more time learning jargon than studying clean code. Or it uses patterns (or lack of, given graphics programming) that don't apply to your domain.
And all the graphics stacks nowadays are similar, Vulkan, Metal, DX12, all share the same ideas
Also there are countless opensource cross platform GPU libs, bgfx [1] or sokol [2] for example
Though I have my complaints about it, I think bgfx gives a good powerful-but-not-too-complicated abstraction over graphics programming; for some design info, see: https://bkaradzic.github.io/bgfx/internals.html
PS: also don't forget BGFX (https://github.com/bkaradzic/bgfx) which sits somewhere in the middle between sokol-gfx/WebGPU and Magnum when it comes to API abstraction and feature set.
For example, one pretty nice cross-platform GPU-enabled stack :
https://github.com/bkaradzic/bgfx
[1]https://github.com/bkaradzic/bgfx [2]https://github.com/DiligentGraphics/DiligentEngine
Big open source projects still seem to roll their own solution for this, which I imagine is both for historical reasons but also because there might be a fear that using a library like this could leave your hands tied when you need to do some API-specific workaround.
It exposes a common API to 3d GPU resources and implements it in terms of native backends.
I've not tried Linux for a long time, so it's possible there are some issues. But it's definitely compilable and it used to run few months ago.
MacOS port should be easy, there once was a branch with a lot of stuff already ported, but it was done by other programmer and he did not finish it.
And if you don't have resources to ask/communicate than just use something like https://github.com/bkaradzic/bgfx/ which is an awesome API agnostic rendering library.
If you want to produce compelling VR experiences then I'd recommend you download Unity. You should be able to start making real, valid prototypes for different types of VR interactions in under a week.
If you want to graphics then I might recommend you poke at http://humus.name/index.php?page=3D or https://github.com/bkaradzic/bgfx. But graphics isn't my specialty so my thoughts aren't the strongest.
If you want to learn C++ then... that's an interesting question I've not thought of before. Maybe I'd start with "Learn C the Hard Way"? http://c.learncodethehardway.org/book/ I'm not as much of a C fanboy/C++ hater as other game devs. I quite like C++11 lambdas and move semantics. But I hate boost and it's ilk. So starting with C and later adding a dash of C++ seems like a good way to start.
While not a 2D library, https://github.com/bkaradzic/bgfx is a very sweet abstraction layer over platform graphics APIs