Image copyright Getty Images Image caption Princes Harry and William with John Boyega and other members of The Last Jedi cast and crew

Princes William and Harry have cameo roles as stormtroopers in the next Star Wars film, actor John Boyega has said.

The royals visited the set of The Last Jedi in April 2016 and were rumoured to have filmed a scene in disguise.

Now Boyega, who plays reformed stormtrooper Finn, has confirmed that he shared a scene with the pair "wrapped in stormtroopers costumes".

The actor also appeared to confirm that actor Tom Hardy appears beside them, also beneath a face-obscuring helmet.

Boyega's confirmation came during a taping of a "round table" interview for the Hollywood Reporter. The film website has reported his quotes but has yet to make the audio available.

Image copyright Getty Images Image caption The Duke of Cambridge got a hug from Chewbacca while visiting Pinewood Studios

It quoted the British actor as saying it was "a great experience" to shoot the scene with the princes, and that it made for a "strange contrast of a weird family".

In April, Boyega said "no comment" when asked whether William and Harry would be making cameo appearances. The royals were on the film set in 2016 as part of an official visit to Pinewood Studios.

Take That singer Gary Barlow has also revealed that he has a part in Star Wars: The Last Jedi, which is out in cinemas in December.

The BBC has tried to contact Prince William and Harry's communications secretary and a spokesperson for Disney, owner of the Star Wars brand.

Follow us on Facebook, on Twitter @BBCNewsEnts, or on Instagram at bbcnewsents. If you have a story suggestion email entertainment.news@bbc.co.uk.