Hi, all, i have a problem with this script that doesn't do what a need to; i'm getting initiated in Matlab, so i'm waiting you to support me for. I'll be very grateful.
The code is:
_____________________________________________________
function videomonocolor
vid = videoinput('macvideo', 1, 'YCbCr422_1280x720');
k=0;
c=1;
start(vid);
while c<100
A = getsnapshot(vid);
A=imresize(A,0.3);
rgb = A;
I = ycbcr2rgb(rgb);
imshow(I)
c=c+1;
end
end
__________________________________________________________
As You can see, the script is very austere; then well, what im trying to do is take a snapshot from my macbook's camera and give it to a matrix that could be modified, saving, so, all informatión of image, then work with it, and display it again. All this have a purpose, but now, I just have one problem: the imshow doesn't show me anything. Some times show just the last image that was taken, when the program it's done. I think isn't the appropriate way to display every image and show almost at runtime, just like a video motion. I don't want to take a sequence of photos, then use the comand that convert this same sequence to a video. I want to work with an image at the time, and show the same information that has been token. I know about the function that do this, showing a preview of the video.. but i want every snapshot for do something with it... I apologise for my english, that is not the best. Greetings from México, and good night here.