Info
Questa domanda è chiusa. Riaprila per modificarla o per rispondere.
display img from function in gui
2 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
i have main code with gui hendles and i display img somehow like that:
axes(handles.axes18);
imshow(ObrazSzary);
but now i have a separate function that i use in my main program
function [ o_str ] = ocr1( img )
pre procesing img
ocr
o_str=word
end
now i want do display pre procesinf of img in specifinc axes , but there is no hendles for axes how i can do that????
0 Commenti
Risposte (1)
Geoff Hayes
il 11 Gen 2015
Lukasz - if you want the image from the pre-processing part of the ocr1 function to appear in a specific axes, then pass the axes handle into the function. Just change your function signature to
function [ o_str ] = ocr1(img, preProcImgAxesHandle)
and then when you have the pre-processed image to display, just do
imshow(preProcImg,'Parent', preProcImgAxesHandle);
and the pre-processed image, preProcImg, will be shown on the axes that is represented by the preProcImgAxesHandle handle.
In your GUI, you would call this function as (for example)
ocr1(img,handles.axes18)
Try making the above change and see what happens!
0 Commenti
Questa domanda è chiusa.
Vedere anche
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!