Although they appear to be the place where you have the least amount of control, students actually have much more control over the quality of the recommendations than they think they do. You give the recommenders the information from which to write the recommendations. You start choosing recommenders in your first year of college by taking your coursework seriously, doing quality work, getting good grades, speaking up in class, and building relationships with professors outside the classroom. Professors have office hours. Professors give talks on and near campus.
Professors write books and articles.
Even if law school feels years away, speak to the professor at the end of the course and ask him or her if it's okay for you to come back at application time and get a letter. Yes, professors are your best recommenders. The best students may go so far as to pick and choose recommenders according to the skills required in the professors' classes or according to the professors' disciplines. For example, a student might pair a professor from a large general education course which involved lots of reading across disciplines and a series of essay exams with a professor of an intimate senior seminar focused on a single theme and which required a term-length research project, term paper, and oral presentation. Students who haven't done so well will have a harder time.