Analysis of properties of ion implanted planar optical waveguides in Cr :KTiOPO4 and Er:KTiOPO4