Added invert option.