As a boy, Alexander Skarsgard thought Tarzan was the ultimate superhero. Sure, the king of the jungle couldn’t shoot spiderwebs from his wrists or laser beams from his eyes. But he didn’t need special mutations or gadgets. He was willing to take on any beast or man, equipped only with his biceps.

Alex and his father, the actor Stellan Skarsgard, would spend hours watching old black-and-white Tarzan movies together when he was little. They were meaningful to Stellan, who’d grown up watching the films starring Johnny Weissmuller at Saturday matinees in Sweden. So when, just shy of 40 years old, Alex was offered the chance to play the character in a big-budget adaptation, he knew he had to do it. He had to make his dad proud.

But his father’s reaction to the news was, uh, a tad surprising/not entirely supportive.

“I laughed,” recalled Stellan, 65, calling from his native country. “And he laughed too. It was not meaningful at all. It was extremely comic. I can’t explain my kid being Johnny Weissmuller. But I’m sure it’s great. He’s a much better actor than Johnny Weissmuller.”

The fact that the younger Skarsgard has yet to convince his own dad that he’s the right guy to play the iconic character gives you a sense of the kind of expectations he has been up against at the box office. “The Legend of Tarzan,” which hit theaters last week, marks director David Yates’ attempt to modernize Edgar Rice Burroughs’ jungle hero. Before his death in 1950, Burroughs wrote more than two dozen Tarzan stories, which were then adapted for the big screen numerous times - the most memorable being 1932’s “Tarzan the Ape Man” and 1984’s “Greystoke: The Legend of Tarzan, Lord of the Apes.”

For the 39-year-old Skarsgard, who’s best known for his work on HBO’s “True Blood” and in independent films such as Lars Von Trier’s “Melancholia,” “Tarzan” serves as a test of his strength as a leading man. For years, Hollywood has struggled to find a young male action hero as popular as Arnold Schwarzenegger or Bruce Willis. Colin Farrell tried and failed. So did Jake Gyllenhaal. Same with Taylor Kitsch.

According to the director, the studio “would have been very happy with a complete unknown,” given Tarzan’s name recognition. “But I always really fancied Alex for the role very early on in the process,” said Yates. “I wanted to find someone who had a real grace and presence and sense of otherness. He’s a very vertical actor with great length and shape. I wanted to get away from that he-man, squared look with the big, strapping leading man.”

After finding out he landed the role, Skarsgard knew he had to get in shape. The 6-foot-4 actor cut out gluten, sugar, dairy and alcohol. For three months, he ate 6,000 calories a day and lifted weights. Once he’d gained enough body mass, he moved to a stricter diet to keep the muscle but get rid of the fat. Ultimately, he put on 25 pounds of muscle.

In “The Legend of Tarzan,” we find the character eight years removed from the jungle, living in an austere British castle as Lord Greystoke. He’s abandoned vine-swinging for tea-sipping until he’s called to return to the Congo as a trade emissary. He and Jane, played by Margot Robbie, return to Africa only to find its people and wildlife ravaged by colonialism and pressed into slavery by the sinister Leon Rom, played by Christoph Waltz.

Though he was unable to visit the African jungle before filming got underway, Skarsgard did spend time with some wild animals — lions in California, gorillas in England — to observe their movement. He binged David Attenborough nature documentaries. He started working with a choreographer to figure out how a character raised by gorillas would walk. And he thought a lot about human nature — the animalistic urges we all fight to keep at bay in the modern world.

“We are civilized human beings, but we’re all animals deep down, and that creates a certain friction in all of us,” he said. “When you’re in the public eye, we all feel like we’re constantly observed, so we don’t let things out. Anger, sadness, happiness - when does that come out? Maybe when you’re in traffic, because you’re in the safety of your little metallic bubble.”