Mario Van Peebles knows that social media can be used not only to promote a film, but also to make one.

His latest project, “We the Party,” tapped into Twitter feeds and Facebook for some of the dialogue of his young protags, as well as for soundtrack selections.

While writing the script for an untitled thriller that stars Van Peebles, Michael Jai White, Snoop Dogg and Orlando Jones, the filmmaker was intrigued by the type of music his teenagers were listening to.

“My kids were listening to stuff like the Rejects and New Boys, and I liked it and was curious about what the party scene looked like for kids like my own,” he says, adding that he started to go to clubs with his kids, to see if any movie could come out of it.

“When ‘New Jack City’ (which Van Peebles directed) came out, the industry was what I called a ‘push industry,’ where the label was able to put money behind a record or artist and push it out because you put enough money behind it,” he says. “Now we are in a ‘pull’ industry where everything is measured by downloads, so I knew the audience participation would play an important part to the making of this movie.”

Peebles and his producing partner, Michael Cohen, studied what kids were talking about online, recorded teen conversations at his house and worked that dialogue into the script.

They eschewed focus groups to screen early cuts in high schools in order to figure out what songs to use for the soundtrack. “We really were out to make this a collaborative effort with the audience,” he says. “This a new generation that wants to grow up and be more like (President) Obama and not just like Tiger (Woods) and Michael (Jordan) — so who better to make this movie with than the kids it will have the greatest effect on?”

Van Peebles is in talks with distrubutors.