All of the NYPD’s patrol officers will be outfitted with body cameras within three years under a new labor contract announced Tuesday as Mayor Bill de Blasio and the city's largest police union struck a deal after years of animosity. Our Bobby Cuza has more.

For years, he's been perhaps Mayor de Blasio’s greatest antagonist, even leading protests outside his Park Slope gym.

But Tuesday, Pat Lynch and the mayor shook hands for the cameras in announcing a five-year contract deal that gives officers a combined raise of 11 percent.

"It’s our job to make sure we’re standing up for our members," the union boss said. "Sometimes we do that by agreeing. Sometimes we disagree. Sometimes we shake hands. Sometimes we poke at each other. But the mission is to get to where police officers feel respected, they’re treated as professionals, they’re paid as professionals, that’s what we’ve done today.”

As part of the deal, which is retroactive to 2012, the union agreed to have all patrol officers wear body cameras by the end of 2019. Though many details remain unclear, the plan expands on a court-ordered pilot program.

"That is now being applied on a very aggressive schedule," Mayor de Blasio said. "And it was important to have the buy-in of the union representing those officers.”

The union also agreed to health care savings; a one-percent contribution to fund disability benefits; and it agreed to drop a number of pending lawsuits. But officers will get a two-and-a-half percent pay increase for so-called neighborhood policing.

"We, in our approach to neighborhood policing, are asking officers to learn a new way of doing the work, and to do a host of new work as part of their responsibilities," said de Blasio.

As for those protests, the mayor said he doesn't take it personally.

"We totally honor, respect the right to protest," the mayor said "I pretty much at this point experience a protest every day on some topic or another."

"We wanted to get the mayor and the staff to focus on our contract," Lynch said of the demonstrations. "I think it worked."

After having taken office with virtually all the city’s labor contracts expired, de Blasio has now struck deals with union representing 99 percent of the union’s workforce though this latest deal expires this summer, which means the city and the police union will soon be right back at the negotiating table.