Polaronic optical absorption in semiconducting and superconducting oxides