/* * Render a triangle using points and respecting edge flags. */ static void _swsetup_edge_render_point_tri(struct gl_context *ctx, const GLubyte *ef, GLuint e0, GLuint e1, GLuint e2, const SWvertex *v0, const SWvertex *v1, const SWvertex *v2) { if (ef[e0]) _swrast_Point( ctx, v0 ); if (ef[e1]) _swrast_Point( ctx, v1 ); if (ef[e2]) _swrast_Point( ctx, v2 ); _swrast_flush(ctx); }
void ffb_fallback_point(GLcontext *ctx, ffb_vertex *v0) { SWvertex v[1]; ffb_translate_vertex(ctx, v0, &v[0]); _swrast_Point(ctx, &v[0]); }
static void swsetup_points( struct gl_context *ctx, GLuint first, GLuint last ) { struct vertex_buffer *VB = &TNL_CONTEXT(ctx)->vb; SWvertex *verts = SWSETUP_CONTEXT(ctx)->verts; GLuint i; if (VB->Elts) { for (i = first; i < last; i++) if (VB->ClipMask[VB->Elts[i]] == 0) _swrast_Point( ctx, &verts[VB->Elts[i]] ); } else { for (i = first; i < last; i++) if (VB->ClipMask[i] == 0) _swrast_Point( ctx, &verts[i] ); } }
void nouveau_fallback_point(struct nouveau_context *nmesa, nouveauVertex *v0) { GLcontext *ctx = nmesa->glCtx; SWvertex v[1]; _swsetup_Translate(ctx, v0, &v[0]); _swrast_Point(ctx, &v[0]); }
static void mga_fallback_point( mgaContextPtr mmesa, mgaVertex *v0 ) { GLcontext *ctx = mmesa->glCtx; SWvertex v[1]; mga_translate_vertex( ctx, v0, &v[0] ); _swrast_Point( ctx, &v[0] ); }
static void trident_fallback_point( tridentContextPtr tmesa, const tridentVertex *v0 ) { GLcontext *ctx = tmesa->glCtx; SWvertex v[1]; trident_translate_vertex( ctx, v0, &v[0] ); _swrast_Point( ctx, &v[0] ); }
static void tdfx_fallback_point( tdfxContextPtr fxMesa, tdfxVertex *v0 ) { GLcontext *ctx = fxMesa->glCtx; SWvertex v[1]; tdfx_translate_vertex( ctx, v0, &v[0] ); _swrast_Point( ctx, &v[0] ); }
static void r128_fallback_point( r128ContextPtr rmesa, r128Vertex *v0 ) { GLcontext *ctx = rmesa->glCtx; SWvertex v[1]; _swsetup_Translate( ctx, v0, &v[0] ); _swrast_Point( ctx, &v[0] ); }
static void i810_fallback_point( i810ContextPtr imesa, i810Vertex *v0 ) { GLcontext *ctx = imesa->glCtx; SWvertex v[1]; i810_translate_vertex( ctx, v0, &v[0] ); _swrast_Point( ctx, &v[0] ); }
static void sis_fallback_point( sisContextPtr smesa, sisVertex *v0 ) { GLcontext *ctx = smesa->glCtx; SWvertex v[1]; sis_translate_vertex( ctx, v0, &v[0] ); _swrast_Point( ctx, &v[0] ); }
static void _swsetup_render_point_tri( GLcontext *ctx, GLuint e0, GLuint e1, GLuint e2 ) { SScontext *swsetup = SWSETUP_CONTEXT(ctx); struct vertex_buffer *VB = &TNL_CONTEXT(ctx)->vb; GLubyte *ef = VB->EdgeFlag; SWvertex *verts = swsetup->verts; SWvertex *v0 = &verts[e0]; SWvertex *v1 = &verts[e1]; SWvertex *v2 = &verts[e2]; GLchan c[2][4]; GLchan s[2][4]; GLuint i[2]; if (ctx->_TriangleCaps & DD_FLATSHADE) { COPY_CHAN4(c[0], v0->color); COPY_CHAN4(c[1], v1->color); COPY_CHAN4(s[0], v0->specular); COPY_CHAN4(s[1], v1->specular); i[0] = v0->index; i[1] = v1->index; COPY_CHAN4(v0->color, v2->color); COPY_CHAN4(v1->color, v2->color); COPY_CHAN4(v0->specular, v2->specular); COPY_CHAN4(v1->specular, v2->specular); v0->index = v2->index; v1->index = v2->index; } if (ef[e0]) _swrast_Point( ctx, v0 ); if (ef[e1]) _swrast_Point( ctx, v1 ); if (ef[e2]) _swrast_Point( ctx, v2 ); if (ctx->_TriangleCaps & DD_FLATSHADE) { COPY_CHAN4(v0->color, c[0]); COPY_CHAN4(v1->color, c[1]); COPY_CHAN4(v0->specular, s[0]); COPY_CHAN4(v1->specular, s[1]); v0->index = i[0]; v1->index = i[1]; } }
static void via_fallback_point(struct via_context *vmesa, viaVertex *v0) { struct gl_context *ctx = vmesa->glCtx; SWvertex v[1]; _swsetup_Translate(ctx, v0, &v[0]); viaSpanRenderStart( ctx ); _swrast_Point(ctx, &v[0]); viaSpanRenderFinish( ctx ); }
static void sis_fallback_point( sisContextPtr smesa, sisVertex *v0 ) { struct gl_context *ctx = smesa->glCtx; SWvertex v[1]; _swsetup_Translate( ctx, v0, &v[0] ); sisSpanRenderStart( ctx ); _swrast_Point( ctx, &v[0] ); sisSpanRenderFinish( ctx ); _swrast_flush( ctx ); }
static void intel_fallback_point( intelContextPtr intel, intelVertex *v0 ) { GLcontext *ctx = &intel->ctx; SWvertex v[1]; if (0) fprintf(stderr, "\n%s\n", __FUNCTION__); _swsetup_Translate( ctx, v0, &v[0] ); intelSpanRenderStart( ctx ); _swrast_Point( ctx, &v[0] ); intelSpanRenderFinish( ctx ); }
static void i830_fallback_point( i830ContextPtr imesa, i830Vertex *v0 ) { GLcontext *ctx = imesa->glCtx; SWvertex v[1]; if (0) fprintf(stderr, "\n%s\n", __FUNCTION__); i830_translate_vertex( ctx, v0, &v[0] ); i830SpanRenderStart( ctx ); _swrast_Point( ctx, &v[0] ); i830SpanRenderFinish( ctx ); }