def buildTransform(inputProfile, outputProfile, inMode, outMode, renderingIntent=INTENT_PERCEPTUAL, flags=0):
 if ((not isinstance(renderingIntent, int)) or (not (0 <= renderingIntent <= 3))):
  raise PyCMSError('renderingIntent must be an integer between 0 and 3')
 if ((not isinstance(flags, int)) or (not (0 <= flags <= _MAX_FLAG))):
  raise PyCMSError(('flags must be an integer between 0 and %s' + _MAX_FLAG))
 try:
  if (not isinstance(inputProfile, ImageCmsProfile)):
   inputProfile = ImageCmsProfile(inputProfile)
  if (not isinstance(outputProfile, ImageCmsProfile)):
   outputProfile = ImageCmsProfile(outputProfile)
  return ImageCmsTransform(inputProfile, outputProfile, inMode, outMode, renderingIntent, flags=flags)
 except (IOError, TypeError, ValueError) as v:
  raise PyCMSError(v)

def buildTransform ( inputProfile , outputProfile , inMode , outMode , renderingIntent = INTENT_PERCEPTUAL , flags = 0 ) : if ( ( not isinstance ( renderingIntent , int ) ) or ( not ( 0 <= renderingIntent <= 3 ) ) ) : raise PyCMSError ( 'renderingIntent must be an integer between 0 and 3' ) if ( ( not isinstance ( flags , int ) ) or ( not ( 0 <= flags <= _MAX_FLAG ) ) ) : raise PyCMSError ( ( 'flags must be an integer between 0 and %s' + _MAX_FLAG ) ) try : if ( not isinstance ( inputProfile , ImageCmsProfile ) ) : inputProfile = ImageCmsProfile ( inputProfile ) if ( not isinstance ( outputProfile , ImageCmsProfile ) ) : outputProfile = ImageCmsProfile ( outputProfile ) return ImageCmsTransform ( inputProfile , outputProfile , inMode , outMode , renderingIntent , flags = flags ) except ( IOError , TypeError , ValueError ) as v : raise PyCMSError ( v )
builds an icc transform mapping from the inputprofile to the outputprofile .