summaryrefslogtreecommitdiffstats
path: root/matlab/tools/downsample_sinogram.m
blob: 1fb4ec8e2cf4779f7c30c3371783264302864983 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
function sinogram_out = downsample_sinogram(sinogram, ds)

	if ds == 1
		sinogram_out = sinogram;
		return;
	end

	sinogram_out = sinogram(:,1:ds:end,:);
	for i = 2:ds
		sinogram_out = sinogram_out + sinogram(:,i:ds:end,:);
	end
	sinogram_out = sinogram_out / (ds*ds);