Kenneth Lonergan says there are many ways for a film to incorporate music, but that he favors one in particular. “Counterpoint is usually the way that I like to use it,” says the director of “Manchester by the Sea.” “It always feels right to have the music help you step back a little and look at the whole environment, not just the characters’ experience.”

So when composer Lesley Barber sent him a short piece for a cappella voices she called “Plymouth Chorale,” Lonergan played it against a scene of Lee (Casey Affleck) driving. “It was the first thing we ever tried against that scene, and we never tried anything else because it just fit so well.”

And, as Lonergan later learned, it was especially apropos for this story of family ties, because the voices all belonged to the composer’s 19-year-old daughter, Jacoba, now in her third year at McGill University in Montreal, where she performs with Opera McGill and other ensembles.

“I’d written this piece and I wanted to hear how it sounded,” Barber explains. “So we set up a Skype recording in her dorm room.” The effect was to make it sound like the music was coming from a small space — from the inside of Lee’s emotional world. “I also took care to record all of Jacoba’s breaths, so you really got the sense of the person, as if from this deep place.”

A touch of parental pride is understandable, but Barber also points out that her daughter’s voice — containing very little vibrato, “almost an early-music voice” — was just right for the story. The composer initially found inspiration in the Calvinist hymns the Puritans brought to 17th-century New England, and decided that a certain amount of restraint was necessary in the score.

“I think of the music that Lesley wrote, and the source music we chose, as reflecting the environment that Lee is moving through,” the director says. “It’s coloring his experience. The fact that Leslie’s daughter is singing adds an emotional component that you might not get otherwise.”

Barber augmented the vocal passages with musically related material, mostly for strings and piano. She had worked with Lonergan on “You Can Count on Me,” so it was understood that he would add classical pieces to the mix.

“I knew I’d have to have music that wouldn’t be a conventional narrative score, but something really unique that would unify, blend in, and support what was happening in the film,” Barber notes.

Lonergan sees beauty and an ethereal quality to Barber’s music “that can also characterize the classical pieces that we ended up keeping in the film. There’s a humanity and an emotional texture that’s very much on a par with what Lesley writes.”