#include <Vlib.h>

unsigned long
VConstantColor(Viewport *v, int cIndex)
{
  if (v->flags & VPDoubleBuffer) {
    return v->aPixel[cIndex];
  }

  return    v->w->color_to_pixel_map[v->aPixel[cIndex]];
}
