Fabrizio,
As implemented, cquiver and vfcolor can only display a rectangular grid of vectors. Thus the quiver functionality you are looking for is not available. Sorry! I'll consider whether it can be added in a future version.

Christopher,
I guess it's confusing that the usage for cquiver is slightly different from quiver. Sorry about that!

If I understand your example properly, `of` represents the optical flow you wish to display as a 2D array of complex numbers. In that case you should be able to call cquiver like this:

Not working.. error in opening SampleVideo.avi. I tried (.avi) video from own dataset and got error
Undefined function 'gcut' for input arguments of type 'double'.

Error in graphLabel (line 16)
cut = gcut([zeros(2),C;C',P],[1 2]);

Hello Dears,
when I executed this script in Maltab I received this error,
Undefined function 'gcut' for input arguments
of type 'double'.
Error in graphLabel (line 16)
cut = gcut([zeros(2),C;C',P],[1 2]);
Error in extractForeground (line 113)
label =
reshape(graphLabel(alpha*[max(2*significanceThreshold-deviation(:)',0);deviation(:)'],connections),size(deviation));

Error in RUNME (line 29)
fg = extractForeground(frames);

So how can I solve it? Please help me it's so crucial for me to settle that!!
Thanks!

Fabrizio,
As implemented, cquiver and vfcolor can only display a rectangular grid of vectors. Thus the quiver functionality you are looking for is not available. Sorry! I'll consider whether it can be added in a future version.

Dear Nicholas,
I have a problem with using cquiver and vfcolor. I have a map of vectors that I normally display with quiver by giving it as an imput the x and y position of each vector and the x and y components (say quiver(xcoord, ycoord, xcomp, comp)). Rather then the standard quiver plot, I wish to colorcode this map of vectors. What should I give as an input to vfcolor or cquiver?

Fabrizio,
As implemented, cquiver and vfcolor can only display a rectangular grid of vectors. Thus the quiver functionality you are looking for is not available. Sorry! I'll consider whether it can be added in a future version.

Dear Nicholas,
I have a problem with using cquiver and vfcolor. I have a map of vectors that I normally display with quiver by giving it as an imput the x and y position of each vector and the x and y components (say quiver(xcoord, ycoord, xcomp, comp)). Rather then the standard quiver plot, I wish to colorcode this map of vectors. What should I give as an input to vfcolor or cquiver?

Christopher,
I guess it's confusing that the usage for cquiver is slightly different from quiver. Sorry about that!
If I understand your example properly, `of` represents the optical flow you wish to display as a 2D array of complex numbers. In that case you should be able to call cquiver like this:
cquiver(of);

can you give me an working example of the cquiver() function? i don't know how to handle the input arguments.
formally I used Matlabs quiver() function like this:
%read a single frame of a Video file
im = step(hVideoSrc);
%create a rectangular grid
[X Y] = meshgrid(1:1:size(im, 2), 1:1:size(im, 1));
% compute optical flow for the video
%Horizontal and vertical components in %complex form
of = step(hof,im);
%plot a 2-d vector Field
quiver(X(:),real(of(:)),Y(:),imag(of(:)));
This returns a Quiver Plot of the Optical flow between two frames of the Video.
But when I replace the quiver() function With the cquiver function it just returns me the Colorbar, and nothing else.

Comment only