it has the trappings of a driver now, but essential features are missing: discovery and forgetting
continuous-integration/drone/push Build is passing

This commit is contained in:
2022-02-15 22:31:51 +01:00
parent 73e6cba770
commit 107b29620d
8 changed files with 732 additions and 48 deletions
+1
View File
@@ -21,6 +21,7 @@ type DriverKind string
var (
DTHue DriverKind = "Hue"
DTHue2 DriverKind = "Hue2"
DTNanoLeaf DriverKind = "Nanoleaf"
DTLIFX DriverKind = "LIFX"
DTMill DriverKind = "Mill"
+4 -4
View File
@@ -127,8 +127,8 @@ func (cg *ColorGamut) Conform(color ColorXY) ColorXY {
return color
}
for x := best.X - 0.001; x < best.X+0.001; x += 0.0001 {
for y := best.Y - 0.001; y < best.Y+0.001; y += 0.0001 {
for x := best.X - 0.001; x < best.X+0.001; x += 0.0002 {
for y := best.Y - 0.001; y < best.Y+0.001; y += 0.0002 {
color2 := ColorXY{X: x, Y: y}
if cg.atTheEdge(color2) {
@@ -139,8 +139,8 @@ func (cg *ColorGamut) Conform(color ColorXY) ColorXY {
}
}
for x := best.X - 0.0001; x < best.X+0.0001; x += 0.00001 {
for y := best.Y - 0.0001; y < best.Y+0.0001; y += 0.00001 {
for x := best.X - 0.0001; x < best.X+0.0001; x += 0.00003 {
for y := best.Y - 0.0001; y < best.Y+0.0001; y += 0.00003 {
color2 := ColorXY{X: x, Y: y}
if cg.atTheEdge(color2) {