Re: How to play 2 or more movies asynchronously?

From: Chris P. [MVP] (msdn_at_chrisnet.net)
Date: 04/22/04


Date: Thu, 22 Apr 2004 17:37:30 -0400

Archana2004 wrote:
> OK. Let me explain my objective first. I am writing this code for a
> neurocognitive experiment. This is what I am trying to achieve:
>
> 1) I want to run 2 movies simultaneously for a given duration of time.
> Lets assume 2 seconds, in this case.
> 2) At the same time, while watching movies, I want to get some
> response from the viewer(user). Lets say, he presses 1 each time he
> views an object1 and 2 when he views an object2. This response should
> be given while he is watching the movie. And movies must not stop on
> kbhit(). 3) The movies should stop after the specified duration. The
> windows must close automatically when movies stop.
>
> I am trying this code at home on XP home edition. I am not aware if
> it has any limitations on multi-threading. I suspect it has because
> the code that you have suggested doesn`t work the way you say it
> should. It still doesnt take in my response until movies stop.

What do you want to do with the responses? Right now I set it to stop the
video as an example but you can make it do anything you want, that was just
an *example* as I'm not here to write your software.

I think you need to kick it up a notch. Create a windows application and
embed 2 MCI control windows on a dialog. You will have tighter control over
the playback and can set yourself a timer to stop and close the video after
x seconds. Additionally you will be able to trap all keyboard input in the
PreTranslateMessage handler without interfering with the program operation.



Relevant Pages

  • Re: Windows Movie Maker Problems
    ... I would like to burn with WMM. ... the movies I have downloaded appear in a folder, ... I am running Windows Vista and I am ... Assuming you have Windows DVD Maker... ...
    (microsoft.public.windows.vista.music_pictures_video)
  • Re: FFmpeg and Mencoder DIVX...
    ... I've encoded the movies under Linux using Mencoder, ... I have a WinXP machine to test the movies on and it has Windows ... > Media Player and Quicktime 6. ...
    (comp.os.linux.questions)
  • Re: The Palladium (NGSCB) rollout has begun!!!
    ... Although in this particular case I was going off on the "movies on demand" ... Linux has been breaking that monopoly of theirs. ... >> Linux is far more modern than any Windows OS. ... >> IE has not been avaliable for the Mac for quite some time dumbass. ...
    (comp.os.linux.misc)
  • Re: WMV on Mac, to Windows
    ... I have some Windows Media movies downloaded using Flip4Mac on ... and saved from there as QuickTime movies. ... I want to pass these to a friend with a Windows ... compatibility problems these days usually end at hard ware and ...
    (comp.sys.mac.apps)
  • Re: Poor quality video playback
    ... was able to make the program that came with the tuner work (Catalyst ... Media Center) so am using the Windows Movie Maker that comes with XP ... Movies down load Ok and look pretty good on the small window monitor, ... Settings are: WMV. ...
    (microsoft.public.windowsxp.video)

Quantcast