mav_paletteColourSet - Define an ambient colour entry in a palette.

[ Maverik Level 1 functions ]

#

mav_paletteColourSet

## Summary

Define an ambient colour entry in a palette.

## Syntax

void mav_paletteColourSet(MAV_palette *p, int index, float r, float g, float b, float a);

- MAV_palette *p
  Palette to set.

- int index
  Index of colour to define, in range 0..`mav_opt_maxColours` (default 150).

- float r, float g, float b
  Red, green and blue component of colour (0.0-1.0)

- float a
  Alpha component of colour (0.0-1.0) (0=transparent, 1=opaque)

## Description

This function defines ambient colour entry `index` of palette `p` as specified by `r`, `g`, `b` and `a`.

N.B. For transparent colours to be handled correctly, the options variable `mav_opt_trans` must be set to `MAV_TRUE` before mav_initialise is called.

## See also

mav_paletteMaterialSet.html>mav_paletteMaterialSet, mav_paletteTextureSet.html>mav_paletteTextureSet

Back to the index page.