video frame capturing and resizing
显示 更早的评论
i have installed a webcam .. following codes i am using for the video capturing the video
a = imaqhwinfo;
[camera_name, camera_id, format] = getCameraInfo(a);
vid = videoinput(camera_name, camera_id, format);
% Set the properties of the video object
set(vid, 'FramesPerTrigger', Inf);
set(vid, 'ReturnedColorspace', 'rgb')
vid.FrameGrabInterval = 5;
%start the video aquisition here
start(vid)
while(vid.FramesAcquired<=5)
data = getsnapshot(vid);
imwrite(data,'1.jpg');
end
the saved frame 1.jpg is of size 640X680...
but i want to capture the images of 104 X 120 poxel size,.. tell me how to do
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Video Formats and Interfaces 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!