Mercurial > hg > ishara
view general/funutils/bind1.m @ 61:eff6bddf82e3 tip
Finally implemented perceptual brightness thing.
author | samer |
---|---|
date | Sun, 11 Oct 2015 10:20:42 +0100 |
parents | fbc0540a9208 |
children |
line wrap: on
line source
% bind1 - Bind arguments to a function using Matlab closure % % bind1 :: % func(A{1}, ..., A{N}->B{1:L}) ~'func from N inputs to L outputs', % A{1}, ..., A{M} ~'M<=N input arguments of the correct types' % -> func(A{M+1}, ..., A{N}->B{1:L}) ~'func from remaining arguments to returns'. function g=bind1(f,varargin) args=varargin; g=@(varargin)f(args{:},varargin{:}); end