Image box or rectangle color

I want to drag a rectangle on image and set color of edges of rectangle. How to start?

 Respuesta aceptada

Khalid Mahmood
Khalid Mahmood el 29 de Mayo de 2021

1 voto

I hope you want this
set(gcf,'Units','normalized')
im=imread('peppers.png');
imshow(im);
k = waitforbuttonpress;
rect_pos = rbbox;
annotation('rectangle',rect_pos,'Color','red')

2 comentarios

Nasir Ali
Nasir Ali el 29 de Mayo de 2021
It worked. I will contact you on email for further help
Khalid Mahmood
Khalid Mahmood el 29 de Mayo de 2021
I will try best to help you

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Image Processing Toolbox en Centro de ayuda y File Exchange.

Productos

Preguntada:

el 29 de Mayo de 2021

Comentada:

el 29 de Mayo de 2021

Community Treasure Hunt

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

Start Hunting!

Translated by