|
Roadmap |
Site sponsored by
IGEL
|
||
|
|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [directfb-users] Re: Displaying buffer contents
Quoting Sven Neumann:
> {
> char *src = buffer; /* buffer points to your data buffer */
> char *dst;
> int pitch;
>
> surface->Lock (surface, (void **) &dst, &pitch);
surface->Lock (surface, DSLF_WRITE, (void **) &dst, &pitch) ;)
> for (y = 0; y < height; y++)
> {
> memcpy (dst, src, width * bpp);
>
> src += width * bpp;
> dst += pitch;
> }
>
> surface->UnLock (surface);
surface->Unlock (surface) ;)
> }
>
>
What about adding
IDirectFBSurface::Read ( x, y, width, height, dst, pitch ) and
IDirectFBSurface::Write( x, y, width, height, src, pitch ) ?
Did I miss a parameter? Is the order ok?
--
Best regards,
Denis Oliver Kropp
.------------------------------------------.
| DirectFB - Hardware accelerated graphics |
| http://www.directfb.org/ |
"------------------------------------------"
Convergence GmbH
--
Info: To unsubscribe send a mail to ecartis@directfb.org with
"unsubscribe directfb-users" as subject.
|
|
| directfb.org |
|
Development |
|
Old Archives |