From: M Paheerathan on 23 Jul 2010 01:10 When I select points in an image, I would like to drag the image and select the points, but if I drag the image, I couldn't continue with ginput I need a solution for that for example say I would like to select 10 points by using ginput. after selecting 5 points I would like to drag the image and then would like to select remaining 5 points Thank you, Best Regards, Paheerathan
From: exosceleton on 23 Jul 2010 01:30 "M Paheerathan" <mp.mscproject(a)yahoo.com> wrote in message <i2b87e$jal$1(a)fred.mathworks.com>... > When I select points in an image, I would like to drag the image and select the points, but if I drag the image, I couldn't continue with ginput > > I need a solution for that > > for example say I would like to select 10 points by using ginput. after selecting 5 points I would like to drag the image and then would like to select remaining 5 points > > > > Thank you, > > > > Best Regards, > Paheerathan try using the "button" third argument of ginput. selecting point with the left button, scrolling with the right. (i don't think you can drag, but just to pan between 2 right mouse clicks)
From: M Paheerathan on 23 Jul 2010 01:48 Dear exosceleton, I need what you mentioned. I would like to pan it in between the point selection. Please provide me a sample code. When I selecting the point pan is disabled. How to make it enabled? Thanks, Regards Pahee "exosceleton" <exosceleton(a)hotmail.com> wrote in message <i2b9df$2th$1(a)fred.mathworks.com>... > "M Paheerathan" <mp.mscproject(a)yahoo.com> wrote in message <i2b87e$jal$1(a)fred.mathworks.com>... > > When I select points in an image, I would like to drag the image and select the points, but if I drag the image, I couldn't continue with ginput > > > > I need a solution for that > > > > for example say I would like to select 10 points by using ginput. after selecting 5 points I would like to drag the image and then would like to select remaining 5 points > > > > > > > > Thank you, > > > > > > > > Best Regards, > > Paheerathan > > try using the "button" third argument of ginput. > selecting point with the left button, scrolling with the right. > (i don't think you can drag, but just to pan between 2 right mouse clicks)
From: exosceleton on 23 Jul 2010 04:09 it's not a solution it is more a workaround; use left and right mousebuttons %%%%%%%%% clear all h1=figure; load mandrill imagesc(X) colormap(map) done=0; i=1; while done==0 [x,y,button]=ginput(1); if button==1 Xarray(i)=x; Yarray(i)=y; i=i+1; else XL=xlim; YL=ylim; xlim([x-((XL(2)-XL(1))/2) x+((XL(2)-XL(1))/2)]); ylim([y-((YL(2)-YL(1))/2) y+((YL(2)-YL(1))/2)]); end if i==10 done=1; end end Xarray Yarray %%%%%%%%%%%%%%%%%%%%%%%%%
From: exosceleton on 23 Jul 2010 04:14 It's not a solution, it's more a workaround use your left and right mouse buttons %%%%%%%%%%%%%%%%%%% clear all h1=figure; load mandrill imagesc(X) colormap(map) done=0; i=1; while done==0 [x,y,button]=ginput(1); if button==1 Xarray(i)=x; Yarray(i)=y; i=i+1; else XL=xlim; YL=ylim; xlim([x-((XL(2)-XL(1))/2) x+((XL(2)-XL(1))/2)]); ylim([y-((YL(2)-YL(1))/2) y+((YL(2)-YL(1))/2)]); end if i==10 done=1; end end Xarray Yarray %%%%%%%%%%%%%%%%%%%%%%%%%%%
|
Pages: 1 Prev: Find position of number in matrix Next: Vectorization help |