Prosecutors will put on eye-witnesses, show photographs and even play a surveillance camera video in a gang stabbing trial currently underway.

It’s a good thing for them because the 17-year-old victim refused Wednesday to testify.

Despite being stabbed 17 times in the neck, torso and arm, Jose “Rafa” Cortez wouldn’t cooperate on the witness stand, and at one point denied ever being stabbed.

 He gestured to a scar and admitted spending two days in a hospital after a warning against perjury from Judge Arthur Wick.

But he did little else to assist in prosecuting Francisco Jesus Serrano, 18, who is accused of attempted murder, assault with a deadly weapon and gang charges in the 2010 attack.

Serrano watched from the defense table as Cortez smiled and poured himself water while prosecutor Bob Waner tried to question him.

Earlier, Waner showed pictures to jurors of Cortez’s wounds and asked his girlfriend to recount the Washington Street encounter with four alleged gang rivals.

 A video of the attack made by a neighbor’s home security camera is expected to be played Friday morning.

Still, it’s possible the fear of being labeled a snitch prevented the victim from helping out, although he denied it when Waner asked if that was making him reluctant.

Law enforcement sources say it’s a common problem in cases involving gangs.

There’s a code of conduct passed down from prison gang bosses and enforced on the street forbidding any cooperation with police.

Those who do can be punished with death or disfigured. Violators may get a “snitch scar” from ear to chin or have a family member beaten or killed.

Trial witnesses often refuse to testify and risk contempt charges or jail.

It can make winning a conviction difficult as jurors grapple with the motivations behind a person refusing to identify defendants or tell what happened.

“It’s a very real fear,” said one law enforcement source.

 The Cortez stabbing seems to illustrate the point.

According to witnesses, Cortez and his then-girlfriend, Cindy Sarabia, 19, were walking to her house on July 21, 2010 when men in a car drove up and asked Cortez what hood he was from.

Cortez saw them coming and pushed Sarabia out of the way. He then started running. The men pursued him on foot, catching up with him a few blocks away.

That’s when Cortez was stabbed multiple times. A neighbor testified that she watched in horror from a window.

Cortez wouldn’t acknowledge the confrontation and said he didn’t know who stabbed him. When asked why he ran that day, he said he was running because he wanted to.

“I was just running,” he said.