Fixed problem with glass materials and internal rays