From: hackbard Date: Thu, 28 Aug 2003 22:39:27 +0000 (+0000) Subject: - X-Git-Url: https://hackdaworld.org/gitweb/?a=commitdiff_plain;h=c05d446cdfc52acdb2411ce819d7043134192e80;p=my-code%2Fivac.git - --- diff --git a/dfbapi.c b/dfbapi.c index 7de46c3..cabc5a7 100644 --- a/dfbapi.c +++ b/dfbapi.c @@ -13,6 +13,28 @@ // int dfb_play_video() // int dfb_stop_video() +int flip_blit_callback(void *ctx) { + struct ivac *ivac=ctx; + + ivac->dfb_stuff.v_surface->Flip(ivac->dfb_stuff.v_surface,NULL,0); + + return 1; +} + +int dfb_play_video(struct ivac *ivac) { + + ivac->dfb_stuff.v_provider->PlayTo(ivac->dfb_stuff.v_provider,ivac->dfb_stuff.v_surface,NULL,flip_blit_callback,(void *)ivac); + + return 1; +} + +int dfb_stop_video(struct ivac *ivac) { + + ivac->dfb_stuff.v_provider->Stop(ivac->dfb_stuff.v_provider); + + return 1; +} + int dfb_init(int arg_c,char **arg_v,struct ivac *ivac) { DFBSurfaceDescription sdsc; // DFBFontDescription fdsc; @@ -41,7 +63,6 @@ int dfb_init(int arg_c,char **arg_v,struct ivac *ivac) { ivac->dfb_stuff.layer->CreateWindow(ivac->dfb_stuff.layer,&wdsc,&(ivac->dfb_stuff.v_window)); ivac->dfb_stuff.v_window->GetSurface(ivac->dfb_stuff.v_window,&(ivac->dfb_stuff.v_surface)); ivac->dfb_stuff.v_window->SetOpacity(ivac->dfb_stuff.v_window,0xff); - ivac->dfb_stuff.v_provider->PlayTo(ivac->dfb_stuff.v_provider,ivac->dfb_stuff.v_surface,NULL,NULL,NULL); return 1; } @@ -54,4 +75,3 @@ int dfb_tini(struct ivac *ivac) { return 1; } -