[PD] Re: [PD-ot] how low (latency) can you go?

2006-12-19 Thread Mathieu Bouchard

On Tue, 19 Dec 2006, Patco wrote:


Mathieu Bouchard a écrit :
When the latency is changed, the musician has to retrain to a different 
compensation delay, and that's more tiresome than not having to retrain.


Seriously, it's not really a problem to have any amount of latency (even one 
million year) when there is a single musician.


If the musician can concentrate on the fingers rather than what is heard, 
fine (but that needs to be a good player).


However I'm not talking about that. I'm talking about a player trying to 
fit in a group, hopefully with one central sound output or at least sound 
outputs that are close to each other. The player has to keep always the 
same advance; he/she heard the previous notes from other player and needs 
to play something that will fit with what will be heard from those people 
at the time in the future when it'll be played.


 _ _ __ ___ _  _ _ ...
| Mathieu Bouchard - tél:+1.514.383.3801 - http://artengine.ca/matju
| Freelance Digital Arts Engineer, Montréal QC Canada___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


[PD] Re: [PD-ot] how low (latency) can you go?

2006-12-19 Thread Patco

Mathieu Bouchard a écrit :
Seriously, it's not really a problem to have any amount of latency 
(even one million year) when there is a single musician.


If the musician can concentrate on the fingers rather than what is 
heard, fine (but that needs to be a good player).


The musician don't have to concentrate on what is heard at all, at the 
moment he is able to hear what he is playing, but the problem he could 
meet would be about having a mix of his sound and the delayed sound.
However I'm not talking about that. I'm talking about a player trying 
to fit in a group, hopefully with one central sound output or at least 
sound outputs that are close to each other. The player has to keep 
always the same advance; he/she heard the previous notes from other 
player and needs to play something that will fit with what will be 
heard from those people at the time in the future when it'll be played.


That is exactely what I am saying and what involves composition or style 
problems.
The composer could compute himself the latency between each musician and 
beetween instruments groups, or between an orchestra and the director, 
or between the whole thing and the public, even between different 
listening points in the public.

Patco.






___ 
Yahoo! Mail réinvente le mail ! Découvrez le nouveau Yahoo! Mail et son interface révolutionnaire.

http://fr.mail.yahoo.com


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Re: [PD-ot] how low (latency) can you go?

2006-12-17 Thread Charles Henry

