A film about Tupac Shakur has divided audiences in America

Getty Images Demetrius Shipp Jr, who plays Tupac in the filmGetty Images
Demetrius Shipp Jr plays Tupac Shakur in All Eyez On Me

A new Tupac Shakur biopic has divided audiences and critics in the US.

Although All Eyez On Me performed higher than expected at the US box office, some people connected to Tupac during his life have criticised it.

Jada Pinkett Smith, who was a childhood friend of the rapper, tweeted that the film's portrayal of her relationship with him is "deeply hurtful".

Tupac was killed in 1996, aged 25, and the film was released on what would have been his 46th birthday.

It has a 24% critics rating on review aggregator Rotten Tomatoes.

Warning: third-party content may contain ads

Vulture said the biopic was "rarely more than a faithful adaptation of the rapper's Wikipedia entry", while Rolling Stone called it a "major letdown."

Jada Pinkett Smith, who is played in the film by Kat Graham, suggests that the depiction of her friendship with Tupac is inaccurate.

There are three main incidents in the film which Pinkett Smith criticises.

But the actress and producer praises the performances of Demetrius Shipp Jr, who plays Tupac, and Kat Graham.

Getty Images Jada Pinkett SmithGetty Images
Jada Pinkett Smith was childhood friends with Tupac

All Eyez On Me producer LT Hutton told TMZ he was "disappointed and hurt by the accusations" from Jada Pinkett Smith.

He defended the film, saying it "all came from the truth".

Rapper 50 Cent also criticised the film, calling it "trash" on social media.

Instagram/50 Cent 50 Cent's Instagram post.Instagram/50 Cent

But the film beat box office expectations in the US, making an estimated $27m (£21m) on its opening weekend - showing that the audience seems to be enjoying it.

And its audience score on Rotten Tomatoes is a respectable 70%.

Rapper Diddy and music producer Suge Knight, who are depicted in the film as well, both reportedly gave it the thumbs up.

Getty Images Sean Diddy Combs in 1999, when he was known as Puff DaddyGetty Images
Sean Diddy Combs in 1999, when he was known as Puff Daddy

John Singleton, who directed Shakur in the 1993 film Poetic Justice, was originally attached to All Eyez On Me but quit in 2015.

At the time, he said it was because "the people involved aren't really respectful of the legacy of Tupac Amaru Shakur."

Last year, he told magazine HipHopDX: "I haven't watched it and I refuse to watch it ... I'm not even trying to give it any attention."

He was eventually replaced at the helm by Benny Boom.

It was the last album released by Tupac before he was murdered in a drive-by shooting.

It was certified Diamond in the US, making it one of the best-selling albums of all time.

The film All Eyez On Me is released in the UK on 30 June.

Find us on Instagram at BBCNewsbeat and follow us on Snapchat, search for bbc_newsbeat