<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[sampling rate impacting sound]]></title><description><![CDATA[<p>I have read that the lower the sampling rate the lower will be the frequency of the sampled signal (since the resulting signal has been sampled with greater distances), but can't understand why the frequency of a [osc~ 440] will get higher if i lower the sampling rate in the Media &gt; Audio Settings, and it sounds lower if i choose a higher sampling rate.<br />
Can anyone explain why is this happening?</p>
<p>PS:  Now i have tested something else which is strange for me:<br />
With the following patch:</p>
<p><img src="/uploads/files/1488307231397-screenshot.png" alt="Screenshot.png" class="img-responsive img-markdown" /></p>
<p>if i click on the Media &gt; Audio Settings &gt; Apply key:</p>
<p><img src="/uploads/files/1488307374748-screenshot-1.png" alt="Screenshot-1.png" class="img-responsive img-markdown" /></p>
<p>The frequency gets higher, and when i save the patch the frequency will be 440 Hz. again.<br />
I would be very thankful for any explanations about these two things.</p>
]]></description><link>http://forum.pdpatchrepo.info/topic/10610/sampling-rate-impacting-sound</link><generator>RSS for Node</generator><lastBuildDate>Sun, 10 May 2026 08:12:52 GMT</lastBuildDate><atom:link href="http://forum.pdpatchrepo.info/topic/10610.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 28 Feb 2017 18:46:12 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to sampling rate impacting sound on Tue, 28 Feb 2017 18:46:12 GMT]]></title><description><![CDATA[<p>I have read that the lower the sampling rate the lower will be the frequency of the sampled signal (since the resulting signal has been sampled with greater distances), but can't understand why the frequency of a [osc~ 440] will get higher if i lower the sampling rate in the Media &gt; Audio Settings, and it sounds lower if i choose a higher sampling rate.<br />
Can anyone explain why is this happening?</p>
<p>PS:  Now i have tested something else which is strange for me:<br />
With the following patch:</p>
<p><img src="/uploads/files/1488307231397-screenshot.png" alt="Screenshot.png" class="img-responsive img-markdown" /></p>
<p>if i click on the Media &gt; Audio Settings &gt; Apply key:</p>
<p><img src="/uploads/files/1488307374748-screenshot-1.png" alt="Screenshot-1.png" class="img-responsive img-markdown" /></p>
<p>The frequency gets higher, and when i save the patch the frequency will be 440 Hz. again.<br />
I would be very thankful for any explanations about these two things.</p>
]]></description><link>http://forum.pdpatchrepo.info/topic/10610/sampling-rate-impacting-sound</link><guid isPermaLink="true">http://forum.pdpatchrepo.info/topic/10610/sampling-rate-impacting-sound</guid><dc:creator><![CDATA[amirt]]></dc:creator><pubDate>Tue, 28 Feb 2017 18:46:12 GMT</pubDate></item><item><title><![CDATA[Reply to sampling rate impacting sound on Wed, 01 Mar 2017 09:02:56 GMT]]></title><description><![CDATA[<p>Not entirely sure about the math of the whole thing, but what I know is that when you use Jack as your audio server, you don't change your audio setting in Pd, but only in Jack.<br />
Check this, start Jack (in the image you posted, the sampling rate is at 48KHz), then start Pd and open its audio settings. Most likely it will read a 44.1KHz sampling rate. Don't change that, open a new patch and put a [samplerate~] connected to a [print]. Bang it and see what it prints. It should print 48000 and NOT 44100. This is because Jack's sampling rate is at 48000 and that's the sampling rate Pd is using, even though its settings read 44100.<br />
What happens, I guess, is that when you change Pd's audio settings you force a different sampling rate between the client (Pd) and the server (Jack), which causes this frequency difference, which probably occurs due to two different samplings of the same frequency.<br />
The only thing you should probably set in Pd's audio settings (if I'm not mistaken), is the number of channels of your sound card.</p>
]]></description><link>http://forum.pdpatchrepo.info/topic/10610/sampling-rate-impacting-sound/2</link><guid isPermaLink="true">http://forum.pdpatchrepo.info/topic/10610/sampling-rate-impacting-sound/2</guid><dc:creator><![CDATA[alexandros]]></dc:creator><pubDate>Wed, 01 Mar 2017 09:02:56 GMT</pubDate></item><item><title><![CDATA[Reply to sampling rate impacting sound on Wed, 01 Mar 2017 09:05:51 GMT]]></title><description><![CDATA[<p>I'm on Linux and using JACK too and changing the settings SHOULDN'T haven't an effect on audible frequency, particularly with the oscillators. In fact, it seems like Pd ignores any sample rate I try to set and just takes JACK's sample rate (but perhaps this is changeable with command line parameters). Anyways, I'm not hearing any difference in audible frequency from my own tests, as should be the case.</p>
<p>Anyways, [osc~] uses a lookup table for the sinusoid, meaning there's a cosine wave that's precalculated in Pd's guts and [osc~] searches for the value of cosine it needs with this table (with some interpolation as needed if it wants something in between stored values). A higher sampling rate just means that [osc~] looks up values more often, 48k times a second versus 44.1k times a second. [osc~ 440] in 44.1k and 48k is still going to be 440 Hz, no matter what the sampling rate. Now if you try to play a sound file encoded at 44.1k at 48k, well, that's going to sound different because it's not meant to be read through that fast so everything is going to sound higher-pitched than normal. It's exactly like playing a 33 1/3 RPM at 45 RPM.</p>
<p>You don't really need to worry about different sample rates when using stuff like [osc~] or even [readsf~] at least in terms of audible frequencies, Pd takes care of that. Now when you're indexing into an array with [tabread4~] to play sounds, well, then you need to take sample rates into consideration.</p>
]]></description><link>http://forum.pdpatchrepo.info/topic/10610/sampling-rate-impacting-sound/3</link><guid isPermaLink="true">http://forum.pdpatchrepo.info/topic/10610/sampling-rate-impacting-sound/3</guid><dc:creator><![CDATA[dxk]]></dc:creator><pubDate>Wed, 01 Mar 2017 09:05:51 GMT</pubDate></item></channel></rss>