diff options
author | Willem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl> | 2015-09-16 16:44:10 +0200 |
---|---|---|
committer | Willem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl> | 2015-09-25 15:49:53 +0200 |
commit | c39b12fc42a7254bad1e68cbdb948eee0421ad81 (patch) | |
tree | c585addff5194c30c278ce2f1c0ca7af4af8bc6c /matlab/tools | |
parent | 55cbaa5df6f91594b7cd69754e04c186c7c88c97 (diff) | |
download | astra-c39b12fc42a7254bad1e68cbdb948eee0421ad81.tar.gz astra-c39b12fc42a7254bad1e68cbdb948eee0421ad81.tar.bz2 astra-c39b12fc42a7254bad1e68cbdb948eee0421ad81.tar.xz astra-c39b12fc42a7254bad1e68cbdb948eee0421ad81.zip |
Let astra_create_vol_geom also generate flexible volume geometries
Diffstat (limited to 'matlab/tools')
-rw-r--r-- | matlab/tools/astra_create_vol_geom.m | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/matlab/tools/astra_create_vol_geom.m b/matlab/tools/astra_create_vol_geom.m index ea975e6..a3ba7de 100644 --- a/matlab/tools/astra_create_vol_geom.m +++ b/matlab/tools/astra_create_vol_geom.m @@ -15,6 +15,7 @@ function vol_geom = astra_create_vol_geom(varargin) % vol_geom: MATLAB struct containing all information of the geometry. %-------------------------------------------------------------------------- % vol_geom = astra_create_vol_geom(row_count, col_count, slice_count); +% vol_geom = astra_create_vol_geom(row_count, col_count, slice_count, min_x, max_x, min_y, max_y, min_z, max_z); % % Create a 3D volume geometry. See the API for more information. % row_count: number of rows. @@ -93,4 +94,18 @@ elseif numel(varargin) == 3 vol_geom.GridRowCount = varargin{1}; vol_geom.GridColCount = varargin{2}; vol_geom.GridSliceCount = varargin{3}; + +% astra_create_vol_geom(row_count, col_count, slice_count, min_x, max_x, min_y, max_y, min_z, max_z) +elseif numel(varargin) == 9 + vol_geom = struct(); + vol_geom.GridRowCount = varargin{1}; + vol_geom.GridColCount = varargin{2}; + vol_geom.GridSliceCount = varargin{3}; + vol_geom.option.WindowMinX = varargin{4}; + vol_geom.option.WindowMaxX = varargin{5}; + vol_geom.option.WindowMinY = varargin{6}; + vol_geom.option.WindowMaxY = varargin{7}; + vol_geom.option.WindowMinZ = varargin{8}; + vol_geom.option.WindowMaxZ = varargin{9}; + end |