Recent

Author Topic: MediaInfo  (Read 553 times)

P.curtis

  • Jr. Member
  • **
  • Posts: 77
MediaInfo
« on: March 14, 2020, 03:38:13 pm »
Hi All,
does anyone have any exprience with MediaInfo.dll?

I wanth to get somespecific info about a video file, for example width, height, bitrate ...

I have managed to get the demo sample program working, but I'm stuck getting specific information.

I think I need to look at the following :

Code: Pascal  [Select][+][-]
  1.  To_Display := To_Display + CR + CR + 'Get with Stream:=General and Parameter=^FileSize^' + CR;
  2.  To_Display := To_Display + MediaInfo_Get(Handle, Stream_General, 0, 'FileSize', Info_Text, Info_Name);

Any suggestions?

Thanks.

Mike.Cornflake

  • Hero Member
  • *****
  • Posts: 1251
Re: MediaInfo
« Reply #1 on: March 17, 2020, 06:21:20 am »
No experience with MediaInfo.dll.

I use ffprobe.exe, call it with TProcess and parse the output looking for what I need.   Simple text manipulation :-)  If you like I can share code...
Lazarus Trunk/FPC Trunk on Windows [7, 10]
  Have you tried searching this forum or the wiki?:   http://wiki.lazarus.freepascal.org/Alternative_Main_Page
  BOOKS! (Free and otherwise): http://wiki.lazarus.freepascal.org/Pascal_and_Lazarus_Books_and_Magazines

metis

  • Full Member
  • ***
  • Posts: 168
Re: MediaInfo
« Reply #2 on: March 23, 2020, 02:48:46 pm »
And I use 'FFInfo4Laz':
https://forum.lazarus.freepascal.org/index.php/topic,22038.msg208700.html#msg208700,
which is Part of 'FFPlay4Laz':
https://forum.lazarus.freepascal.org/index.php/topic,26666.msg337046.html#msg337046.

Quote
... use ffprobe.exe, call it with TProcess ...
For how to read out the Output of 'FFProbe' via TProcess, You may also take a Look at 'RunFFmpeg', which is Part of 'FFGrab4Laz':
http://forum.lazarus.freepascal.org/index.php/topic,43411.0.html
-> GoTo "RunFFmpeg".

'RunFFmpeg' has Code to run the following FFmpeg-Executables:
- 'ffprobe.exe' to read out MediaStream-Data (that's what You want)
- 'ffmpeg.exe' to record/convert/manipulate Audio/Video
- 'ffplay.exe' to play them,
and read their Outputs.  :)
« Last Edit: March 30, 2020, 08:47:53 pm by metis »
Life could be so easy, if there weren't those f*** Details.

alantelles

  • New member
  • *
  • Posts: 5
Re: MediaInfo
« Reply #3 on: April 23, 2020, 06:45:13 pm »
For MediaInfo I would really prefer use the CLI version as a process and handle the results in my program.

winni

  • Hero Member
  • *****
  • Posts: 1359
Re: MediaInfo
« Reply #4 on: April 23, 2020, 06:52:54 pm »

 

TinyPortal © 2005-2018