Fluorescence quenching of ultrathin anthracene films by dielectric and metallic substrates