gc->pipe[pn].shader.ch = ch;
gc->pipe[pn].array.line = 1;
+ gc->pipe[pn].array.anti_alias = gc->dc->anti_alias;
gc->pipe[pn].array.use_vertex = 1;
gc->pipe[pn].array.use_color = 1;
gc->pipe[pn].array.use_texuv = 0;
shader_array_flush(gc);
gc->pipe[pn].array.line = 0;
+ gc->pipe[pn].array.anti_alias = 0;
gc->pipe[pn].array.use_vertex = 0;
gc->pipe[pn].array.use_color = 0;
gc->pipe[pn].array.use_texuv = 0;
}
}
}
- if (gc->pipe[i].shader.render_op != gc->state.current.render_op)
+ if ((gc->pipe[i].shader.render_op != gc->state.current.render_op) ||
+ gc->state.current.anti_alias)
{
switch (gc->pipe[i].shader.render_op)
{
if (gc->pipe[i].array.line)
{
+ if (gc->pipe[i].array.anti_alias)
+ {
+ glEnable(GL_BLEND);
+ glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
+ glHint(GL_LINE_SMOOTH, GL_NICEST);
+ glEnable(GL_LINE_SMOOTH);
+ }
+ else
+ {
+ glDisable(GL_LINE_SMOOTH);
+ }
+
glDisableVertexAttribArray(SHAD_TEXUV);
GLERR(__FUNCTION__, __FILE__, __LINE__, "");
glDisableVertexAttribArray(SHAD_TEXUV2);
gc->state.current.smooth = gc->pipe[i].shader.smooth;
gc->state.current.blend = gc->pipe[i].shader.blend;
gc->state.current.clip = gc->pipe[i].shader.clip;
+ gc->state.current.anti_alias = gc->pipe[i].array.anti_alias;
if (gc->pipe[i].array.vertex) free(gc->pipe[i].array.vertex);
if (gc->pipe[i].array.color) free(gc->pipe[i].array.color);