[<<] [<] Page 1 of 1 [>] [>>] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
16bpp and 32bpp blitting broken
From: Greg Haerr ####@####.#### Date: 7 Jan 2000 18:05:41 -0000 Message-Id: <C1962B36D9BBD311B0F80060083DFEFB01E627@SYS.CenSoft.COM> Kyle, Attached is a rewritten fblin16.c function, for speed. It incorporates your patch, slightly rewritten. Could you please check that it works? Also, from inspection it appears that fblin32.c has the same problem. Both of these fixes will appear in the next cut. /* srccopy bitblt, opcode is currently ignored*/ void linear16_blit(PSD dstpsd, COORD dstx, COORD dsty, COORD w, COORD h, PSD srcpsd, COORD srcx, COORD srcy, int op) { ADDR16 dst = dstpsd->addr; ADDR16 src = srcpsd->addr; int i; int dlinelen = dstpsd->linelen; int slinelen = srcpsd->linelen; assert (dst != 0); assert (dstx >= 0 && dstx < dstpsd->xres); assert (dsty >= 0 && dsty < dstpsd->yres); assert (w > 0); assert (h > 0); assert (src != 0); assert (srcx >= 0 && srcx < srcpsd->xres); assert (srcy >= 0 && srcy < srcpsd->yres); assert (dstx+w <= dstpsd->xres); assert (dsty+h <= dstpsd->yres); assert (srcx+w <= srcpsd->xres); assert (srcy+h <= srcpsd->yres); DRAWON; dst += dstx + dsty * dlinelen; src += srcx + srcy * slinelen; while(--h >= 0) { #if 0 /* a _fast_ memcpy is a _must_ in this routine*/ wmemcpy(dst, src, w); dst += dlinelen; src += slinelen; #else for(i=0; i<w; ++i) *dst++ = *src++; dst += dlinelen - w; src += slinelen - w; #endif } DRAWOFF; } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: 16bpp and 32bpp blitting broken
From: Kyle Harris ####@####.#### Date: 7 Jan 2000 21:04:50 -0000 Message-Id: <38765222.48030E29@nexus-tech.net> Oooppss, I meant to send this to the list, but it only made it back to Greg. Is there anyone working on JPEG support? Can I help? Thanks, Kyle. > > Greg Haerr wrote: > > > > Kyle, > > Attached is a rewritten fblin16.c function, for speed. > > It incorporates your patch, slightly rewritten. Could you please > > check that it works? > > This patch works fine for the 16bpp driver (sorry for the confusion with > my earlier patch being backwards). I found this bug running the > demos/mwin/demo.c code. > > I also noticed in demos/nanox/demo3.c reference to a GrJPEG function > with offscreen memory drawing and blitting. This is exactly what I need > to do. Hmmmm... might save me some time if someone shared this bit of > code (GrJPEG) for a starting point :-). > > Kyle. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
[<<] [<] Page 1 of 1 [>] [>>] |