Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

TMediaPlayer (or TActiveMovie) not capable to use rate property?

Posted on 2003-10-27
5
212 Views
Last Modified: 2010-04-05
Hi,

i am into this problem since over a week now.

Situation: I have 4 video windows (MediaPlayer ActiveX version 6.4) created
at run time within MDI childs.
Every Player has its own files which are reloaded by a getfile procedure i wrote.
I have some cutom made controls like play, stop, pause etc.

Problem: I want to implement a fast forward and a fast rewind button, which
rewinds or forwards the videos.

The MediaPlayer 6.4 ActiveX has a method called "rate". This can be between
1 to 10 to play faster (2=double speed, 4=quad speed etc).
The method can also be from -1 to -10 to reverse playback the video. But this
doesnt work - it does nothing it seems.
I am using avi-format files without marker positions.

The illogical thing is, it plays very fast with positive rate values, but not
reverse with negative values.

So someone know how to solve this problem, or knows of a workaround (not
writing my own procedure which repositions the "currentposition" every 100ms) ?

thanks for your time.
I will also spend a lot of more points if you need them to show me a proper
solution.

regards,
Sascha
0
Comment
Question by:sahmann
  • 3
  • 2
5 Comments
 
LVL 12

Expert Comment

by:Lee_Nover
ID: 9632900
err .. try out DSPack - www.progdigy.com
0
 

Author Comment

by:sahmann
ID: 9633590
Thx Lee_Nover,

just downloaded the DSPack.

Is it right that this one is using DirectShow/DirectDraw to display
a videofile (and automaticall chooses right Filtergraph) ?

But then, how will i be able to set a rate property, or to code
a fast forward, fast reverse (reverse playback) procedure?

0
 
LVL 12

Expert Comment

by:Lee_Nover
ID: 9633634
yes it uses DirectShow ... MediaPlayer AX also uses it .. practicaly any media app uses DirectShow
check the forum .. all your questions have already been answered :)
0
 

Author Comment

by:sahmann
ID: 9634140
Dear Lee:

Thanks again for your help.
My problem mainly concerns the reverse-play procedure.

Since all Delphi components such as TActiveMovie, TMediaPlay AX, DSPack are
based on the DirectShow Lib, witch does not provide an appropriate way for
reverse-playback, all these VCLs are somehow useless for me.

As described, I am using avi-files to record the video data. The file format
has to be avi due to compatibility issues and in order to apply any standard
compression filter.

The problem is: Reverse-playback can only be done by pausing the
media-player instance (or in my case all four players) and setting up a
timer to change the current file-position many times a second (e.g.: to
achieve a frame rate of 10fps the timer has to re-set the position 10 times
a second - in my case this would be even 40 times a second since I am
working with 4 players).

The normal play-method implemented within DirectShow can only play forwards
and also does not "seek" the file for every frame to be played.

The work-around - as described above - does work somehow. It is just too
resource-consuming to use it for all four players. Also, for instance: To
achieve a frame rate of 20fps I would have to re-set the position twice as
often, witch would certainly not be possible.


Please tell me if there is a way to just have a file being played backwards
instead of forwards and also if double/quad-speed reverse playing can be
done the same way.

I searched the whole site for many hours, but I could not find any question
addressing this topic.
0
 
LVL 12

Accepted Solution

by:
Lee_Nover earned 130 total points
ID: 9634315
using dspack 1 seems to work:
http://www.progdigy.com/boards/index.php?act=ST&f=1&t=21&hl=&s=549afecb992ccf4139c1e7a7a8baef9d

playing backwards is kinda hard coz you need to 'undo' the previous frame
that means you have to decode it normally all the way up to your frame from the last keyframe
then for each frame nackwards do an undo ..
this is actually doable .. the harder part is the sound and synchronization
sorry I can't be of more help
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question