https://bitbucket.org/daniel_fort/magic-lantern
Raw File
Tip revision: 2876812f07b869d421fa68755e62a324170e5791 authored by a1ex on 21 May 2014, 05:28:48 UTC
Close branch ime
Tip revision: 2876812
defish-lut.m
#!/usr/bin/env octave3.2

prefix = argv(){1};

xy = double(imread([prefix ".tif"]));

f = fopen([prefix ".lut"], "wb")
for i = 1:480/2
	for j = 1:720/2
		fwrite(f, [xy(i,j), xy(481-i,721-j)], 'uint8');
	end
end
fclose(f)
back to top