BOSTON  A judge ruled Tuesday that jurors can be shown video of an 8-year-old boy accidentally shooting himself in the head with a submachine gun at a gun show, setting up an unusually grisly courtroom scene in the manslaughter trial of a former police chief who organized the event.

Judge Peter A. Velis of Hampden Superior Court in Springfield, Mass., is still deciding whether audio from after the shooting  in which the boy can be heard screaming and his father praying  will be played for the jury. The video will be played in its entirety, but little is visible after the boy, Christopher Bizilj of Manchester, Conn., shot himself.

Judge Velis said he must ensure that the chief, Edward Fleury, receives a fair trial. The video “would shock the conscience of any reasonable human being,” Judge Velis said in court Tuesday, The Associated Press reported.

“The greatest risk in this case is invoking any sympathy,” Judge Velis said.

Douglas L. Keene, a trial consultant in Austin, Tex., said more video  including at times extremely graphic footage  is bound to end up in courtrooms as cities install surveillance cameras and amateurs shoot video with cellphones.