A San Marcos man was sentenced to 80 years in prison on nearly 30 counts of child pornography, the Hays County District Attorney's Office said Wednesday.