def __init__(self, indexes, brightness=1.0, hue1=0.6, hue2=0.8): Effect.__init__(self, indexes) self.brightness = brightness self.hue1 = hue1 self.hue2 = hue2 self.eq_start = random.uniform(0.2, 0.7) self.curr_pos = self.eq_start self.last_time_percent = 0
def __init__(self, indexes, num_of_dark): """ :param indexes: :param base_color: :param single_pix_color: :param tot_range_pixels: you can decide that the total number of pixel will be different than len(indexes) """ Effect.__init__(self, indexes) self.num_of_dark = num_of_dark
def __init__(self, indexes, from_color, to_color, type=GoToColorEffectType.CONST_SPEED): Effect.__init__(self, indexes) self.from_color = from_color self.to_color = to_color self.type = type
def __init__(self, indexes, hue): Effect.__init__(self, indexes) self._start_percent = random.random() * 0.2 self._full_percent = self._start_percent + max(0.1, random.random() * 0.3) self._stop_percent = 1.0 - random.random() * 0.2 self._decent_percent = self._stop_percent - max( 0.1, random.random() * 0.3) self.hue = hue self.max_brightness = 0.5 * random.random()
def __init__(self, indexes, base_color, single_pix_color, tot_range_pixels): """ :param indexes: :param base_color: :param single_pix_color: :param tot_range_pixels: you can decide that the total number of pixel will be different than len(indexes) """ Effect.__init__(self, indexes) self.base_color = base_color self.single_pix_color = single_pix_color self.tot_range_pixels = tot_range_pixels
def __init__(self, indexes, timed_color, tail_percent, tot_range_pixels, circular=False): """ :param indexes: :param base_color: :param tail_percent: out of the tot_range_pixels :param tot_range_pixels: you can decide that the total number of pixel will be different than len(indexes) """ Effect.__init__(self, indexes) self.timed_color = timed_color self.tail_percent = tail_percent self.tot_range_pixels = tot_range_pixels self.tot_pixel_with_tail = tot_range_pixels if circular else (1 + tail_percent) * tot_range_pixels self.circular = circular
def __init__(self, indexes, leds_percent_per_beat, brightness=1.0, fade_factor=0.9): Effect.__init__(self, indexes) self.hue = 0 self.fade_factor = fade_factor self.brightness = brightness self.number_of_leds_per_beat = int(leds_percent_per_beat * len(self.indexes)) self.lighted_counter = 0
def __init__(self, indexes, timed_color, start_time, on_time_start, on_time_end, dark_time, location_percent): """ :param indexes: :param timed_color: :param start_time: when the star starts to shine :param on_time_start: when the star receive full brightness :param on_time_end: when the star starts to disappear :param dark_time: when the star goes dark please use like this 0 <= start_time <= on_time_start <= on_time_end <= dark_time <= 1.0 """ Effect.__init__(self, indexes) self.timed_color = timed_color self.start_time = start_time self.on_time_start = on_time_start self.on_time_end = on_time_end self.dark_time = dark_time self.location_percent = location_percent
def __init__(self, indexes, leds_percent_per_cycle): Effect.__init__(self, indexes) self._leds_per_cycle = max( int(leds_percent_per_cycle * len(self.indexes)), 1) self.hue = 0
def __init__(self, indexes, timed_color): Effect.__init__(self, indexes) self.timed_color = timed_color
def __init__(self, indexes, color1, color2): Effect.__init__(self, indexes) self.color1 = color1 self.color2 = color2
def __init__(self, indexes, strting_hue): Effect.__init__(self, indexes) self.hue = strting_hue self.fibonacci(1) self.start_fib = 1
def __init__(self, indexes): Effect.__init__(self, indexes)
def __init__(self, indexes, number_of_snakes): Effect.__init__(self, indexes) self._number_of_snakes = number_of_snakes self.hue_start = random.random() self.start_pos = 0
def __init__(self, indexes, color): Effect.__init__(self, indexes) self.color = color
def __init__(self, indexes, color): Effect.__init__(self, indexes) self.color = color self.currentOnLed = -1
def __init__(self, indexes, from_color, to_color, power=1): Effect.__init__(self, indexes) self.from_color = from_color self.to_color = to_color self.power = power
def __init__(self, indexes, add_red_bootom=True): Effect.__init__(self, indexes) self.loop_num = 0 self.add_red_bootom = add_red_bootom self.create_effects() self.previous_time = 1
def __init__(self, indexes, color): Effect.__init__(self, indexes) self.color = color self.to_color = [0, 0, 0] self.power = 3
def __init__(self, indexes, num_of_blinks, color): Effect.__init__(self, indexes) self.num_of_blinks = num_of_blinks self.color = color