The officer and the student both fired a single shot at that point, and it wasn't immediately clear whether he took his own life or was killed by the officer's bullet, St. Mary's County Sheriff Tim Cameron said. The other students — a 16-year-old girl and a 14-year-old boy — were hospitalized, the girl with life-threatening injuries. The officer was unharmed.
"When the shooting took place, our school resource officer, who was stationed inside the school, was alerted to the event and the shots being fired. He pursued the shooter and engaged the shooter, during which that engagement he fired a round at the shooter," Cameron said.
"Simultaneously the shooter fired a round as well. So, in the hours to come, in the days to come, through a detailed investigation, we will be able to determine if our SRO's round struck the shooter."
The shooter's motive also is being investigated, the sheriff said.
"I'm alerted to a number of things that are out there on social media about the potential relationship between the shooter and any of the victims. At this time, we can't confirm any of that," Cameron said.
Agents with the FBI and the Bureau of Alcohol, Tobacco, Firearms and Explosives joined deputies at the scene.
This shooting at Great Mills High School comes as lawmakers nationwide face pressure to take action against gun violence following the Valentine's Day killings of 17 people at a Florida high school by a teenager with an assault weapon.
Democratic Rep. Steny Hoyer praised the first responders, saying the officer at the school "answered the call this morning with swiftness, professionalism, and courage." He said it's now for Congress to take action.
"We sympathize. We empathize. We have moments of silence. But we don't have action," Hoyer said. "Wringing our hands is not enough."
Sen. Ben Cardin, D-Md., also spoke to reporters near the high school, and expressing anger and saying that at a minimum, universal background checks and a ban on assault-style weapons are needed. He said he believes momentum is building for reform, fueled by student activism.
"These students are literally just not taking 'no' for an answer," Cardin said. "I can tell you that Americans are listening to our students. I think our political system will respond."
Maryland's Senate joined the House on Monday night to ban bump stocks, which enable a semi-automatic rifle to mimic a fully automatic weapon. Teachers union leaders issued statements Tuesday saying more policies must be changed nationwide to keep schools safe.
Great Mills High School has about 1,600 students and is near the Patuxent River Naval Air Station, about 65 miles (104 kilometers) southeast of Washington. On Tuesday, ambulances, fire trucks and other emergency vehicles crowded the parking lot and the street outside, where about 20 school buses lined up in the rain to take students to nearby Leonardtown High School to be picked up by their parent or guardians.
Many students across the country are calling for effective gun controls, leading up to Saturday's March For Our Lives rally in the nation's capital against gun violence in schools. The violence hasn't abated since the massacre in Parkland, Florida; A high school student in Birmingham, Alabama, was killed this month when a classmate fired a gun inside a classroom. Threats against schools have proliferated as well, and Great Mills High has not been immune.
Just last month, the school's principal, Jake Heibel, told parents in a letter posted on the local news site The Bay Net that two students were interviewed after they were overheard mentioning a school shooting, and they were found to pose no threat. Heibel said the school increased its security nevertheless after social media posts about a possible school shooting "circulated quite extensively."
Also last month, St. Mary's County Sheriff's office said it arrested two teenage boys for "Threats of Mass Violence" and a 39-year-old man on related charges after the teens made threats about a potential school shooting at Leonardtown High School, a high school about 10 miles from Great Mills. Police said they obtained a search warrant that led to them finding semi-automatic rifles, handguns and other weapons, along with ammunition.
"This is what we prepare for and this is what we pray we will never have to do," the sheriff said. "The notion that it can't happen here is no longer a notion."
Associated Press contributors include Alex Brandon, Brian Witte, Matthew Daley, Alan Suderman, Sarah Rankin, David McFadden and Courtney Columbus.