diff options
author | leochanj <jbakita@cs.unc.edu> | 2020-10-21 01:52:54 -0400 |
---|---|---|
committer | leochanj <jbakita@cs.unc.edu> | 2020-10-21 01:52:54 -0400 |
commit | 25d94aa8aabb8ac3e8bbea0bc439ea6148444cc8 (patch) | |
tree | ba80e76d25d9ca9486092e2f6b6d76f0e3352bf7 /SD-VBS/benchmarks/texture_synthesis/src/matlab/expand.m | |
parent | e2b50015cebdfba68699abd6e8575e38230f5a78 (diff) |
debug libextra and remove matlab
Diffstat (limited to 'SD-VBS/benchmarks/texture_synthesis/src/matlab/expand.m')
-rwxr-xr-x | SD-VBS/benchmarks/texture_synthesis/src/matlab/expand.m | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/SD-VBS/benchmarks/texture_synthesis/src/matlab/expand.m b/SD-VBS/benchmarks/texture_synthesis/src/matlab/expand.m deleted file mode 100755 index 5f6e4d9..0000000 --- a/SD-VBS/benchmarks/texture_synthesis/src/matlab/expand.m +++ /dev/null | |||
@@ -1,34 +0,0 @@ | |||
1 | function te = expand(t,f) | ||
2 | |||
3 | % Expand spatially an image t in a factor f | ||
4 | % in X and in Y. | ||
5 | % t may be complex. | ||
6 | % It fills in with zeros in the Fourier domain. | ||
7 | % te = expand(t, f) | ||
8 | % See also: shrink.m | ||
9 | % JPM, May 95, Instituto de Optica, CSIC, Madrid. | ||
10 | |||
11 | [my mx]=size(t); | ||
12 | my=f*my; | ||
13 | mx=f*mx; | ||
14 | Te=zeros(my,mx); | ||
15 | T=f^2*fftshift(fft2(t)); | ||
16 | y1=my/2+2-my/(2*f); | ||
17 | y2=my/2+my/(2*f); | ||
18 | x1=mx/2+2-mx/(2*f); | ||
19 | x2=mx/2+mx/(2*f); | ||
20 | Te(y1:y2,x1:x2)=T(2:my/f,2:mx/f); | ||
21 | Te(y1-1,x1:x2)=T(1,2:mx/f)/2; | ||
22 | Te(y2+1,x1:x2)=((T(1,mx/f:-1:2)/2)').'; | ||
23 | Te(y1:y2,x1-1)=T(2:my/f,1)/2; | ||
24 | Te(y1:y2,x2+1)=((T(my/f:-1:2,1)/2)').'; | ||
25 | esq=T(1,1)/4; | ||
26 | Te(y1-1,x1-1)=esq; | ||
27 | Te(y1-1,x2+1)=esq; | ||
28 | Te(y2+1,x1-1)=esq; | ||
29 | Te(y2+1,x2+1)=esq; | ||
30 | Te=fftshift(Te); | ||
31 | te=ifft2(Te); | ||
32 | if all(imag(t)==0), | ||
33 | te = real(te); | ||
34 | end | ||