Skip to content

Commit

Permalink
bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
kouichi-c-nakamura committed Aug 4, 2023
1 parent 4de3d02 commit f522cf9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Browsing Functions/AtlasTransformBrowser.m
Original file line number Diff line number Diff line change
Expand Up @@ -779,8 +779,9 @@ function hotkeyFcn(f, slice_figure, keydata, allData, save_location, save_suffix
disp('atlas location saved')

% save transformed histology image
current_slice_image = imread(fullfile(save_location, [slice_name '.tif']));
% current_slice_image = flip(get(ud_slice.im, 'CData'),1);
% current_slice_image = imread(fullfile(save_location, [slice_name '.tif']));%TODO no imreisze() used, size mismatch creates a huge error in transform
current_slice_image = flip(get(ud_slice.im, 'CData'),1);

R = imref2d(size(ud.ref));
curr_slice_trans = imwarp(current_slice_image, ud.transform, 'OutputView',R);
imwrite(curr_slice_trans, fullfile(folder_transformations, [slice_name '_transformed.tif']))
Expand Down

0 comments on commit f522cf9

Please sign in to comment.