How to use imellipse for GUI?
조회 수: 2 (최근 30일)
이전 댓글 표시
Hi there,I'd like to extract a ellipse-like roi area, but the "imellipse" I noticed cannot include the theta angle, so I wonder if there is any solution so that an ellipse roi with user-defined theta&major axis&minor axis can be extracted. Or is there any function with circle-roi extraction and the circle can be transformed into an ellipse? Thanks! By the way, when I use the "imellipse" function in matlab 2012a, there are some errors, and the code i use for "imellipse" is the same as that in "imfreehand"(run successfully), so can anyone help me with this, thanks a lot. The code is as follows:
h_qupur = imfreehand(gca);
position_qupur = wait(h_qupur);
qupur_mask = createMask(h_qupur);
when the first line is placed by "h = imellipse(gca)" the errors appear:
Error: File: interp1q.m Line: 1 Column: 25 The input character is not valid in MATLAB statements or expressions.
Error in ellipseToPolygon (line 68) ts = interp1q(S(:),t(:),(1:(N-1))')';
Error in getEllipseVertices (line 20) [x,y] = ellipseToPolygon(a,b,cx,cy,delta);
Error in ellipseSymbol/updateView (line 157) vert = getEllipseVertices(h_axes,position);
Error in imrect>imrectAPI/updateView (line 432) draw_api.updateView(pos);
Error in imrect>imrectAPI/setPosition (line 376) updateView(position);
Error in imrect>imrectAPI/placeRect (line 350) setPosition([x_init y_init 0 0]);
Error in manageInteractivePlacement/buttonDownPlaceObject (line 206) completed = placementFcn(x_init,y_init);
Error in iptaddcallback/callbackProcessor (line 149) fun(varargin{:});
Error using waitfor Error while evaluating figure WindowButtonDownFcn
Error: File: interp1q.m Line: 1 Column: 25 The input character is not valid in MATLAB statements or expressions.
Error in ellipseToPolygon (line 68) ts = interp1q(S(:),t(:),(1:(N-1))')';
Error in getEllipseVertices (line 20) [x,y] = ellipseToPolygon(a,b,cx,cy,delta);
Error in ellipseSymbol/updateView (line 157) vert = getEllipseVertices(h_axes,position);
Error in imrect>imrectAPI/updateView (line 432) draw_api.updateView(pos);
Error in imrect>imrectAPI (line 300) updateView(position);
Error in imrect (line 83) [h_group,draw_api] = imrectAPI(varargin{:});
Error in imellipse (line 89) obj = obj@imrect(varargin{:},'DrawAPI',ellipseSymbol());
Error in VOG_mice (line 45) h_qupur = imellipse(gca);
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Particle Swarm에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!