I've got 10 grayscale images. I'd like to plot a simple YELLOW line over each image separately, then show them all over one plot (montage style).
I tried to draw all images first, but that made plotting lines very tricky (X,Y axes weren't standard for plotting over each separate image).
I thought about burning the line over the image, but I don't have the computer vision toolkit (easy functions to do this), otherwise it seemed complicated to both convert the grayscale to color and get it to burn the image.
I thought I might be able to use the function newplot
to create a temporary plot space for each image, draw the line with a simple plot(...) call, then save it and just montage(...)
all the individual plots at the end.
Is this possible? I've never played with the function newplot
or tried to loop through individual plots, saving them up for a call to montage(...)
this way, but it seems like a logical/simple approach.
line
to draw a line in a figure window. You just need to be aware that they
axis is positivey
-down when showing an image withimshow
. – rayryeng