Solved

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

Posted on 2003-10-27
5
214 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
[X]
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
  • 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

Enroll in May's Course of the Month

May’s Course of the Month is now available! Experts Exchange’s Premium Members and Team Accounts have access to a complimentary course each month as part of their membership—an extra way to increase training and boost professional development.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Adoquery sql  left join does not work 25 119
Delphi...Split view - idea? 1 144
Delphi Seattle StructureView color 1 33
IP without any Dots 1 98
Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

732 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