function [C,D,tc]=clarity_nzox(y,fs,T,N)
% T: ms-ben
% A BEMENETRE TERJEDESI KESLELTETES NELKULI IMPULZUSVALASZ KELL!!

pnter=T*fs/1000;

y1=y(1:pnter);
y2=y(pnter+1:end);

yo=ox(y,fs,N); y1o=ox(y1,fs,N); y2o=ox(y2,fs,N);
t=(0:length(y.^2)-1)/fs;

for i=1:10*N,
    Ee=sum(y1o(i,:).^2);
    El=sum(y2o(i,:).^2);
    Eo=sum(yo(i,:).^2);
    
    C(i)=10*log10(Ee/El);
    D(i)=100*(Ee/Eo);
    tc(i)= sum(yo(i,:).^2.*t)./Eo;
end;