Recent

Author Topic: Playing videos within Lazarus  (Read 8507 times)

Student043

  • New Member
  • *
  • Posts: 27
Playing videos within Lazarus
« on: January 03, 2016, 05:13:07 pm »
Dear all,

Does someone know how to play videos within players? For example, if you open the program(OnFormShow), the video automatically starts.

Thank you in advance.

Regards,

Student043

balazsszekely

  • Guest
Re: Playing videos within Lazarus
« Reply #1 on: January 03, 2016, 05:39:26 pm »

Student043

  • New Member
  • *
  • Posts: 27
Re: Playing videos within Lazarus
« Reply #2 on: January 03, 2016, 07:32:26 pm »
Hello,

No, i didn't read that, but I don't a "Mediaplayer". Just a command like

var
  afsound:Tprocess;
  fl:string;

begin
  isPlaying := false;
  fl := Application.Location;
  fl := copy(fl,1,Pos('/project1.app',fl)-1);
  afsound := Tprocess.create(nil);
  afsound.CommandLine := 'afplay ' + '''' + fl + '/Test.mp3' + '''';
  afsound.Execute;
  afsound.Free;           


Thank you in advance.

Regards,

Student043

Mike.Cornflake

  • Hero Member
  • *****
  • Posts: 1269
Lazarus Trunk/FPC latest fixes on Windows 11
  I'm getting old and stale.  Slowly getting used to git, I'll get there...

 

TinyPortal © 2005-2018