Re: [PD] change variables in struct?

2023-05-10 Thread Miller Puckette
I believe that if you change the name of a variable in a "struct" object 
it will keep all the existing data fields under the new names, even 
reordering the fields as appropriate.  OTOH I haven't tested this 
recently, so try it and report back if it fails somehow :)


cheers

Miller

On 5/11/23 03:00, Forrest Curo wrote:
If I want to use a working example struct (from the datastructures 
help patches) I can readily change the values of the variables it uses.


What about changing the names of those variables to something more 
meaningful for their use in a new structure? Will I need to construct 
the dreadful patch from scratch?


Forrest Curo
San Diego

___
Pd-list@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> 
https://urldefense.com/v3/__https://lists.puredata.info/listinfo/pd-list__;!!Mih3wA!EBJnzugYe70vhyPI6OOmwy1aGFgX5CuAUwshaSfYNUt20LReBvIczt0I2ANmyFp04zwnWUBZ8_q9f0Wc$




___
Pd-list@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> 
https://lists.puredata.info/listinfo/pd-list


Re: [PD] Audio latency on linux

2023-05-10 Thread Peter P.
Orm, 
you might wanna see if running your interface in 96kHz will halve the
latency further.
best, P



___
Pd-list@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> 
https://lists.puredata.info/listinfo/pd-list


[PD] change variables in struct?

2023-05-10 Thread Forrest Curo
If I want to use a working example struct (from the datastructures help
patches) I can readily change the values of the variables it uses.

What about changing the names of those variables to something more
meaningful for their use in a new structure? Will I need to construct the
dreadful patch from scratch?

Forrest Curo
San Diego
___
Pd-list@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> 
https://lists.puredata.info/listinfo/pd-list


Re: [PD] update on Gem for Apple Silicon?

2023-05-10 Thread Andrew Lyons
Open GL is pretty much dead, and as I understand it, Gem is built on Open
GL. Apple deprecated OpenGL years ago, and it will be removed at some
point. Metal is the API for Apple these days, and Vulkan is the open source
replacement for Open GL. No idea if Gem will move to either of these.

https://venturebeat.com/games/apple-defends-end-of-opengl-as-mac-game-developers-threaten-to-leave/#:~:text=For%20now%2C%20Apple%20is%20deprecating,on%20devices%20with%20older%20OSes
.



On Wed, May 10, 2023, 3:29 PM John Harrison 
wrote:

> We're approaching 3 years now since Apple released the M1 and there's no
> Gem available for distribution on Apple Silicon that I'm aware of. I'm not
> finding a lot of conversation about it on this list and when searching in
> the Gem-dev list I found nothing.
>
> I tried compiling Gem for Apple Silicon myself and to my surprise it
> compiled and ran. There are some issues though. I didn't test
> thoroughly but quickly playing with some examples I saw artifacts when
> playing videos and general choppiness.
>
> Is Gem for Apple Silicon on anybody's radar? I'm up for being part of a
> team to get Gem on Apple Silicon if there's interest.
>
> --
> John
> https://johnharrison.cc
> ___
> Pd-list@lists.iem.at mailing list
> UNSUBSCRIBE and account-management ->
> https://lists.puredata.info/listinfo/pd-list
>
___
Pd-list@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> 
https://lists.puredata.info/listinfo/pd-list


Re: [PD] Audio latency on linux

2023-05-10 Thread Roman Haefeli
On Wed, 2023-05-10 at 19:04 +0200, Orm Finnendahl wrote:
> 
> jack_delay reports a 9.6 ms roundtrip delay through the analog
> outputs
> with a vector size of 64, so it is not the driver and in principle
> should be possible to get a lower latency in linux.

When using -callback (as Christof already suggested), you should get
exactly the same latency as measured by jack_delay. And in my
experience, that is indeed the case. 

While using the callback scheduler,  Pd used to hang after switching
audio backends. This is fixed in the Christof's scheduler_fix PR¹. I
hope this gets merged soonish. 

Roman

¹https://github.com/pure-data/pure-data/pull/1756 


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


[PD] update on Gem for Apple Silicon?

2023-05-10 Thread John Harrison
We're approaching 3 years now since Apple released the M1 and there's no
Gem available for distribution on Apple Silicon that I'm aware of. I'm not
finding a lot of conversation about it on this list and when searching in
the Gem-dev list I found nothing.

I tried compiling Gem for Apple Silicon myself and to my surprise it
compiled and ran. There are some issues though. I didn't test
thoroughly but quickly playing with some examples I saw artifacts when
playing videos and general choppiness.

Is Gem for Apple Silicon on anybody's radar? I'm up for being part of a
team to get Gem on Apple Silicon if there's interest.

-- 
John
https://johnharrison.cc
___
Pd-list@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> 
https://lists.puredata.info/listinfo/pd-list


Re: [PD] Audio latency on linux

2023-05-10 Thread Andrew Lyons
There is such a thing as a "low latency Linux kernel" as well. It's what AV
Linux , and Ubuntu Studio use. It's a special build for real time audio
work apparently.



