mix.setImageAssessmentMetadata(iam);
sm = new SpatialMetrics ();
iam.setSpatialMetrics(sm);
ice = new ImageColorEncoding ();
iam.setImageColorEncoding(ice);
gci = new GeneralCaptureInformation ();
icm.setGeneralCaptureInformation(gci);
// Here are some pieces which are constructed once, but added only if they're needed.
cp = new ColorProfile (); // Add this to phi if needed
iccp = new IccProfile(); // Add this to cp if needed