Skip to content

Instantly share code, notes, and snippets.

@TorbenKoehn
Created July 22, 2016 10:35
Show Gist options
  • Save TorbenKoehn/a9ec2885d8fc869e47224d44ed6004c8 to your computer and use it in GitHub Desktop.
Save TorbenKoehn/a9ec2885d8fc869e47224d44ed6004c8 to your computer and use it in GitHub Desktop.
<?php
private static $functions = [
'rgb' => ['className' => RgbColor::class, 'args' => [
['type' => 'int', 'base' => 255],
['type' => 'int', 'base' => 255],
['type' => 'int', 'base' => 255]
]],
'rgba' => ['className' => RgbaColor::class, 'args' => [
['type' => 'int', 'base' => 255],
['type' => 'int', 'base' => 255],
['type' => 'int', 'base' => 255],
['type' => 'float', 'base' => 1]
]],
'hsl' => ['className' => HslColor::class, 'args' => [
['type' => 'float', 'base' => 360],
['type' => 'float', 'base' => 1],
['type' => 'float', 'base' => 1]
]],
'hsla' => ['className' => HslaColor::class, 'args' => [
['type' => 'float', 'base' => 360],
['type' => 'float', 'base' => 1],
['type' => 'float', 'base' => 1],
['type' => 'float', 'base' => 1]
]],
'hsv' => ['className' => HsvColor::class, 'args' => [
['type' => 'float', 'base' => 360],
['type' => 'float', 'base' => 1],
['type' => 'float', 'base' => 1]
]],
'hsva' => ['className' => HsvaColor::class, 'args' => [
['type' => 'float', 'base' => 360],
['type' => 'float', 'base' => 1],
['type' => 'float', 'base' => 1],
['type' => 'float', 'base' => 1]
]]
];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment