palette-setcolor!

Synopsis

(palette-setcolor! palette index color)

Parameters

  • palette: A palette colormap
  • index
  • color: A RGB color value

Description

This procedure sets the slot in a palette colormap to a specific RGB color. The index mus be in the range 0 … 65535.

Side Effects

The palette slot is set to the specified color.

Return Value

unspecified (ok)

Implementation

(define (palette-setcolor! palette index color)
 (palette-unfold! palette)
 (colormap-setpixel! palette index 0 color))

Example

> (define p (palette-create))
p
> (palette-setcolor! p 1234 (rgb 200 100 50))
ok
>