"Straight Outta Compton", the story of rap collective N.W.A, from Compton, California, opened on Thursday as protests take place in Ferguson, Missouri, to mark the anniversary of the fatal shooting of black teenager Michael Brown by a white police officer.

It follows N.W.A, which included rappers Dr Dre and the late Eazy-E, as they rose to fame in the late 1980s with lyrics drawing from the violence, crime and anti-police sentiments that the rappers themselves had experienced growing up in Compton.

Brown's death was one in a series of police killings of unarmed black men and women across the U.S. that has renewed the debate on race and justice.

Against that backdrop, and with security at movie theaters in focus after a gunman killed two women in a Louisiana screening of "Trainwreck" in July, private security and police presence was increased at a number of venues.

"(In this movie) police don't come out in a good light and there is a feeling in the country that is anti-police and anti-establishment, and crowds are affected by movies," Tom DeLuca, president of National Cinema Security, the largest provider of security to U.S. movie theaters, told Reuters.

At a screening in South Gate, a neighboring city of Compton, an employee checking attendees' bags on entry said the theater hired extra security for the film's opening. One guard was stationed outside of the film's screening room.

N.W.A. founding member Ice Cube, one of the film's producers, praised the efforts of the studio and theaters.

"I am glad that Universal stepped up and it's all about making people feel safe," the rapper told Reuters.

Comcast Corp-owned Universal Pictures said it would work with theater owners on any security issues.

"The studio has not solicited enhanced security for theaters who will begin showing it this weekend, but have partnered with those exhibitors who've requested support for their location," Universal said in a statement.

Compton native Eddie Cruz told Reuters at a screening in nearby Downey he hoped the film shed a light on his community.

"The majority of the United States don't really understand what's going on in these cities like Compton or Oakland," he said. "They need to understand what's happening and I think having it shown in movies really helps that progress forward."

Attendees at the first screenings on Thursday in locations neighboring Compton said they were not concerned about possible violence.

"I'm here with my kids. I feel secure," said Leo Olea at the Downey screening. "It's just a movie after all."

Fellow movie-goer Vince Montano added: "I'm pretty sure people are smarter than that now so I don't think there'd be any violence."

The film is projected to top the U.S. box office this weekend with upwards of $40 million, said Rentrak senior analyst Paul Dergarabedian.

"People who are excited to see any movie this weekend are not going to be deterred by any thought of violence at theaters," he said.