Csound Csound-dev Csound-tekno Search About

[Csnd] pconvolve latency in samples

Date2019-07-13 23:51
FromDave Seidel
Subject[Csnd] pconvolve latency in samples
I know how to calculate the latency of pconvolve in seconds:

  idel = (ksmps < ipartsize ? ipartsize + ksmps : ipartsize) / sr

But how can I get the latency in terms of the number of samples? I prefer to to convolve soundfiles with a 100% wet output, and then mix the original (dry) soundfile with the convolved (wet) soundfile separately so I can adjust the balance, but that requires dealing with the latency difference between the files. I can do that in Audacity based on fractional seconds, but it seems like using an exact number of samples (Audacity supports this as well) would be more accurate.
Csound mailing list Csound@listserv.heanet.ie https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND Send bugs reports to https://github.com/csound/csound/issues Discussions of bugs and features can be posted here

Date2019-07-14 00:20
FromVictor Lazzarini
SubjectRe: [Csnd] pconvolve latency in samples
If you don't divide by the sr, the value is given in samples. Is that what you asked?

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 14 Jul 2019, at 00:52, Dave Seidel <dave.seidel@gmail.com> wrote:

I know how to calculate the latency of pconvolve in seconds:

  idel = (ksmps < ipartsize ? ipartsize + ksmps : ipartsize) / sr

But how can I get the latency in terms of the number of samples? I prefer to to convolve soundfiles with a 100% wet output, and then mix the original (dry) soundfile with the convolved (wet) soundfile separately so I can adjust the balance, but that requires dealing with the latency difference between the files. I can do that in Audacity based on fractional seconds, but it seems like using an exact number of samples (Audacity supports this as well) would be more accurate.
Csound mailing list Csound@listserv.heanet.ie https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND Send bugs reports to https://github.com/csound/csound/issues Discussions of bugs and features can be posted here

Date2019-07-14 01:02
FromDave Seidel
SubjectRe: [Csnd] pconvolve latency in samples
Ah, I should have realized that it was as simple as that! Thanks, Victor. 

On Sat, Jul 13, 2019, 7:21 PM Victor Lazzarini <Victor.Lazzarini@mu.ie> wrote:
If you don't divide by the sr, the value is given in samples. Is that what you asked?

Victor Lazzarini
Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland

On 14 Jul 2019, at 00:52, Dave Seidel <dave.seidel@gmail.com> wrote:

I know how to calculate the latency of pconvolve in seconds:

  idel = (ksmps < ipartsize ? ipartsize + ksmps : ipartsize) / sr

But how can I get the latency in terms of the number of samples? I prefer to to convolve soundfiles with a 100% wet output, and then mix the original (dry) soundfile with the convolved (wet) soundfile separately so I can adjust the balance, but that requires dealing with the latency difference between the files. I can do that in Audacity based on fractional seconds, but it seems like using an exact number of samples (Audacity supports this as well) would be more accurate.
Csound mailing list Csound@listserv.heanet.ie https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND Send bugs reports to https://github.com/csound/csound/issues Discussions of bugs and features can be posted here
Csound mailing list Csound@listserv.heanet.ie https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND Send bugs reports to https://github.com/csound/csound/issues Discussions of bugs and features can be posted here
Csound mailing list Csound@listserv.heanet.ie https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND Send bugs reports to https://github.com/csound/csound/issues Discussions of bugs and features can be posted here