Added HSB/HSV conversion.
Code refactoring.
Bug fixing.