[Eeglablist] Matlab Video Processing Question

Vikram Rao vikramraobm at gmail.com
Fri Sep 7 16:24:46 PDT 2012


Hey Davide,

Another way of playing a video in matlab is via psychtoolbox (
http://psychtoolbox.org/HomePage ) and using SimpleMovieDemo.m to play a
movie...see if that is any useful.

Cheers!
Vikram Rao
UC Berkeley, Psychology Dept.
Berkeley, California, USA
"Brain cells come and brain cells go, but fat cells live forever!!"


On Thu, Sep 6, 2012 at 10:38 AM, Davide Baldo <davidebaldo84 at gmail.com>wrote:

> Dear all,
>
> I know the following question does not concern EEGLAB, but I guess many
> user might have had my same problem.
>
>
> I need to load a .mp4 video into Matlab to process it frame by frame. The
> video contain audio as well.
>
> To import the video into Matlab I am using:
>
> xyloObj = VideoReader( MyVideo );
> info = get(xyloObj);
>
> info =
>
>           Duration: 50.4746
>               Name: 'SuperMarioTest.mp4'
>               Path: 'C:\Users\programmer\Documents\MATLAB\'
>                Tag: ''
>               Type: 'VideoReader'
>           UserData: []
>       BitsPerPixel: 24
>          FrameRate: 29.9700
>             Height: 1080
>     NumberOfFrames: 1514
>        VideoFormat: 'RGB24'
>               Width: 1920
>
>
> Everything works fine and I am able to process the video frame by frame
> and save the output in another .mp4 file, but the output video has no
> audio!:
>
>     mov.cdata = vidFrames(:,:,:,1);
>     mov.colormap = [];
>     OBJ.writeVideo(mov.cdata);
>
>
> I have the following problem: I need the audio to be present in the output
> video (the same audio that is present in the input video).
>
> How can I do that???
>
> Thanks a lot for you help!
>
>
> Davide.
>
> _______________________________________________
> Eeglablist page: http://sccn.ucsd.edu/eeglab/eeglabmail.html
> To unsubscribe, send an empty email to
> eeglablist-unsubscribe at sccn.ucsd.edu
> For digest mode, send an email with the subject "set digest mime" to
> eeglablist-request at sccn.ucsd.edu
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://sccn.ucsd.edu/pipermail/eeglablist/attachments/20120907/977ee340/attachment.html>


More information about the eeglablist mailing list