Despite the theoretically infinite number of possible trajectories a human may take to reach a distant doorway, we observed that locomotor trajectories corresponding to this task were actually stereotyped, both at the geometric and the kinematic levels. In this paper, we propose a computational model for the formation of human locomotor trajectories. Our model is adapted from smoothness maximization models that have been studied in the context of hand trajectory generation. The trajectories predicted by our model are very similar to the experimentally recorded ones. We discuss the theoretical implications of this result in the context of movement planning and control in humans. In particular, this result supports the hypothesis that common principles, such as smoothness maximization, may govern the generation of very different types of movements (in this case, hand movements and whole-body movements).