It takes some chutzpah to use $15 million of your own loose change to bankroll your first major feature as a director. But Madonna has never lacked faith in her own talent, and “W.E.” represents her latest leap of self-belief.

The film is a time-shifting romance about an unhappily married modern woman who becomes obsessed with the love affair of King Edward VIII and Wallis Simpson.

Madonna researched the Edward and Mrs. Simpson story exhaustively, crafting the screenplay with Alek Keshishian, who directed her doc “Madonna: Truth or Dare.”

She financed her low-budget directing debut “Filth and Wisdom” in 2008 to experiment technically with how to make a film. Its modest reception didn’t discourage her from pursuing her passion project.

When it came to setting up “W.E.,” she employed a movable feast of top British producers, and drove them hard to meet her exacting standards. Some lasted the course longer than others.

They included David Parfitt, who was involved in early budgeting but left to make his own “My Week With Marilyn”; Colin Vaines, instrumental in putting together the cast and crew, but who also moved onto his own project, “Coriolanus,” retaining a co-producer credit on “W.E.”

Kris Thykier, who knew Madonna well from his former life in PR, took over the main producing role, and saw it through to the end. He shares the producer credit with Madonna herself, but there’s no doubt who’s the boss.

“The two things I knew about her were that she works harder than anyone I’ve ever met, and she has a very strong vision and creative eye for what she wants to do, so it never crossed my mind that she couldn’t do it,” Thykier says.

Thykier says Madonna always wants the best people on her team. “If you think about the way she’s worked with producers on her albums, she always chooses very strong partners. She’s among the most collaborative directors, and I know how much time she spent with the heads of departments and the actors.”

Another individual close to the production says that Madonna was completely involved in every aspect of the film: “She’s a massive perfectionist, she works flat-out round the clock, and she wants people who can keep up with that kind of pace.”

Even though the $17 million budget came largely from Madonna herself, plus the U.K. tax credit, Thykier says that like any other independent productions, cash was always tight. “This wasn’t a philanthropic exercise,” he says. “There were proper sales estimates; she needed to know what the commercial marketplace would bear. She felt strongly enough to put up a significant proportion of the equity, but it was a very, very ambitious project for the money, shot in three countries, across five different decades, with over 100 locations and sets in the U.K. alone.”

Self-financing gave Madonna the freedom to make her own creative choices. “The joy of being able to get the best actor for the role, rather than necessarily casting the most bankable, was considerable,” Thykier says. When Vera Farmiga, who was originally lined up to play Wallis, became pregnant, Madonna cast the virtually unknown Andrea Riseborough on the strength of her performance as the young Margaret Thatcher in a BBC telepic.

Strong presales at Berlin, notably to the Weinstein Co. and Optimum, gave credibility to what always risked being dismissed as a hobby project. The fact that sales agent IM Global had previously handled Tom Ford’s self-financed debut “A Single Man” encouraged buyers to share Madonna’s faith. n