Smooth color with GL_QUAD_STRIPS
<p>I'm trying to draw this color map in OpenGL</p>

<p><a href="http://i.stack.imgur.com/vlMfX.png" rel="nofollow">COLOR_MAP</a></p>

<p>When using QUADS, the result look fine:</p>

<pre><code>int colorArr[] = { 255, 224, 192, 160, 128, 96, 64, 32 };
gluOrtho2D(-2, 2, -2, 2);
glPolygonMode(GL_FRONT, GL_FILL);

glDisable(GL_COLOR_LOGIC_OP);
glClear(GL_COLOR_BUFFER_BIT);
glBegin(GL_QUADS);
for (int i = 0; i &lt; 8; i++) {
    glColor3ub(colorArr[7 - i], 0, 0);
    glVertex2f(-4, i - 4);
    glVertex2f(4, i - 4);
    glVertex2f(4, i - 4 + 1);
    glVertex2f(-4, i - 4 + 1);
}
glEnd();

glEnable(GL_COLOR_LOGIC_OP);
glLogicOp(GL_OR);

glBegin(GL_QUADS);
for (int i = 0; i &lt; 8; i++) {
    glColor3ub(0, colorArr[i], 0);
    glVertex2f(i - 4, 4);
    glVertex2f(i - 4, -4);
    glVertex2f(i - 4 + 1, -4);
    glVertex2f(i - 4 + 1, 4);
}
glEnd();

glFlush();
</code></pre>

<p>But if I use QUAD_STRIPS to draw the polygons, the color get smooth between the lines:</p>

<pre><code>int colorArr[] = { 255, 224, 192, 160, 128, 96, 64, 32 };
gluOrtho2D(-2, 2, -2, 2);
glPolygonMode(GL_FRONT, GL_FILL);

glDisable(GL_COLOR_LOGIC_OP);
glClear(GL_COLOR_BUFFER_BIT);

glBegin(GL_QUAD_STRIP);
for (int i = 0; i &lt; 8; i++) {
    glColor3ub(colorArr[7 - i], 0, 0);
    glVertex2f(-4, i - 4);
    glVertex2f(4, i - 4);
}
glVertex2f(-4, 4);
glVertex2f(4, 4);
glEnd();

glEnable(GL_COLOR_LOGIC_OP);
glLogicOp(GL_OR);

glBegin(GL_QUAD_STRIP);
for (int i = 0; i &lt; 8; i++) {
    glColor3ub(0, colorArr[i], 0);
    glVertex2f(i - 4, 4);
    glVertex2f(i - 4, -4);
}
glVertex2f(4, 4);
glVertex2f(4, -4);
glEnd();
glFlush();
</code></pre>

<p>Do you have any idea why is that?</p>