private static function createRgbArray(array $vals)
    {
        foreach ($vals as $r) {
            foreach ($vals as $g) {
                foreach ($vals as $b) {
                    $colors[] = ['r' => $r, 'g' => $g, 'b' => $b];
                }
            }
        }
        
        return $colors;
    }
private static function createRgbArray(array $vals)
    {
        foreach ($vals as $r) {
            foreach ($vals as $g) {
                foreach ($vals as $b) {
                    $colors[] = ['r' => $r, 'g' => $g, 'b' => $b];
                }
            }
        }
        
        return $colors;
    }
private static function createRgbArray ( array $ vals ) { foreach ( $ vals as $ r ) { foreach ( $ vals as $ g ) { foreach ( $ vals as $ b ) { $ colors [ ] = [ 'r' => $ r , 'g' => $ g , 'b' => $ b ] ; } } } return $ colors ; }
Creates rgb codes array

@example
[
['r' => 0, 'g' => 0, 'b' => 0],
['r' => 0, 'g' => 51, 'b' => 0],
['r' => 0, 'g' => 0, 'b' => 51],
...
]

@param array $vals Initial values

@return array
Creates rgb codes array