currentsz = dmasz;
}
} else {
- fprintf(stderr, "%s - cannot draw primitive\n", __func__);
- return;
+ unreachable("Cannot draw primitive; validate_render should have "
+ "prevented this");
}
}
} else if (ctx->Light.ShadeModel == GL_SMOOTH) {
TAG(render_tri_fan_verts)( ctx, start, count, flags );
} else {
- fprintf(stderr, "%s - cannot draw primitive\n", __func__);
- return;
+ unreachable("Cannot draw primitive; validate_render should have "
+ "prevented this");
}
}
{
GLuint j, nr;
- if (ctx->Light.ShadeModel == GL_FLAT &&
- TNL_CONTEXT(ctx)->vb.AttribPtr[_TNL_ATTRIB_COLOR0]->stride) {
- /* Vertices won't fit in a single buffer or elts not available - should
- * never happen.
- */
- fprintf(stderr, "%s - cannot draw primitive\n", __func__);
- return;
- } else {
+ if (ctx->Light.ShadeModel != GL_FLAT ||
+ !TNL_CONTEXT(ctx)->vb.AttribPtr[_TNL_ATTRIB_COLOR0]->stride) {
LOCAL_VARS;
const unsigned dmasz = GET_SUBSEQUENT_VB_MAX_VERTS() & ~1;
unsigned currentsz;
}
FLUSH();
+ } else {
+ unreachable("Cannot draw primitive; validate_render should have "
+ "prevented this");
}
}