While the theory that explains all of this is quantum mechanics, the derivations you want are not trivial at all. The examples you gave are completely different types of materials with completely different approaches being used in solid state physics to describe them via QM. You should be able to find descriptions in every good book on solid state physics.
A few hints at a better understanding of the topic:
Glass is transparent in the visible part of the spectrum. However: UV light has a hard time passing glass. That's why one can't get a sunburn below glass. This means that glass is only transparent from our perspective. At the same time radio waves can easily penetrate walls that visible light cannot. So glass just happens to be transparent to us, while e.g. muscle tissue would be transparent to some hypothetical creature being sensible to x-rays. If you look at the complete spectrum, every material is transparent at some wavelengths and not at others. Using QM you can compute which material is transparent at which wavelengths.
EDIT: While QED may be more fundamental than QM, as well as somewhat more suitable b/c one has to work w/ many particle systems, the QM derivations are enough for qualitative descriptions as relativistic effects aren't of much interest here and in the non-relativistic limit QED gives QM w/ minimal substitution.