Intentando mostrar un .AVI

Post Reply
Loren
Posts: 458
Joined: Fri Feb 16, 2007 10:29 am
Location: Cadiz - España

Intentando mostrar un .AVI

Post by Loren »

Compañeros, buenas:

Llevo 2 días completos intentando mostrar un .AVI mediante recurso (Pelles C) en un Dialog, pero sin resultado!!

- He seguido los pasos según \samples\copyfile.prg y \samples\testvid.prg
- y también el hilo:
http://forums.fivetechsupport.com/viewt ... eo#p151661

pero nada... me muestra el Dialog y un recuadro blanco donde debería aparecer el video, pero NADA.
En Pelles C he intentado con el control Tanimate y con Tvideo

... pero NADA.
Tengo FHW 8.07
¿Algún alma caritativa?

Mil gracias.
Un saludo
Desde Cádiz, españa.
User avatar
Rick Lipkin
Posts: 2397
Joined: Fri Oct 07, 2005 1:50 pm
Location: Columbia, South Carolina USA

Re: Intentando mostrar un .AVI

Post by Rick Lipkin »

Loren

Consider this code ..make a few changes for your resource file ..

Rick Lipkin

Code: Select all

// playavi.prg

#INCLUDE "FIVEWIN.CH"

//----------------------
Function _Playavi( cDEFA )

LOCAL oDLG, oAVI

IF .not. FILE( cDEFA+"\DHEC.AVI" )
   RETURN(NIL)
ENDIF

DEFINE DIALOG oDLG FROM 0,1  to 24,80   ;
       COLOR "N/N,N/N,N/N,N/N,N/N"  ;
       TITLE "Fleet Vehicle Maint"      ;
       STYLE nOr( WS_THICKFRAME, WS_POPUP )

  @ 1,9.5 VIDEO oAVI FILE ( cDEFA+"\DHEC.AVI" ) of oDLG SIZE 158,100 NOBORDER

ACTIVATE DIALOG oDLG CENTERED  ;
         ON INIT ( oAVI:PLAY(), AviTimer( oDLG, 2.5)  )

oDLG:END()
oAVI:END()

oDLG := NIL
oAVI := NIL

SysReFresh()

RETURN(NIL)

//-------------------
Static Func AviTimer(oDLG, nSECONDS )

LOCAL oTMR

DEFINE TIMER oTMR OF oDLG INTERVAL nSECONDS * 1000 ;
       ACTION ( oDLG:END() )

ACTIVATE TIMER oTMR

RETURN(NIL)

// end playavi.prg
 
horacio
Posts: 1270
Joined: Wed Jun 21, 2006 12:39 am
Location: Capital Federal Argentina

Re: Intentando mostrar un .AVI

Post by horacio »

Rick , with version 14.12 the code is not working .

regards
Loren
Posts: 458
Joined: Fri Feb 16, 2007 10:29 am
Location: Cadiz - España

Re: Intentando mostrar un .AVI

Post by Loren »

Rick , with version 8.07 the code is not working .
Only a window appears with white background where the video should be .
Any other suggestions , please?
Thanks

Lorenzo
Desde Cádiz, España.
User avatar
Rick Lipkin
Posts: 2397
Joined: Fri Oct 07, 2005 1:50 pm
Location: Columbia, South Carolina USA

Re: Intentando mostrar un .AVI

Post by Rick Lipkin »

Loren

The code I suggested to you has been working for many Years with FWH just about all versions .. Make sure you are pointing to the file and also .. my default .avi player is Windows Media player.

Rick Lipkin
Post Reply