function negate (options) {
  this.options.negate = is.bool(options) ? options : true;
  if (is.plainObject(options) && 'alpha' in options) {
    if (!is.bool(options.alpha)) {
      throw is.invalidParameterError('alpha', 'should be boolean value', options.alpha);
    } else {
      this.options.negateAlpha = options.alpha;
    }
  }
  return this;
}
Produce the "negative" of the image.

@example
const output = await sharp(input)
  .negate()
  .toBuffer();

@example
const output = await sharp(input)
  .negate({ alpha: false })
  .toBuffer();

@param {Object} [options]
@param {Boolean} [options.alpha=true] Whether or not to negate any alpha channel
@returns {Sharp}