A baby allegedly murdered by a high school teacher who adopted him had suffered sexual abuse injuries, a court has heard.