sna: Add missing implementation for Triangles

Feed both into spans and as a mask fallback.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
Chris Wilson 2011-09-02 13:13:38 +01:00
parent 695e7115ef
commit db0fb368c1
3 changed files with 947 additions and 41 deletions

View File

@ -523,6 +523,26 @@ void sna_composite_trapezoids(CARD8 op,
PictFormatPtr maskFormat,
INT16 xSrc, INT16 ySrc,
int ntrap, xTrapezoid *traps);
void sna_composite_triangles(CARD8 op,
PicturePtr src,
PicturePtr dst,
PictFormatPtr maskFormat,
INT16 xSrc, INT16 ySrc,
int ntri, xTriangle *tri);
void sna_composite_tristrip(CARD8 op,
PicturePtr src,
PicturePtr dst,
PictFormatPtr maskFormat,
INT16 xSrc, INT16 ySrc,
int npoints, xPointFixed *points);
void sna_composite_trifan(CARD8 op,
PicturePtr src,
PicturePtr dst,
PictFormatPtr maskFormat,
INT16 xSrc, INT16 ySrc,
int npoints, xPointFixed *points);
Bool sna_gradients_create(struct sna *sna);
void sna_gradients_close(struct sna *sna);

View File

@ -3346,6 +3346,11 @@ Bool sna_accel_init(ScreenPtr screen, struct sna *sna)
ps->UnrealizeGlyph = sna_glyph_unrealize;
ps->AddTraps = sna_add_traps;
ps->Trapezoids = sna_composite_trapezoids;
ps->Triangles = sna_composite_triangles;
#if PICTURE_SCREEN_VERSION >= 2
ps->TriStrip = sna_composite_tristrip;
ps->TriFan = sna_composite_trifan;
#endif
}
}
#endif

File diff suppressed because it is too large Load Diff