- Sort Score
- Result 10 results
- Languages All
Results 1 - 3 of 3 for transparentIndex (0.28 sec)
-
src/image/gif/writer.go
if n > len(p) { // Pad with black. clear(dst[3*len(p) : 3*n]) } return 3 * n, nil } func (e *encoder) colorTablesMatch(localLen, transparentIndex int) bool { localSize := 3 * localLen if transparentIndex >= 0 { trOff := 3 * transparentIndex return bytes.Equal(e.globalColorTable[:trOff], e.localColorTable[:trOff]) && bytes.Equal(e.globalColorTable[trOff+3:localSize], e.localColorTable[trOff+3:localSize])
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 13 21:38:09 UTC 2024 - 11.9K bytes - Viewed (0) -
src/image/gif/reader_test.go
b := &bytes.Buffer{} b.WriteString(headerStr) b.WriteString(paletteStr) for transparentIndex := 0; transparentIndex < 3; transparentIndex++ { if transparentIndex < 2 { // Write the graphic control for the transparent index. b.WriteString("\x21\xf9\x04\x01\x00\x00") b.WriteByte(byte(transparentIndex)) b.WriteByte(0) } // Write an image with bounds 2x1, as per TestDecode.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Apr 11 16:15:54 UTC 2024 - 13.3K bytes - Viewed (0) -
src/image/gif/reader.go
if !useLocalColorTable { // Clone the global color table. m.Palette = append(color.Palette(nil), d.globalColorTable...) } if ti := int(d.transparentIndex); ti < len(m.Palette) { m.Palette[ti] = color.RGBA{} } else { // The transparentIndex is out of range, which is an error // according to the spec, but Firefox and Google Chrome // seem OK with this, so we enlarge the palette with
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Apr 11 16:15:54 UTC 2024 - 17.5K bytes - Viewed (0)