Fixed pos(x,y) generation.