Impurities Effects on the Electronic Structure of Titanium Dioxide