フィルターのクリア

Info

この質問は閉じられています。 編集または回答するには再度開いてください。

how can i zero pad of an image(vein) to make it look like a cylinder

1 回表示 (過去 30 日間)
Oluwatobi Adeyemi
Oluwatobi Adeyemi 2020 年 1 月 23 日
閉鎖済み: MATLAB Answer Bot 2021 年 8 月 20 日
I have an image that i want to pad the volume until it looks like a cylinder! Then when i rotate it by 90 deg it wont look like a lot of long lines but only a lot of short lines.
  2 件のコメント
Nikhil Sonavane
Nikhil Sonavane 2020 年 1 月 29 日
Can you explain your query is a well defined way?
Oluwatobi Adeyemi
Oluwatobi Adeyemi 2020 年 1 月 29 日
i have an MIP image i want to rotate but i want it to look more like a cylinder instead of a line when i rotate it

回答 (1 件)

Nikhil Sonavane
Nikhil Sonavane 2020 年 1 月 30 日
If you have the Image Processing ToolBox you can use the function PADARRAY. For example if I wanted to pad 2 zeroes around the matrix:
A = [1 2; 3 4];
B = [5 6; 7 8];
C = cat(3,A,B); % 3D matrix
D = padarray(C,[3 3 3],0,'both');
If you do not have the toolbox you could work around by by writing a few extra lines of code:
A = [1 2; 3 4];
B = [5 6; 7 8];
C = cat(3,A,B); % 3D matrix
vec= size(C); %Storing the dimensions of the a3d matrix
vec= vec+4; %Increasing the dimensions depending upon the number of zeroes to be padded.
paddedMatrix = zeros(vec); %Creating an empty matrix with new dimensions
paddedMatrix(3:end-2,3:end-2,3:end-2)=C; %Putting C into the empty matrix.
You can also refer to the documentation of Volume Viewer App if it helps resolve your query.
  1 件のコメント
Oluwatobi Adeyemi
Oluwatobi Adeyemi 2020 年 1 月 30 日
the volume viewers app really help thanks

この質問は閉じられています。

タグ

製品


リリース

R2018a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by