LOS ANGELES — A prosecutor says the man charged with killing a movie studio executive in Southern California had “murder on the brain.”

The remark came during opening statements Thursday in the Los Angeles trial of John Creech.

Prosecutors say Creech, a convicted drug dealer, beat to death 57-year-old Gavin Smith in the man’s Mercedes in 2012 because Smith was having an affair with his wife.

The 20th Century Fox distribution executive was missing for 2 ½ years before his remains were found in a shallow desert grave near Palmdale in 2014.

Creech was indicted for murder in 2015 and could face life in prison if convicted.

In his opening statement, Creech’s public defender said Creech hit Smith in self-defense after the executive attacked him.