Polarons in crystalline and non-crystalline materials