>
>
> It assumes that the source x coordinate is aligned to 8 pixels, because
> there might be functions not handling the phase properly, but the warning
> could also be obsolete and all functions support unaligned sources.
Are you sure ? I just saw the latest generic.c and not found any changes..
static void Bop_a1_set_alphapixel_Aop_rgb16( GenefxState *gfxs )
{
int i;
int w = gfxs->length;
u8 *S = gfxs->Bop[0];
u16 *D = gfxs->Aop[0];
u16 Cop = gfxs->Cop;
for (i=0; i<w; i++) {
if (S[i>>3] & (0x80 >> (i&7)))
D[i] = Cop;
}
}
When the start pixel is not aligned onto 1 byte then output picture will be
wrong. Or I am not right ?
My version of the function was :
int i = gfxs->Xphase >> 13;/* !!!!!!! */
int w = gfxs->length + i; /* !!!!!! */
for (; i<w; i++,j++) { /* !!!!!!! */
"Xphase" I set in Bop_xy()
int alignment = DFB_PIXELFORMAT_ALIGNMENT(gfxs->src_format);
if ( alignment )/*only A1,A4*/
gfxs->Xphase = ((x & alignment)<<16)/(alignment+1);
I will be very glad if you was able to fix it by other way :)
--
Best Regards
Nikita Egorov
[EMAIL PROTECTED]
[EMAIL PROTECTED]
_______________________________________________
directfb-users mailing list
[email protected]
http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-users