|
![](/i/fill.gif) |
Warp wrote:
> Why wouldn't it work?
Hmmm. I remember.
You get an IDirectFB by calling
IDirectFB* myIDFB;
good = DirectFBCreate(&myIDFB);
You get a "screen" by calling
IDirectFBScreen* myIDFBScreen;
good = myIDFB->GetScreen(myIDFB, this, that, &myIDFBScreen);
In other words, DirectFB is allocating and initlaizig the space, as well as
filling in pointers (like the GetScreen pointer) for each one, and then
putting the space it allocated into the pointer whose address you passed in.
I'm not sure how to cleanly turn that into a class without wrapping every
single function. None of those functions take a pointer to your own class,
so there's a bunch of casting on every creation at a minimum, and you have
to hope your class is laid out the same as the parent struct and all that.
Maybe it'll work, but it's 9 hours of working on this stuff today already, so...
--
Darren New, San Diego CA, USA (PST)
I ordered stamps from Zazzle that read "Place Stamp Here".
Post a reply to this message
|
![](/i/fill.gif) |