toHex() public static method

Method to convert a color space object to a hex RGB object
public static toHex ( Pop\Color\Space\ColorInterface $color ) : Hex
$color Pop\Color\Space\ColorInterface
return Pop\Color\Space\Hex
Example #1
0
 public function testLabToHex()
 {
     $hex = Convert::toHex(new Lab(100, 100, 100));
     $this->assertInstanceOf('Pop\\Color\\Space\\Hex', $hex);
     $this->assertEquals('#c39231', (string) $hex);
 }