When you perform an operation on the image in one the callback functions, you should store the result back in the handles
structure where you obtained the image. That way the next time a callback function executes, it will obtain the modified image.
function pushbutton3_Callback(hObject, eventdata, handles)
%# get the image from the handles structure
img = handles.im;
%# process the image in some way and show the result
img = rgb2gray(img);
himage = imshow(img, 'Parent', handles.axes1);
%# store the image back in the structure
handles.im = img;
guidata(hObject, handles);
end