G
Guest
I have a black and white bitmap in my app. White is transparent and the
black needs to be converted to a different color.
To manage this, I've created a ColorMatrix as follows:
Color sortArrowColor_ = Color.FromArgb(184, 192, 201);
float r = (float)sortArrowColor_.R / 255F;
float g = (float)sortArrowColor_.G / 255F;
float b = (float)sortArrowColor_.B / 255F;
float[][] ptsArray ={
new float[] {1, 0, 0, 0, 0},
new float[] {0, 1, 0, 0, 0},
new float[] {0, 0, 1, 0, 0},
new float[] {0, 0, 0, 1, 0},
new float[] {r, g, b, 0, 1}};
The sortArrowColor represents the color I'm trying to achieve for the black.
The result I get however, is 184, 192, 200
I know it sounds trivial, but in this case, my client has very exacting
standards that must be met and this will fail to pass the testing phase. Is
there any way to correct this?
Pete
black needs to be converted to a different color.
To manage this, I've created a ColorMatrix as follows:
Color sortArrowColor_ = Color.FromArgb(184, 192, 201);
float r = (float)sortArrowColor_.R / 255F;
float g = (float)sortArrowColor_.G / 255F;
float b = (float)sortArrowColor_.B / 255F;
float[][] ptsArray ={
new float[] {1, 0, 0, 0, 0},
new float[] {0, 1, 0, 0, 0},
new float[] {0, 0, 1, 0, 0},
new float[] {0, 0, 0, 1, 0},
new float[] {r, g, b, 0, 1}};
The sortArrowColor represents the color I'm trying to achieve for the black.
The result I get however, is 184, 192, 200
I know it sounds trivial, but in this case, my client has very exacting
standards that must be met and this will fail to pass the testing phase. Is
there any way to correct this?
Pete