Fixed pointer function

Fixed atPels(x,y) function