0

I'm working on CBIR, in my GUI I've 6 axes one for query image 5 for resulted images. For displaying images on axes my code is

function displayResults(filename,hObject, eventdata, handles)
% Open 'filename' file... for reading...
fid = fopen(filename);
for N=6:1:10
    imagename = fgetl(fid);
    if ~ischar(imagename), break, end       % Meaning: End of File...
    x=imread(imagename);
    axes(handles.(sprintf('axes%d', N)));
    imshow(x)
    xlabel(imagename);  
end
fclose(fid);

and calling function is in pushbutton function Texture_Callback(hObject, eventdata, handles). calling function is displayResults('textureResults.txt',hObject, eventdata, handles);

this is my output window before

![before pressing pushbutton](http://s1273.photobucket.com/user/Chethan_tv/media/fig5_zps64ca6452.jpg.html?sort=3&o=1)

after pressing pushbutton

![final output](http://s1273.photobucket.com/user/Chethan_tv/media/fig5_zps98c96f8f.jpg.html?sort=3&o=0)

What just happened to image quality?

Chethan
  • 213
  • 3
  • 7
  • 19
  • Before using above code i was getting clear images, but that was not a GUI window, instead just a figure window. any thing wrong in called function? – Chethan May 03 '13 at 07:21
  • 1
    I would be tempted to point the finger at the `imshow` function here - I don't think it's meant for use outside your normal "figure" environment. Another potential candidate looks like that call to `axes`. Perhaps you could try drawing it with `image(x, 'Parent', handles.(sprintf('axes%d', N)))` - does that help? – wakjah May 03 '13 at 08:02
  • Well, slightly it is working even some images are not clear. . `![output](http://s1273.photobucket.com/user/Chethan_tv/media/fig_zps761bcc6d.jpg.html)` also how did map values(x and y axis values) come from? – Chethan May 03 '13 at 11:35
  • The link you provided gives file not found – wakjah May 03 '13 at 12:20
  • `(http://s1273.photobucket.com/user/Chethan_tv/media/fig_zpsa48de802.jpg.html?sort=3&o=0)` – Chethan May 03 '13 at 14:46
  • Are you absolutely sure that that's **not** what the original images look like? There is nothing in the code you posted that should distort your data... or do anything to it, in fact, apart from display it. – wakjah May 03 '13 at 15:09
  • yeah, in output side first image is clear and other 4 images should look like that. Don't know what had happened, Then which part of my code is wrong...! How to remove that map values? – Chethan May 03 '13 at 16:17

0 Answers0