Added clampling and alignement.