Original Post
I'm currently using this: But speed is REALLY important, and if I call this function something about 10,000 times so it's really slowing down...
unsigned short rgb(short r,short g,short b)
{
unsigned short PixelCol;
PixelCol = (unsigned short) (r & 0xff) << 11 | (g & 0xff) << 6 | (b & 0xff);
return PixelCol;
}