This commit is contained in:
Kovid Goyal
2025-10-09 08:04:58 +05:30
parent 37bd77f4a8
commit e61e95da3a

View File

@@ -73,7 +73,7 @@ func (p *NRGB) NRGBAt(x, y int) NRGBColor {
return NRGBColor{}
}
i := p.PixOffset(x, y)
s := p.Pix[i : i+4 : i+4] // Small cap improves performance, see https://golang.org/issue/27857
s := p.Pix[i : i+3 : i+3] // Small cap improves performance, see https://golang.org/issue/27857
return NRGBColor{s[0], s[1], s[2]}
}