GVnc.ColorMap¶
Fields¶
Name |
Type |
Access |
Description |
---|---|---|---|
colors |
r/w |
||
offset |
r/w |
||
size |
r/w |
Methods¶
class |
|
|
|
|
|
|
|
|
Details¶
- class GVnc.ColorMap¶
- classmethod new(offset, size)¶
- Parameters:
- Returns:
the new color map
- Return type:
Allocate a new colour map object able to store colour map entries with indexes in the range offset to offset + size.
The color map must be freed with
GVnc.ColorMap.free
when no longer required.
- copy()¶
- Returns:
the new color map
- Return type:
Allocate a new color map initializing it with a copy of the data stored in self.
- free()¶
Release the memory associated with the color map self
- lookup(idx)¶
- Parameters:
idx (
int
) – the index to set- Returns:
True
if idx was in range,False
otherwise- red:
pointer to hold the red value
- green:
pointer to hold the green value
- blue:
pointer to hold the blue value
- Return type:
Lookup the RGB values associated with the colour map entry at position idx
- set(idx, red, green, blue)¶
- Parameters:
- Returns:
- Return type:
Update the RGB value associated with the color map entry at position idx.