Name

OpenVideoFile — opens a video file for reading

Calling Sequence

VideoFilePointer = OpenVideoFile(VideoPath);

Parameters

VideoPath

name or complete path of a video file

VideoFilePointer

pointer to a video file

Description

This function opens a video file for reading.

Examples

VideoPath = 'contrib\IPD-3.1\demos\red-car-video.avi';

VideoInfo = GetVideoInfo(VideoPath);

VideoFilePointer = OpenVideoFile(VideoPath);

figure();

for n = 1 : VideoInfo.NumberOfFrames

 RGB = ReadImage(VideoFilePointer);

 ShowColorImage(RGB, VideoPath);

end;

CloseVideoFile(VideoFilePointer);

See Also

GetVideoStruct, ReadImage, CloseVideoFile, GetVideoInfo, ReadImageFromVideo