필터 지우기
필터 지우기

How to draw a line on the axis using user click

조회 수: 1 (최근 30일)
Brenda FOCHIVÉ
Brenda FOCHIVÉ 2020년 6월 2일
댓글: darova 2020년 6월 14일
I have written designed GUI, on my interface there is an axes. I designed my program such that the user can plot specific points.
I want that when the user clicks on a point it should start a line and as the user is moving arround the axes, the cursor should drag the line until the user clicks on another point to end the line.
I gave to my point a button down function, when the user clicks i can get the coordinates of the point but i don't know how to get the position of the cursor and draw and interactive line. I know i have to get the current point and there's a function for that in MATLAB but I don't know how to use it. I am using R2018b.
Please for help
  댓글 수: 1
darova
darova 2020년 6월 14일
You have to write your own code? What about imline?

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Visual Exploration에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by