On Wed, May 10, 2023, 10:23 AM Orm Finnendahl <
orm.finnend...@selma.hfmdk-frankfurt.de> wrote:

> Hi,
>
>  I found it: The delay setting in the audio settings is the culprit:
> It was set at 25 ms and setting is to 0 ms will reduce the latency.
>
> Sorry for the noise...
>
> --
> Orm
>
>
>
>
>
> ___
> Pd-list@lists.iem.at mailing list
> UNSUBSCRIBE and account-management ->
> https://lists.puredata.info/listinfo/pd-list
>
>
>
>
> ___
> Pd-list@lists.iem.at mailing list
> UNSUBSCRIBE and account-management ->
> https://lists.puredata.info/listinfo/pd-list
>
___
Pd-list@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> 
https://lists.puredata.info/listinfo/pd-list


Re: [PD] Audio latency on linux

2023-05-10 Thread Christof Ressi

Hi,


I found it: The delay setting in the audio settings is the culprit:
It was set at 25 ms and setting
If you want to reduce latency even more, try to enable "callbacks" in 
the audio settings (or start Pd with the "-callback" option). Generally, 
this is not recommend, unless you really need the lowest possible latency.

I even tried to compile pd with a lower blocksize

To anyone reading: don't try this at home!

Christof

On 10.05.2023 19:04, Orm Finnendahl wrote:

Hi,

  for a project involving controlled and tuned feedback through the
Audio Interface, we need very low latency (~ 9-10 ms roundtrip through
the analog ins/outs) for it to work properly. We did some tests using
OSX and linux based systems with different audio interfaces.

On OSX I can get down to 16 ms with pd (44.1 kHz sr); using Max/MSP we
can get below 10ms with a vector size of 32.

On Linux the lowest I can get with pd is 29.33 ms with 48k samplerate
(this is using alsa; jack is ~34 ms).

jack_delay reports a 9.6 ms roundtrip delay through the analog outputs
with a vector size of 64, so it is not the driver and in principle
should be possible to get a lower latency in linux. I don't know if
jack_delay is implemented with additional i/o buffers but even if pd
adds an extra period in both directions that should be well below 30ms
(64 samples are 1.33 ms at 48k). The added 20ms in comparison to
jack_delay appear quite large to me.

I even tried to compile pd with a lower blocksize (I changed
DEFDACBLKSIZE in s_stuff.h and DEFSENDVS in d_global.c and can get
down to a vectorsize of 32 without distortion at the audio interface),
but that doesn't change the i/o latency at all. I didn't yet study the
alsa/jack related code.

Can anyone shed a light on this? It'd be much nicer to use pd for this
than writing a dedicated app doing all the dsp (or using Max/MSP on
OSX :-(

--
Orm





___
Pd-list@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> 
https://lists.puredata.info/listinfo/pd-list




___
Pd-list@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> 
https://lists.puredata.info/listinfo/pd-list


[PD] Audio latency on linux

2023-05-10 Thread Orm Finnendahl
Hi,

 I found it: The delay setting in the audio settings is the culprit:
It was set at 25 ms and setting is to 0 ms will reduce the latency.

Sorry for the noise...

--
Orm





___
Pd-list@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> 
https://lists.puredata.info/listinfo/pd-list




___
Pd-list@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> 
https://lists.puredata.info/listinfo/pd-list


[PD] Audio latency on linux

2023-05-10 Thread Orm Finnendahl
Hi,

 for a project involving controlled and tuned feedback through the
Audio Interface, we need very low latency (~ 9-10 ms roundtrip through
the analog ins/outs) for it to work properly. We did some tests using
OSX and linux based systems with different audio interfaces.

On OSX I can get down to 16 ms with pd (44.1 kHz sr); using Max/MSP we
can get below 10ms with a vector size of 32.

On Linux the lowest I can get with pd is 29.33 ms with 48k samplerate
(this is using alsa; jack is ~34 ms).

jack_delay reports a 9.6 ms roundtrip delay through the analog outputs
with a vector size of 64, so it is not the driver and in principle
should be possible to get a lower latency in linux. I don't know if
jack_delay is implemented with additional i/o buffers but even if pd
adds an extra period in both directions that should be well below 30ms
(64 samples are 1.33 ms at 48k). The added 20ms in comparison to
jack_delay appear quite large to me.

I even tried to compile pd with a lower blocksize (I changed
DEFDACBLKSIZE in s_stuff.h and DEFSENDVS in d_global.c and can get
down to a vectorsize of 32 without distortion at the audio interface),
but that doesn't change the i/o latency at all. I didn't yet study the
alsa/jack related code.

Can anyone shed a light on this? It'd be much nicer to use pd for this
than writing a dedicated app doing all the dsp (or using Max/MSP on
OSX :-(

--
Orm





___
Pd-list@lists.iem.at mailing list
UNSUBSCRIBE and account-management -> 
https://lists.puredata.info/listinfo/pd-list