Recent

Author Topic: How to keep the MPlayer really paused ?  (Read 4451 times)

metis

  • Sr. Member
  • ****
  • Posts: 300
How to keep the MPlayer really paused ?
« on: June 22, 2012, 03:15:00 pm »
Hi to all Laz-Proggers,

I'm just doing (another) FrontEnd for the MPlayer, using:
OS      WinXP SP3
Lazarus v0.9.30
MPlayer v0.6.10.

I know, there are quite a lot MPlayer-FrontEnds already done, like
SMPlayer, QMPlayer, TMPlayer, MPUI, MPUI-Ve, Cactus JukeBox, but
obviously not too many written in Lazarus yet.


Everything is working fine (Start/Stop, Play/Pause, Seek/SeekOnDragging, etc.), but:

In Paused-State, the MPlayer, on each 'SendCommand':
- steps one Frame forward, and
- unmutes for an instance (means Sound is heard),
even when using the 'pausing_keep'-SendCommand-Prefix - This is not really paused.

Of course, I could do some progging around, like:
Mute -> SaveCurrentPosition -> SendCommand -> RestoreLastPosition -> UnMute,
but may be there is some better way.

So, here my question:
Does anybody know, how to keep the MPlayer really paused ?
Life could be so easy, if there weren't those f*** Details.
My FFmpeg4Lazarus = FFPlay4Laz + FFGrab4Laz + FFInfo4Laz

w click

  • Full Member
  • ***
  • Posts: 180
Re: How to keep the MPlayer really paused ?
« Reply #1 on: June 22, 2012, 03:48:54 pm »
Could you drop the volume to zero and then restore after you've finished?

metis

  • Sr. Member
  • ****
  • Posts: 300
Re: How to keep the MPlayer really paused ?
« Reply #2 on: June 22, 2012, 04:43:41 pm »
Hi w click,

your solution finally is included in what I meant, when I wrote:
Mute -> SaveCurrentPosition -> SendCommand -> RestoreLastPosition -> UnMute, because:

of course, You may also put:
SaveCurrentVol -> SetVolToZero -> SaveCurrentPosition -> SendCommand -> RestoreLastPosition -> RestoreLastVol.

Puh, lots of 'SendCommands' - But, this is not, what I want.

My problem is:
Any 'SendCommand' provokes a "FrameStep+VolOnForAnInstance", no difference, if You use
SendCommand('<get/setproperty>', '<value>') or
SendCommand('get/set/stepproperty <property>', '<value>').

So, my question is (more precise):
Is there any other way to avoid this, p.e.
by using an additional Option in the SendCommand-String, or better
by interacting with the MPlayer in an other way but 'SendCommand -> ReadProcessOutput' ?

Thank You anyway
Life could be so easy, if there weren't those f*** Details.
My FFmpeg4Lazarus = FFPlay4Laz + FFGrab4Laz + FFInfo4Laz

w click

  • Full Member
  • ***
  • Posts: 180
Re: How to keep the MPlayer really paused ?
« Reply #3 on: June 22, 2012, 06:17:58 pm »
Yes, of course.

I've not used MPlayer, but went instead for MMSystem, which I got to work eventually.  Although I'm still trying to find a way to check the mute status that works.

 

TinyPortal © 2005-2018