|
0 registered members (),
1,459
guests, and 9
spiders. |
Key:
Admin,
Global Mod,
Mod
|
|
|
waiting for avi to finish, please help
#451389
05/05/15 13:29
05/05/15 13:29
|
Joined: Feb 2006
Posts: 52
carlpa
OP
Junior Member
|
OP
Junior Member
Joined: Feb 2006
Posts: 52
|
I am working on a project for medical research. This is a reaction time study. The beginning is for inputinging test id. This is to be followed by an instructional avi. media_play is a background process and following instructions continue without waiting for the end of the avi, I know there are prior posts on this problem. There are so many posts in this forum that I don't know where to look. Can anyone direct me to the appropriate post? I need my test complete by June 1 as I hope to take it to China.
Thank you.
Researcher & clinician. A6, A7, & A8 First computer a Commodore Pet
|
|
|
Re: waiting for avi to finish, please help
[Re: carlpa]
#451390
05/05/15 13:44
05/05/15 13:44
|
Malice
Unregistered
|
Malice
Unregistered
|
There is no time stamp seeking in media_play. So I would break the avi into many small avi's and look at checking media_playing var.
But I am not sure I understand what the problem is and what you would like to achieve.
|
|
|
Re: waiting for avi to finish, please help
[Re: Ch40zzC0d3r]
#451400
05/05/15 16:21
05/05/15 16:21
|
Joined: Feb 2006
Posts: 52
carlpa
OP
Junior Member
|
OP
Junior Member
Joined: Feb 2006
Posts: 52
|
Thanks to all of you. The introduction function begins with enter ID, Enter age, etc. Then an avi. The avi is very simple, brief instructions on how and where to place the cursor and click.
My thought is to time the avi, then media_play (...); wait(-4);
in main: wait_for(introduction) to keep any other functions waiting. A good idea? one simple solution?
Researcher & clinician. A6, A7, & A8 First computer a Commodore Pet
|
|
|
Re: waiting for avi to finish, please help
[Re: carlpa]
#451401
05/05/15 16:36
05/05/15 16:36
|
Malice
Unregistered
|
Malice
Unregistered
|
Ch40zzC0d3r gives the best advice. However
var mhandle =0;
function play_vid()
{
mhandle = media_play(.....AVI);
while(media_playing(mhandle)){wait(1);}
... other actions to fallow....
}
|
|
|
Re: waiting for avi to finish, please help
[Re: ]
#451429
05/06/15 00:14
05/06/15 00:14
|
Joined: Feb 2006
Posts: 52
carlpa
OP
Junior Member
|
OP
Junior Member
Joined: Feb 2006
Posts: 52
|
Dear Malice,
Your suggestion worked. You have taught me a valuable trick. It also made me feel foolish not to have seen it. Thank you very much.
Researcher & clinician. A6, A7, & A8 First computer a Commodore Pet
|
|
|
Re: waiting for avi to finish, please help
[Re: carlpa]
#451430
05/06/15 00:30
05/06/15 00:30
|
Malice
Unregistered
|
Malice
Unregistered
|
Sure thing, your welcome.
Good luck on your project. Mal
|
|
|
|
|
|