//
//  CattailArtNSColor.h
//
//  Created by Theresa L. Ford on 10/12/08.
//  Copyright 2008 Theresa L. Ford. All rights reserved.  Visit http://www.cattail.nu
//
/*

Programmaticaly generate colors based on the art concepts of:

	complement
	split complement
	triad
	analogous
	value
	saturation
	chromatic

Choose between the RGB "light" color wheel or Newton's "art" color wheel.
See: http://www.cattail.nu/newton/index.html to compare and try these color wheels.
Most computer generated schemes are based on the RGB color wheel, because that's
the true color set based on light, however traditional art uses Newton's 
color wheel.

The first 2 functions switch hues between color wheels.  The rest of the functions
return colors which can be used to generate "eye-pleasing" color schemes
for applications and computer art.

*/

#import <Cocoa/Cocoa.h>

@interface CattailArtNSColor : NSObject {
}

+ (CGFloat) NewtonHueToRGBHue: (CGFloat) startHue;
+ (CGFloat) RGBHueToNewtonHue: (CGFloat) startHue;

+ (NSColor *) RGBComplement: (NSColor *)rootColor;
+ (NSColor *) NewtonComplement: (NSColor *)rootColor;

+ (NSArray *) RGBSplitComplementArray: (NSColor *)rootColor;
+ (NSArray *) NewtonSplitComplementArray: (NSColor *)rootColor;

+ (NSArray *) RGBTriadArray: (NSColor *)rootColor;
+ (NSArray *) NewtonTriadArray: (NSColor *)rootColor;

// Try 45.0 tetradicDegrees
+ (NSArray *) RGBTetradicArray: (NSColor *)rootColor tetradicDegreesCGFloat:(CGFloat)tetradicDegrees;
+ (NSArray *) NewtonTetradicArray: (NSColor *)rootColor tetradicDegreesCGFloat:(CGFloat)tetradicDegrees;

// Try 15.0 stepDegrees
+ (NSArray *) RGBAnalogousArray: (NSColor *)rootColor numberOfColorsInt:(int)numberOfColors stepDegreesCGFloat:(CGFloat)stepDegrees;
+ (NSArray *) NewtonAnalogousArray: (NSColor *)rootColor numberOfColorsInt:(int)numberOfColors stepDegreesCGFloat:(CGFloat)stepDegrees;

// Try 15.0 stepDegrees
+ (NSArray *) ValueArray: (NSColor *)rootColor numberOfColorsInt:(int)numberOfColors stepDegreesCGFloat:(CGFloat)stepDegrees;

// Try 15.0 stepDegrees
+ (NSArray *) SaturationArray: (NSColor *)rootColor numberOfColorsInt:(int)numberOfColors stepDegreesCGFloat:(CGFloat)stepDegrees;

// Evenly grab colors all the way around the wheel.  Try 6 numberOfColors.
+ (NSArray *) RGBChromaticArray: (NSColor *)rootColor numberOfColorsInt:(int)numberOfColors;
+ (NSArray *) NewtonChromaticArray: (NSColor *)rootColor numberOfColorsInt:(int)numberOfColors;

// alignment = -1 (left) 0 (center) or 1 (right)
+ (NSArray *) RGBFlameArray: (NSColor *)rootColor numberOfColorsInt:(int)numberOfColors hueStepDegreesCGFloat:(CGFloat)hueStepDegrees saturationStepDegreesCGFloat:(CGFloat)saturationStepDegrees brightnessStepDegreesCGFloat:(CGFloat)brightnessStepDegrees alignmentInt:(int)alignment;

+ (NSArray *) NewtonFlameArray: (NSColor *)rootColor numberOfColorsInt:(int)numberOfColors hueStepDegreesCGFloat:(CGFloat)hueStepDegrees saturationStepDegreesCGFloat:(CGFloat)saturationStepDegrees brightnessStepDegreesCGFloat:(CGFloat)brightnessStepDegrees alignmentInt:(int)alignment;

@end
