As the temperature of the heat source increases the wavelength of the light( and heat ) gets shorter. As the sun is so hot the light easily passes through the glass. When it heats the black material up that starts to radiate but the wavelength is much higher than from the sun and it doesn't pass through the glass so well. A very good article is at
https://phys.libretexts.org/Bookshel...body_Radiation.