MCPcopy Create free account
hub / github.com/SolarLune/masterplan / Mult

Method Mult

utils.go:598–610  ·  view source on GitHub ↗
(scalar float32)

Source from the content-addressed store, hash-verified

596}
597
598func (color Color) Mult(scalar float32) Color {
599
600 newColor := NewColor(color.RGBA())
601
602 for i, _ := range newColor[:3] {
603
604 newColor[i] = uint8(float32(newColor[i]) * scalar)
605
606 }
607
608 return newColor
609
610}
611
612func (color Color) Invert() Color {
613

Callers 9

UpdateMethod · 0.45
DrawMethod · 0.45
DrawShadowMethod · 0.45
DrawMethod · 0.45
MouseActionsMethod · 0.45
UpdateMethod · 0.45
UpdateMethod · 0.45
AddZoomMethod · 0.45
mainFunction · 0.45

Calls 2

RGBAMethod · 0.95
NewColorFunction · 0.85

Tested by

no test coverage detected