effects

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 2, 2021 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Flash

type Flash struct {
	// contains filtered or unexported fields
}

Flash is a simple effects that ramps up and down a single color over a given duration

func NewFlash

func NewFlash(c color.Color, d time.Duration) (f *Flash)

NewFlash builds and returns a new Flash effect

func (*Flash) Frame

func (f *Flash) Frame(num int) bool

Frame populates the pixels in the strip passed during initialization

func (*Flash) Init

func (f *Flash) Init(s *adalight.Strip, fps int) string

Init initializes this Effect, passing it the Strip

type Ramp

type Ramp struct {
	// contains filtered or unexported fields
}

Ramp is a simple effects that ramps up and down a single color over a given duration

func NewRamp

func NewRamp(c color.Color, d time.Duration) (r *Ramp)

NewRamp builds and returns a new Ramp effect

func (*Ramp) Frame

func (r *Ramp) Frame(num int) bool

Frame populates the pixels in the strip passed during initialization

func (*Ramp) Init

func (r *Ramp) Init(s *adalight.Strip, fps int) string

Init initializes this Effect, passing it the Strip

type Train

type Train struct {
	// contains filtered or unexported fields
}

Train is a simple effects that lights up every light in sequence a fixed number of times

func NewTrain

func NewTrain(c color.Color, r int) (f *Train)

NewTrain builds and returns a new Train Effect

func (*Train) Frame

func (t *Train) Frame(num int) bool

Frame populates the pixels in the strip passed during initialization

func (*Train) Init

func (t *Train) Init(s *adalight.Strip, _ int) string

Init initializes this Effect, passing it the Strip

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL