In one of the Mockingjay Part 1 trailers Katniss sees that Peeta is alive, although he is not the same sweet boy she left behind in the arena. "What have they done to you?" she whispers when she sees the emotionally-unstable Peeta on a TV screen. Well, the answer to that is [spoiler] the Capitol hijacked Peeta's brain using tracker jacker venom. This specific form of torture was chosen to hurt Peeta not just on a physical level, but to actually alter his memories of Katniss and make him hate her.
Beetee, District 13's resident smarty-pants, explained the process in the book saying, "It's a type of fear conditioning ... Memories can be changed. Brought to the forefront of your mind, altered, and saved again in the revised form."
It's not unlike Pavlov's classical conditioning theory which proves that you can train someone to associate an object or feeling with a behavior—if you reward their behavior the same way every time. Pavlov tested this theory on his dogs by feeding them whenever a bell rang. Eventually they learned salivate on cue whenever a bell would ring. You might remember when the theory was tested in an episode of The Office. Jim gave Dwight a mint every time Dwight turned his computer on. Eventually Dwight began to associate the startup sound his computer made with getting a mint. So, Jim Pavlov-ed Dwight.
The Capitol did a similar thing to Peeta, but in a much more damaging way. Instead of rewarding Peeta when he saw images of Katniss, they injected him with tracker jacker venom which targets the section of your brain where fear is stored. As Katniss' sister Prim puts it they've "taken his memories of Katniss and distorted them so they're scary." They did so to the point where he would see Katniss as the cause of his fear and lash out at her, ultimately attempting to injure or kill her.
The thing with tracker jacker poison is that it doesn't just prey on fears you already have, it creates new fearful memories and makes you unable to distinguish whether they were real or not. Katniss was stung by a few tracker jackers in the first Games and remembers the experience as full of "Terror. Hallucinations. [And] nightmarish visions of losing those [she] loves."
To create those nightmarish memories for Peeta, the Capitol would likely strap him down and make him watch footage of Katniss in the Games and then inject him with the venom. "Not enough to induce a three-day blackout. Just enough to infuse the memory with fear and doubt," Beetee explains in the book. "And that's what [his] brain puts in long-term storage."
Basically the Capitol was rewriting Peeta's brain, which is absolutely terrifying. They did so to destroy him, and ultimately to destroy Katniss. After learning of his condition she understands why it was so easy to rescue him. "If 13 hadn't made the effort, Peeta would've been delivered to me anyway," Katniss realizes. "Dropped off in an actively warring district or perhaps 13 itself. Tied up with ribbons and tagged with my name. Programmed to murder me."
It's maybe the worst thing you can do to a person: change who they are and alter their memories of someone they loved. In the book we were spared from having to see the hijacking happen since it's written from Katniss' perspective. But the movie has the freedom to show us Peeta's captivity. I know that if reading about the process was upsetting, seeing it will be 10 times worse—especially since Josh Hutcherson is such a great actor. It's possibly going to be a roughest part of Mockingjay, and I'm not prepared to see it all go down.
There's physical torture, and then there's what the Capitol did to Peeta which is a whole other level of horrendous. It's a wonder he managed to survive it at all.