I use the cc~ external.  The time domain function is not so efficient
for large sizes, since it's an O(N^2) algorithm.  The freq domain
version uses a fourier algorithm, so it uses only O(N*log(N)).
use [cc~ 1024] for time-domain where +/- 1024 is the bounds of the cc~
use [cc~ f] for one-block at a time measurements in freq. domain
and [cc~ r] for running frequency domain cc~
the frequency domain stuff is actually a cross-covariance, rather than
cross-correlation.
The peak you get from cc~ will not be very clearly defined, because
the loudspeaker has reactive elements, phase shifts, etc
I'm still thinking about the normalization routine to turn the
cross-covariance into a cross-correlation (it doesn't matter if all
you're looking for is a peak).  I'm not sure how to do it yet
I would suggest using the running cc~ with a large enough block size
to cover the latency and sound sources that are much much longer than
that.
You'll probably have to get the latest version from Jamie's flib CVS directory
http://pure-data.cvs.sourceforge.net/pure-data/externals/postlude/flib/src/
The zero location is blocksize/2, so whatever result you get for the
peak, you'll want to subtract blocksize/2.

Chuck


cc_test.pd
Description: Binary data
___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


[PD] Re: [PD-ot] how low (latency) can you go?

2006-12-16 Thread Patco

IOhannes m zmoelnig a écrit :

Hans-Christoph Steiner wrote:
  

Apple puts good audio hardware in their laptops.  I can get 14ms of
latency on Mac OS X with Pd without really trying (I just set it to
14ms).  I can get down to 11ms if I don't mind clicks when I operate the
menus and switch to other applications.



as always when it comes to latency and people tell numbers, i have to
ask my question: have you measured this? how? or was it just putting a
number somewhere and assuming that it's the real latency?
how much load do your settings allow?

  
hello, the lowest latency i could get is with the CCRMA low latency 
kernel patch.

On a cheap internal audio card and an USB midi sport 2*2,
connecting midi in to midi out gives me a latency measure on [timer] 
between 15 and 25 ms with the lowest affordable buffers (about 5ms) as 
far as I remember.

I couldn't make some other tests actually,
and hope it gives some clues...
Best,
Patco.





___ 
Yahoo! Mail réinvente le mail ! Découvrez le nouveau Yahoo! Mail et son interface révolutionnaire.

http://fr.mail.yahoo.com


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Re: [PD-ot] how low (latency) can you go?

2006-12-16 Thread Tim Blechmann
On Sat, 2006-12-16 at 16:21 +0100, Patco wrote:
 IOhannes m zmoelnig a écrit :
  Hans-Christoph Steiner wrote:

  Apple puts good audio hardware in their laptops.  I can get 14ms of
  latency on Mac OS X with Pd without really trying (I just set it to
  14ms).  I can get down to 11ms if I don't mind clicks when I
 operate the
  menus and switch to other applications.
  
 
  as always when it comes to latency and people tell numbers, i have
 to
  ask my question: have you measured this? how? or was it just
 putting a
  number somewhere and assuming that it's the real latency?
  how much load do your settings allow?

from my experience, pd's audio backend is the bigger latency problem
than the audio hardware, especially on osx/windows, where vanilla pd is
using portaudio with pablio, which is unable to get below around 25 ms
of round-trip latency (i guess, hans was referring to one-way latencies)

 hello, the lowest latency i could get is with the CCRMA low latency 
 kernel patch.
 On a cheap internal audio card and an USB midi sport 2*2,
 connecting midi in to midi out gives me a latency measure on [timer] 
 between 15 and 25 ms with the lowest affordable buffers (about 5ms)
 as 

on linux, it's a bit better, but even with wini's alsa implementation,
the least round-trip latency it can produce without audio dropouts is
around 10ms. using it with smaller buffersizes there are severe timing
problems. 

with the callback-driven scheduler and the portaudio implementation from
devel, it's possible to get below 5 ms on all supported platforms,
though.

as for linux, it probably doesn't make any sense to use the rt kernel
patches with vanilla pd, as it's internal bottlenecks are a bigger
problem than the kernel.
and of course, these numbers are without _any_ gui interaction.

hth, tim

--
[EMAIL PROTECTED]ICQ: 96771783
http://www.mokabar.tk

I must say I find television very educational. The minute somebody
turns it on, I go to the library and read a good book.
  Groucho Marx


signature.asc
Description: This is a digitally signed message part
___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


[PD] Re: [PD-ot] how low (latency) can you go?

2006-12-16 Thread Patco

aws a écrit :
I have measured such things precisely when the application required 
it.  Its also fairly trivial to hear the latency by clapping into a 
microphone and monitoring it over headphones after it passes through 
the system.  A 10msec difference is quite audible.


A general method for latency measurement of any system is described in 
this paper:


Matthew Wright, Ryan Cassidy, Michael Zbyszynski, Audio and Gesture 
Latency Measurements on Linux and OSX, Proceedings of ICMC 2004, Miami
or just connect ãudio input to audio output of the soundcard and take a 
measure with some patch magics.






___ 
Yahoo! Mail réinvente le mail ! Découvrez le nouveau Yahoo! Mail et son interface révolutionnaire.

http://fr.mail.yahoo.com


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


[PD] Re: [PD-ot] how low (latency) can you go?

2006-12-16 Thread Patco

Bryan Jurish a écrit :
 since i'm just plain not good enough to compensate before the 
glitches become painfully audible...


marmosets,
  Bryan

It becomes really difficult if you add the latency caused by the the 
sound in air.
I've experience this once I was playing guitar at the control table 
while the speakers was at twenty five meters,
and I can tell that it's more easy to play in those conditions when the 
guitar is directly plugged into the the amplifier,
instead of passing through a soundcard, with some amount of latency, 
that is affordable with headphones.

p





___ 
Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! 
Profitez des connaissances, des opinions et des expériences des internautes sur Yahoo! Questions/Réponses 
http://fr.answers.yahoo.com



___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Re: [PD-ot] how low (latency) can you go?

2006-12-16 Thread Patco

Mathieu Bouchard a écrit :

 Do you have any ideas on how to make it more precise?

maybe with measuring the phase difference between a periodic signal sent 
to DAC and the same received in the ADC instead of timing clicks?
Or guessing the frequency of differencial waves between both signals, 
and then getting the latency with some math magics?
or filling a table with a [phasor~] signal and counting the number of 
samples until the signal in the filled table is != 0 ?








___ 
Yahoo! Mail réinvente le mail ! Découvrez le nouveau Yahoo! Mail et son interface révolutionnaire.

http://fr.mail.yahoo.com


___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list


Re: [PD] Re: [PD-ot] how low (latency) can you go?

2006-12-16 Thread Roman Haefeli
On Sat, 2006-12-16 at 20:38 -0500, Mathieu Bouchard wrote:
 On Sun, 17 Dec 2006, Patco wrote:
  aws a écrit :
  A general method for latency measurement of any system is described in 
  this paper: Matthew Wright, Ryan Cassidy, Michael Zbyszynski, Audio and 
  Gesture Latency Measurements on Linux and OSX, Proceedings of ICMC 
  2004, Miami
 
  or just connect ãudio input to audio output of the soundcard and take a 
  measure with some patch magics.
 
 Exactly. That's what I said a few mails ago. Try 
 doc/7.stuff/tools/latency.pd ... however it doesn't seem to be super 
 precise. Do you have any ideas on how to make it more precise?


the attached patch has sample precision, but it requires some user
interaction to give you a result (and [dirac~] from zexy).

roman
#N canvas 193 337 1249 508 10;
#X obj 148 42 metro 500;
#N canvas 0 0 450 300 (subpatch) 0;
#X array scope 1200 float 2;
#X coords 0 1.3 1200 -1.3 1200 200 1;
#X restore 31 290 graph;
#X obj 148 15 tgl 15 0 empty empty empty 0 -6 0 8 -262144 -1 -1 1 1
;
#X text 404 61 2 start the metro in order to send dirac-impulses;
#X text 405 24 1 shortcut out1 of your soundcard with in1;
#X obj 198 194 dac~ 1;
#X obj 198 214 adc~ 1;
#X obj 147 245 dac~ 2;
#X obj 197 245 tabwrite~ scope;
#X text 170 12 start/stop measurement;
#X text 426 39 ('1' can be replaced by any number);
#X text 401 90 3 adjust the delay \, so that the direct impulse is
synced to the incoming impulse and you hear/see only one impuls.;
#X obj 401 159 loadbang;
#X obj 99 64 dirac~;
#X obj 99 108 delwrite~ latencyemu 100;
#X obj 101 169 delread~ latencyemu;
#X floatatom 101 140 5 0 0 0 - - -;
#X text 182 140 - adjust delay;
#X text 139 140 ms;
#X msg 401 182 \; pd dsp 1 \; scope xticks 0 4.41 10 \;;
#X text 468 274 | 10ms;
#X text 908 274 | 20ms;
#X connect 0 0 8 0;
#X connect 0 0 13 0;
#X connect 2 0 0 0;
#X connect 6 0 7 0;
#X connect 6 0 8 0;
#X connect 12 0 19 0;
#X connect 13 0 5 0;
#X connect 13 0 14 0;
#X connect 15 0 8 0;
#X connect 15 0 7 0;
#X connect 16 0 15 0;
___
PD-list@iem.at mailing list
UNSUBSCRIBE and account-management - 
http://lists.puredata.info/listinfo/pd-list