Re: [squeakland] Question about Audio Buffer/Timing

karl ramberg <[email protected]> Sat, 17 Mar 2018 17:29:18 +0100
Newsgroups gmane.comp.lang.smalltalk.squeak.general,gmane.comp.lang.smalltalk.squeak.squeakland
Message-ID <CAGzzWLgZ7h=26TXw0c5FM5xykpqS9a0_b6n5rAk43LAkVjV+Zw@mail.gmail.com>
--===============2900267342369954828==
Content-Type: multipart/alternative; boundary="000000000000fcb12505679e39c1"

--000000000000fcb12505679e39c1
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

I fixed so EnvelopeEditorMorph can open without giving a error in
http://source.squeak.org/trunk/MorphicExtras-kfr.225.mcz

Best,
Karl

On Sat, Mar 17, 2018 at 2:13 PM, karl ramberg <[email protected]> wrote=
:

> Hi,
> ScorePlayerMorph is the class that has best support for making music.( FM
> synthesizer)
>
> Try this do it:
> | n score | n :=3D 3.
> score :=3D (MIDIScore new tracks: ((1 to: n) collect: [:i | Array new]);
> trackInfo: ((1 to: n) collect: [:i | 'Instrument' , i printString]);
> tempoMap: nil; ticksPerQuarterNote: 96).
> ScorePlayerMorph openOn: score title: 'empty score'
>
> In the opened ScorePlayerMorph click on PianoRoll.
> Right click on the opened PianoRollScore and select 'add keyboard' in the
> menu.
> When you click on the opened keyboard it records to the PianoRollScore
>
> You can select different instuments in the ScorePlayerMorph.
> Muting the different instruments in  ScorePlayerMorph to add/edit  the
> PianoRollScore=C2=A8
> Clicking on 'oboe1' you get a meny to select different FM synth premade
> instruments.
> The bottom of that menu give you 'edit oboe1'
>
> Selecting this will give you a DNU because the image does not have class
> ScaleMorph anymore.
> It can be found in old images and filed out. There where some licensing
> issues and I think maybe the
> author passed away before the class could be re licensed.
>
> Anyway, enjoy :-)
>
>
> These tools funktion but have MANY rough edges and a lot can be done to
> improve them.
>
> Best,
> Karl
>
>
> On Sat, Feb 24, 2018 at 5:56 PM, Jeremy Landry <[email protected]> wrote:
>
>> What can I do to make new music in Etoys, then?  According to FLOSS
>> manual, there's nothing for recording...?  The purpose of the sequencer =
was
>> to generate new music...this is basically the goal here...and to do so
>> without using an a MIDI instrument (well, a physical one, anyway...a
>> simulated one is fine!)
>>
>> On Sat, Feb 24, 2018 at 2:27 AM, karl ramberg <[email protected]>
>> wrote:
>>
>>> Etoys ticking is not precise enough to do music timing.
>>> Ticking might be offset by other task the system is doing.
>>> You should use the ScorePlayerMorph for music.
>>>
>>> Best,
>>> Karl
>>>
>>> On Thu, Feb 22, 2018 at 9:55 PM, Jeremy Landry <[email protected]>
>>> wrote:
>>>
>>>> Maybe clicking the sequencer squares to look like this will make more
>>>> sense when you play it back:
>>>> https://imgur.com/a/ZHsaS
>>>>
>>>> Setting the script to tick should be obvious what the problem is: not
>>>> only is the playback not timed at the same interval as the script
>>>> tick-rate, but it will 'skip' sometimes and omit playback.  What you s=
hould
>>>> hear is nonstop, fairly consistent drum smacks, like a drum roll.  Ins=
tead,
>>>> you'll hear it roll a little, stop quickly, then start rolling again, =
stop
>>>> quickly, and almost at random.  Does this help open up the problem?  I=
t's
>>>> not really about music here, just about timing and consistency of
>>>> triggering sounds on a timer...sometimes they do sound off, sometimes =
they
>>>> dont, sometimes they're in-time, sometimes they're not.  If you speed =
up
>>>> the ticks per second, you can hear that 'invisible metronome' I mentio=
ned
>>>> earlier, there seems to be an 'always running' object that only looks =
for
>>>> new sounds to play at a regular interval, if the trigger doesn't make =
that
>>>> window, then it gets dropped seemingly...it's like it's aliasing the
>>>> instructions or something...
>>>>
>>>> Hope this helps, and I appreciate you helping looking into it!
>>>>
>>>>
>>>> On Thu, Feb 22, 2018 at 12:03 PM, Bob Arning <[email protected]>
>>>> wrote:
>>>>
>>>>> I'm not enough of a musician to really know if it's behaving or not.
>>>>> These are drums, so it's not a continuous sound. When I set the scrip=
t to
>>>>> ticking, I do hear an occasional glitch that my well be due to garbag=
e
>>>>> collection -- it's possible that tweaking some gc parameters might re=
duce
>>>>> this. Perhaps a youtube posting with the sound you are hearing would =
let me
>>>>> compare it to what I'm hearing.
>>>>>
>>>>> On 2/22/18 2:33 PM, Jeremy Landry wrote:
>>>>>
>>>>> https://www.youtube.com/watch?v=3D_JlCCtHLHDk I forgot to post this i=
n
>>>>> the last message showing the more stable timing done with 'pure' sque=
ak
>>>>> classes/methods.
>>>>>
>>>>> On Thu, Feb 22, 2018 at 11:32 AM, Jeremy Landry <[email protected]>
>>>>> wrote:
>>>>>
>>>>>> https://drive.google.com/file/d/1nJlQ4huXcKZmTm6GADl40ZrWAEd
>>>>>> 7Kv97/view?usp=3Dsharing
>>>>>>
>>>>>> This is a demo of the problem for ETOYS 5 (along with some other
>>>>>> stuff there that shows what I've looked into, to some degree).  Hitt=
ing
>>>>>> play on the scriptor, you will hear a sequence that has awful timing=
.  I
>>>>>> don't expect 'sample perfect', zero latency or anything spectacular,=
 but it
>>>>>> would seem that if there's timers in the system, everything should a=
dhere
>>>>>> to it, or else not be called timers and something like,
>>>>>> 'when-we-get-around-to-its'.  This video here demonstrates that Sque=
ak, at
>>>>>> least, can do timing just fine and older versions have midi demos, b=
ut
>>>>>> again, I'm using Etoys for a specific reason, so it's confusing me a=
s to
>>>>>> why the delays happen...
>>>>>>
>>>>>> Both sequencers are mouse interactive and playing with the script
>>>>>> timer and setting blocks on/off can reveal this hidden metronome...m=
aybe
>>>>>> that IS the buffer?  I'm not sure...what's most puzzling is that som=
etimes
>>>>>> it will sound right, and sometimes it won't...even if it wasn't corr=
ect,
>>>>>> I'd probably be okay if it was consistently incorrect because I can
>>>>>> actually work with consistency, so I guess if nothing else, that's w=
hat I'm
>>>>>> trying to figure out how to get without making tile usage unavailabl=
e for a
>>>>>> sequencer built on etoys tiles...
>>>>>>
>>>>>> Thanks for all the efforts so far...I did notice some changing in th=
e
>>>>>> timing when I checked the preference there but also unchecked the
>>>>>> preference of stopSoundsWhenDone, just in case it was hiccuping by s=
hutting
>>>>>> down the sound stream then making a new one.  It didn't help, but I =
had
>>>>>> forgotten about these preferences.
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Thu, Feb 22, 2018 at 10:57 AM, Bob Arning <[email protected]>
>>>>>> wrote:
>>>>>>
>>>>>>> There do seem to be some platform issues as to whether this will
>>>>>>> really work. Some things you could do:
>>>>>>>
>>>>>>> - check the value of the Preference for #soundQuickStart -- make it
>>>>>>> true if not already
>>>>>>>
>>>>>>> - put some code into the SoundPlayer method to tell you if
>>>>>>> quickStart is being requested and if not honored, why
>>>>>>>
>>>>>>> On 2/22/18 1:22 PM, Jeremy Landry wrote:
>>>>>>>
>>>>>>> Thanks for the crossover.  I am subscribed, but generally shy away
>>>>>>> from posting there as it seems out of my league and my main interes=
t is in
>>>>>>> Etoys since, well, again, leagues and all that.  I know just enough=
 ST to
>>>>>>> break things, not build them!  :)
>>>>>>>
>>>>>>> So using the code from this message from Bob Arning:
>>>>>>> *Bob Arning* arning315 at comcast.net
>>>>>>> <squeak-dev%40lists.squeakfoundation.org?Subject=3DRe%3A%20%5Bsquea=
k-dev%5D%20%5Bsqueakland%5D%20Question%20about%20Audio%20Buffer/Timing&In-R=
eply-To=3D%3C269cdd30-7c77-6cab-22aa-591eee543b21%40comcast.net%3E>
>>>>>>> *Thu Feb 22 15:49:07 UTC 2018*
>>>>>>>
>>>>>>>    - Previous message: [squeak-dev] [squeakland] Question about
>>>>>>>    Audio Buffer/Timing
>>>>>>>    <http://lists.squeakfoundation.org/pipermail/squeak-dev/2018-Feb=
ruary/197505.html>
>>>>>>>    - Next message: [squeak-dev] [squeakland] Question about Audio
>>>>>>>    Buffer/Timing
>>>>>>>    <http://lists.squeakfoundation.org/pipermail/squeak-dev/2018-Feb=
ruary/197509.html>
>>>>>>>    - *Messages sorted by:* [ date ]
>>>>>>>    <http://lists.squeakfoundation.org/pipermail/squeak-dev/2018-Feb=
ruary/date.html#197508>
>>>>>>>     [ thread ]
>>>>>>>    <http://lists.squeakfoundation.org/pipermail/squeak-dev/2018-Feb=
ruary/thread.html#197508>
>>>>>>>     [ subject ]
>>>>>>>    <http://lists.squeakfoundation.org/pipermail/squeak-dev/2018-Feb=
ruary/subject.html#197508>
>>>>>>>     [ author ]
>>>>>>>    <http://lists.squeakfoundation.org/pipermail/squeak-dev/2018-Feb=
ruary/author.html#197508>
>>>>>>>
>>>>>>> ------------------------------
>>>>>>>
>>>>>>> SoundPlayer class gives a clue:
>>>>>>>
>>>>>>> resumePlaying: aSound quickStart: quickStart
>>>>>>>      "Start playing the given sound without resetting it; it will r=
esume
>>>>>>> playing from where it last stopped. If quickStart is true, then try=
 to
>>>>>>> start playing the given sound immediately."
>>>>>>>
>>>>>>>
>>>>>>> Just looking at it and taking a guess, it doesn't seem to be *quite=
*
>>>>>>> the thing I was looking for.  I was thinking there's a method/class
>>>>>>> variable with a value that could be changed to affect the system, r=
ather
>>>>>>> than 'poking in' every thing I want to play when I want to play it
>>>>>>> individually because the ultimate effect is that Etoys PLAYSOUND:SO=
UND tile
>>>>>>> will work as normal and this seems that it would have to be used in=
stead of
>>>>>>> the tiles...I have no idea if this is possible, but I'll also dig a=
round
>>>>>>> the class browser in Etoys, maybe I'll stumble into something, but =
so far,
>>>>>>> as I noted, I only found the sound-buffer and sample rates, not the=
 imposed
>>>>>>> delay method that I remember reading about.  I remember the reasoni=
ng it
>>>>>>> was put in was to prevent accidental playing of sounds inside of a
>>>>>>> single-frame repeat-tile...i.e. a repeat tile with any value other =
than 1
>>>>>>> and inside of it having a playsound:sound tile would overload the s=
peakers
>>>>>>> and make nasty noises because so many things are playing on top of =
each
>>>>>>> other. I actually WANT this.  Based on how sound plays now, you can=
 hear an
>>>>>>> 'invisible' metronome that makes sure all sounds are separated and =
equally
>>>>>>> spaced apart and in the case of repeat tiles, only seems to accept =
the last
>>>>>>> sound as valid/playable.
>>>>>>>
>>>>>>> Thanks for the help so far!  I'm not expecting a solution because I
>>>>>>> don't know if one exists, but my thought is 'if it was done, it can=
 be
>>>>>>> undone'...and just looking at how to undo it!  :p
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Thu, Feb 22, 2018 at 9:59 AM, David T. Lewis <[email protected]=
m
>>>>>>> > wrote:
>>>>>>>
>>>>>>>> There is some follow up discussion happening on the squeak-dev
>>>>>>>> list. I don't
>>>>>>>> know if it helps, but you can read the posts here if you are not
>>>>>>>> subscribed to
>>>>>>>> that list:
>>>>>>>>
>>>>>>>> http://lists.squeakfoundation.org/pipermail/squeak-dev/2018-
>>>>>>>> February/197508.html
>>>>>>>>
>>>>>>>> HTH,
>>>>>>>> Dave
>>>>>>>>
>>>>>>>> On Thu, Feb 22, 2018 at 10:27:18AM -0500, David T. Lewis wrote:
>>>>>>>> > Hi Jeremy,
>>>>>>>> >
>>>>>>>> > I am copying this to the squeak-dev list in case someone there
>>>>>>>> can offer
>>>>>>>> > some guidance.
>>>>>>>> >
>>>>>>>> > Dave
>>>>>>>> >
>>>>>>>> >
>>>>>>>> > On Wed, Feb 21, 2018 at 02:44:21PM -0800, Jeremy Landry wrote:
>>>>>>>> > > Hi, I made a quick audio sequencer test in Etoys and found tha=
t
>>>>>>>> there's a
>>>>>>>> > > hidden 'timer' that limits the responsiveness of new sounds
>>>>>>>> that go into
>>>>>>>> > > the playback buffer (terminology isn't accurate, but hopefully
>>>>>>>> it makes
>>>>>>>> > > sense to people).
>>>>>>>> > >
>>>>>>>> > > I found the sound buffer setting, but was wondering if there's
>>>>>>>> something
>>>>>>>> > > else that limits how fast new sounds get added to the playback
>>>>>>>> stream? I
>>>>>>>> > > read somewhere (old-man-aphasia here) that some code was added
>>>>>>>> to prevent
>>>>>>>> > > overloading the buffer so surely there's a snippet of code I
>>>>>>>> could add to a
>>>>>>>> > > project to reverse this, if it's what is causing the delay?
>>>>>>>> > >
>>>>>>>> > > Thanks for any help finding the solution.
>>>>>>>> >
>>>>>>>> > > _______________________________________________
>>>>>>>> > > squeakland mailing list
>>>>>>>> > > [email protected]
>>>>>>>> > > http://lists.squeakland.org/mailman/listinfo/squeakland
>>>>>>>> >
>>>>>>>> > _______________________________________________
>>>>>>>> > squeakland mailing list
>>>>>>>> > [email protected]
>>>>>>>> > http://lists.squeakland.org/mailman/listinfo/squeakland
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> _______________________________________________
>>>>>>> squeakland mailing [email protected]://lists.=
squeakland.org/mailman/listinfo/squeakland
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> _______________________________________________
>>>>>>> squeakland mailing list
>>>>>>> [email protected]
>>>>>>> http://lists.squeakland.org/mailman/listinfo/squeakland
>>>>>>>
>>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>> _______________________________________________
>>>> squeakland mailing list
>>>> [email protected]
>>>> http://lists.squeakland.org/mailman/listinfo/squeakland
>>>>
>>>>
>>>
>>
>

--000000000000fcb12505679e39c1
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">I fixed so EnvelopeEditorMorph can open without giving a e=
rror in=C2=A0

<a href=3D"http://source.squeak.org/trunk/MorphicExtras-kfr.225.mcz" rel=3D=
"noreferrer" target=3D"_blank" style=3D"color:rgb(17,85,204);font-family:ar=
ial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:no=
rmal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-al=
ign:start;text-indent:0px;text-transform:none;white-space:normal;word-spaci=
ng:0px;background-color:rgb(255,255,255)">http://source.squeak.org/<wbr>tru=
nk/MorphicExtras-kfr.225.<wbr>mcz</a>

<div><br></div><div>Best,</div><div>Karl</div></div><div class=3D"gmail_ext=
ra"><br><div class=3D"gmail_quote">On Sat, Mar 17, 2018 at 2:13 PM, karl ra=
mberg <span dir=3D"ltr">&lt;<a href=3D"mailto:[email protected]" target=
=3D"_blank">[email protected]</a>&gt;</span> wrote:<br><blockquote clas=
s=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;pad=
ding-left:1ex"><div dir=3D"ltr">Hi,<div>ScorePlayerMorph is the class that =
has best support for making music.( FM synthesizer)</div><div><br></div><di=
v>Try this do it:<br></div><div><div><span style=3D"white-space:pre-wrap">	=
</span>| n score | n :=3D 3.</div><div><span style=3D"white-space:pre-wrap"=
>	</span>score :=3D (MIDIScore new tracks: ((1 to: n) collect: [:i | Array =
new]);</div><div><span style=3D"white-space:pre-wrap">		</span>trackInfo: (=
(1 to: n) collect: [:i | &#39;Instrument&#39; , i printString]);</div><div>=
<span style=3D"white-space:pre-wrap">		</span>tempoMap: nil; ticksPerQuarte=
rNote: 96).</div><div><span style=3D"white-space:pre-wrap">	</span>ScorePla=
yerMorph openOn: score title: &#39;empty score&#39;</div></div><div><br></d=
iv><div>In the opened ScorePlayerMorph click on PianoRoll.</div><div>Right =
click on the opened PianoRollScore and select &#39;add keyboard&#39; in the=
 menu.</div><div>When you click on the opened keyboard it records to the Pi=
anoRollScore</div><div><br></div><div>You can select different instuments i=
n the ScorePlayerMorph.</div><div>Muting the different instruments in=C2=A0

<span style=3D"color:rgb(34,34,34);font-family:arial,sans-serif;font-size:s=
mall;font-style:normal;font-variant-ligatures:normal;font-variant-caps:norm=
al;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;t=
ext-transform:none;white-space:normal;word-spacing:0px;background-color:rgb=
(255,255,255);text-decoration-style:initial;text-decoration-color:initial;f=
loat:none;display:inline">ScorePlayerMorph</span>

 to add/edit=C2=A0 the PianoRollScore=C2=A8</div><div>Clicking on &#39;oboe=
1&#39; you get a meny to select different FM synth premade instruments.</di=
v><div>The bottom of that menu give you &#39;edit oboe1&#39;</div><div><br>=
</div><div>Selecting this will give you a DNU because the image does not ha=
ve class ScaleMorph anymore.</div><div>It can be found in old images and fi=
led out. There where some licensing issues and I think maybe the=C2=A0</div=
><div>author passed away before the class could be re licensed.=C2=A0</div>=
<div><br></div><div>Anyway, enjoy :-)=C2=A0</div><div><br></div><div><br></=
div><div>These tools funktion but have MANY rough edges and a lot can be do=
ne to improve them.</div><div><br></div><div>Best,</div><div>Karl</div><div=
><br></div></div><div class=3D"HOEnZb"><div class=3D"h5"><div class=3D"gmai=
l_extra"><br><div class=3D"gmail_quote">On Sat, Feb 24, 2018 at 5:56 PM, Je=
remy Landry <span dir=3D"ltr">&lt;<a href=3D"mailto:[email protected]" targ=
et=3D"_blank">[email protected]</a>&gt;</span> wrote:<br><blockquote class=
=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padd=
ing-left:1ex"><div dir=3D"ltr">What can I do to make new music in Etoys, th=
en?=C2=A0 According to FLOSS manual, there&#39;s nothing for recording...?=
=C2=A0 The purpose of the sequencer was to generate new music...this is bas=
ically the goal here...and to do so without using an a MIDI instrument (wel=
l, a physical one, anyway...a simulated one is fine!)</div><div class=3D"m_=
1376157283908535302HOEnZb"><div class=3D"m_1376157283908535302h5"><div clas=
s=3D"gmail_extra"><br><div class=3D"gmail_quote">On Sat, Feb 24, 2018 at 2:=
27 AM, karl ramberg <span dir=3D"ltr">&lt;<a href=3D"mailto:karlramberg@gma=
il.com" target=3D"_blank">[email protected]</a>&gt;</span> wrote:<br><b=
lockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px =
#ccc solid;padding-left:1ex"><div dir=3D"ltr">Etoys ticking is not precise =
enough to do music timing.<div>Ticking might be offset by other task the sy=
stem is doing.<br><div>You should use the ScorePlayerMorph for music.</div>=
</div><div><br></div><div>Best,</div><div>Karl</div></div><div class=3D"m_1=
376157283908535302m_6851049898053500012HOEnZb"><div class=3D"m_137615728390=
8535302m_6851049898053500012h5"><div class=3D"gmail_extra"><br><div class=
=3D"gmail_quote">On Thu, Feb 22, 2018 at 9:55 PM, Jeremy Landry <span dir=
=3D"ltr">&lt;<a href=3D"mailto:[email protected]" target=3D"_blank">hakyoku=
@gmail.com</a>&gt;</span> wrote:<br><blockquote class=3D"gmail_quote" style=
=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir=
=3D"ltr"><div>Maybe clicking the sequencer squares to look like this will m=
ake more sense when you play it back:=C2=A0</div><div><a href=3D"https://im=
gur.com/a/ZHsaS" target=3D"_blank">https://imgur.com/a/ZHsaS</a><br></div><=
div><br></div><div>Setting the script to tick should be obvious what the pr=
oblem is: not only is the playback not timed at the same interval as the sc=
ript tick-rate, but it will &#39;skip&#39; sometimes and omit playback.=C2=
=A0 What you should hear is nonstop, fairly consistent drum smacks, like a =
drum roll.=C2=A0 Instead, you&#39;ll hear it roll a little, stop quickly, t=
hen start rolling again, stop quickly, and almost at random.=C2=A0 Does thi=
s help open up the problem?=C2=A0 It&#39;s not really about music here, jus=
t about timing and consistency of triggering sounds on a timer...sometimes =
they do sound off, sometimes they dont, sometimes they&#39;re in-time, some=
times they&#39;re not.=C2=A0 If you speed up the ticks per second, you can =
hear that &#39;invisible metronome&#39; I mentioned earlier, there seems to=
 be an &#39;always running&#39; object that only looks for new sounds to pl=
ay at a regular interval, if the trigger doesn&#39;t make that window, then=
 it gets dropped seemingly...it&#39;s like it&#39;s aliasing the instructio=
ns or something...</div><div><br></div><div>Hope this helps, and I apprecia=
te you helping looking into it!=C2=A0=C2=A0</div><div><br></div></div><div =
class=3D"m_1376157283908535302m_6851049898053500012m_6505211406727498863HOE=
nZb"><div class=3D"m_1376157283908535302m_6851049898053500012m_650521140672=
7498863h5"><div class=3D"gmail_extra"><br><div class=3D"gmail_quote">On Thu=
, Feb 22, 2018 at 12:03 PM, Bob Arning <span dir=3D"ltr">&lt;<a href=3D"mai=
lto:[email protected]" target=3D"_blank">[email protected]</a>&gt;<=
/span> wrote:<br><blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8=
ex;border-left:1px #ccc solid;padding-left:1ex">
 =20
   =20
 =20
  <div text=3D"#000000" bgcolor=3D"#FFFFFF">
    <p><font face=3D"Georgia">I&#39;m not enough of a musician to really kn=
ow
        if it&#39;s behaving or not. These are drums, so it&#39;s not a
        continuous sound. When I set the script to ticking, I do hear an
        occasional glitch that my well be due to garbage collection --
        it&#39;s possible that tweaking some gc parameters might reduce
        this. Perhaps a youtube posting with the sound you are hearing
        would let me compare it to what I&#39;m hearing.</font><br>
    </p><div><div class=3D"m_1376157283908535302m_6851049898053500012m_6505=
211406727498863m_313355801356882249h5">
    <br>
    <div class=3D"m_1376157283908535302m_6851049898053500012m_6505211406727=
498863m_313355801356882249m_-50921442851577088moz-cite-prefix">On 2/22/18 2=
:33 PM, Jeremy Landry
      wrote:<br>
    </div>
    <blockquote type=3D"cite">
      <div dir=3D"ltr"><a href=3D"https://www.youtube.com/watch?v=3D_JlCCtH=
LHDk" target=3D"_blank">https://www.youtube.com/watch?<wbr>v=3D_JlCCtHLHDk<=
/a>
        I forgot to post this in the last message showing the more
        stable timing done with &#39;pure&#39; squeak classes/methods.<br>
      </div>
      <div class=3D"gmail_extra"><br>
        <div class=3D"gmail_quote">On Thu, Feb 22, 2018 at 11:32 AM,
          Jeremy Landry <span dir=3D"ltr">&lt;<a href=3D"mailto:hakyoku@gma=
il.com" target=3D"_blank">[email protected]</a>&gt;</span>
          wrote:<br>
          <blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;bord=
er-left:1px #ccc solid;padding-left:1ex">
            <div dir=3D"ltr"><a href=3D"https://drive.google.com/file/d/1nJ=
lQ4huXcKZmTm6GADl40ZrWAEd7Kv97/view?usp=3Dsharing" target=3D"_blank">https:=
//drive.google.com/file/<wbr>d/1nJlQ4huXcKZmTm6GADl40ZrWAEd<wbr>7Kv97/view?=
usp=3Dsharing</a><br>
              <div><br>
              </div>
              <div>This is a demo of the problem for ETOYS 5 (along with
                some other stuff there that shows what I&#39;ve looked into=
,
                to some degree).=C2=A0 Hitting play on the scriptor, you wi=
ll
                hear a sequence that has awful timing.=C2=A0 I don&#39;t ex=
pect
                &#39;sample perfect&#39;, zero latency or anything spectacu=
lar,
                but it would seem that if there&#39;s timers in the system,
                everything should adhere to it, or else not be called
                timers and something like, &#39;when-we-get-around-to-its&#=
39;.=C2=A0
                This video here demonstrates that Squeak, at least, can
                do timing just fine and older versions have midi demos,
                but again, I&#39;m using Etoys for a specific reason, so
                it&#39;s confusing me as to why the delays happen...</div>
              <div><br>
              </div>
              <div>Both sequencers are mouse interactive and playing
                with the script timer and setting blocks on/off can
                reveal this hidden metronome...maybe that IS the
                buffer?=C2=A0 I&#39;m not sure...what&#39;s most puzzling i=
s that
                sometimes it will sound right, and sometimes it
                won&#39;t...even if it wasn&#39;t correct, I&#39;d probably=
 be okay
                if it was consistently incorrect because I can actually
                work with consistency, so I guess if nothing else,
                that&#39;s what I&#39;m trying to figure out how to get wit=
hout
                making tile usage unavailable for a sequencer built on
                etoys tiles...</div>
              <div><br>
              </div>
              <div>Thanks for all the efforts so far...I did notice some
                changing in the timing when I checked the preference
                there but also unchecked the preference of
                stopSoundsWhenDone, just in case it was hiccuping by
                shutting down the sound stream then making a new one.=C2=A0
                It didn&#39;t help, but I had forgotten about these
                preferences.</div>
              <div><br>
              </div>
              <div><br>
              </div>
              <div><br>
              </div>
              <div>=C2=A0=C2=A0</div>
              <div><br>
              </div>
              <div><br>
              </div>
            </div>
            <div class=3D"m_1376157283908535302m_6851049898053500012m_65052=
11406727498863m_313355801356882249m_-50921442851577088HOEnZb">
              <div class=3D"m_1376157283908535302m_6851049898053500012m_650=
5211406727498863m_313355801356882249m_-50921442851577088h5">
                <div class=3D"gmail_extra"><br>
                  <div class=3D"gmail_quote">On Thu, Feb 22, 2018 at 10:57
                    AM, Bob Arning <span dir=3D"ltr">&lt;<a href=3D"mailto:=
[email protected]" target=3D"_blank">[email protected]</a>&gt;</spa=
n>
                    wrote:<br>
                    <blockquote class=3D"gmail_quote" style=3D"margin:0 0 0=
 .8ex;border-left:1px #ccc solid;padding-left:1ex">
                      <div text=3D"#000000" bgcolor=3D"#FFFFFF">
                        <p><font face=3D"Georgia">There do seem to be some
                            platform issues as to whether this will
                            really work. Some things you could do:</font></=
p>
                        <p><font face=3D"Georgia">- check the value of the
                            Preference for #soundQuickStart -- make it
                            true if not already</font></p>
                        <p><font face=3D"Georgia">- put some code into the
                            SoundPlayer method to tell you if quickStart
                            is being requested and if not honored, why</fon=
t><br>
                        </p>
                        <div>
                          <div class=3D"m_1376157283908535302m_685104989805=
3500012m_6505211406727498863m_313355801356882249m_-50921442851577088m_-1939=
768682591439961h5"> <br>
                            <div class=3D"m_1376157283908535302m_6851049898=
053500012m_6505211406727498863m_313355801356882249m_-50921442851577088m_-19=
39768682591439961m_4959563591284099764moz-cite-prefix">On
                              2/22/18 1:22 PM, Jeremy Landry wrote:<br>
                            </div>
                            <blockquote type=3D"cite">
                              <div dir=3D"ltr">Thanks for the crossover.=C2=
=A0
                                I am subscribed, but generally shy away
                                from posting there as it seems out of my
                                league and my main interest is in Etoys
                                since, well, again, leagues and all
                                that.=C2=A0 I know just enough ST to break
                                things, not build them!=C2=A0 :)
                                <div><br>
                                </div>
                                <div>So using the code from this message
                                  from Bob Arning:</div>
                                <div> <b>Bob Arning</b><span><span>=C2=A0</=
span></span><a href=3D"mailto:squeak-dev%40lists.squeakfoundation.org?Subje=
ct=3DRe%3A%20%5Bsqueak-dev%5D%20%5Bsqueakland%5D%20Question%20about%20Audio=
%20Buffer/Timing&amp;In-Reply-To=3D%3C269cdd30-7c77-6cab-22aa-591eee543b21%=
40comcast.net%3E" title=3D"[squeak-dev] [squeakland]
                                    Question about Audio Buffer/Timing" tar=
get=3D"_blank">arning315 at
                                    comcast.net<span>=C2=A0</span></a><br>
                                  <i>Thu Feb 22 15:49:07 UTC 2018</i><span>=
</span>
                                  <ul>
                                    <li>Previous message:<span>=C2=A0</span=
><a href=3D"http://lists.squeakfoundation.org/pipermail/squeak-dev/2018-Feb=
ruary/197505.html" target=3D"_blank">[squeak-dev]
                                        [squeakland] Question about
                                        Audio Buffer/Timing</a></li>
                                    <li>Next message:<span>=C2=A0</span><a =
href=3D"http://lists.squeakfoundation.org/pipermail/squeak-dev/2018-Februar=
y/197509.html" target=3D"_blank">[squeak-dev]
                                        [squeakland] Question about
                                        Audio Buffer/Timing</a></li>
                                    <li><b>Messages sorted by:</b><span>=C2=
=A0</span><a href=3D"http://lists.squeakfoundation.org/pipermail/squeak-dev=
/2018-February/date.html#197508" target=3D"_blank">[ date ]</a><span>=C2=A0=
</span><a href=3D"http://lists.squeakfoundation.org/pipermail/squeak-dev/20=
18-February/thread.html#197508" target=3D"_blank">[ thread
                                        ]</a><span>=C2=A0</span><a href=3D"=
http://lists.squeakfoundation.org/pipermail/squeak-dev/2018-February/subjec=
t.html#197508" target=3D"_blank">[ subject
                                        ]</a><span>=C2=A0</span><a href=3D"=
http://lists.squeakfoundation.org/pipermail/squeak-dev/2018-February/author=
.html#197508" target=3D"_blank">[ author
                                        ]</a></li>
                                  </ul>
                                  <hr>
                                  <pre style=3D"color:rgb(0,0,0);font-style=
:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:=
400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:n=
one;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-styl=
e:initial;text-decoration-color:initial">SoundPlayer class gives a clue:

resumePlaying: aSound quickStart: quickStart
 =C2=A0=C2=A0=C2=A0 &quot;Start playing the given sound without resetting i=
t; it will resume=20
playing from where it last stopped. If quickStart is true, then try to=20
start playing the given sound immediately.&quot;
</pre>
                                  <br class=3D"m_1376157283908535302m_68510=
49898053500012m_6505211406727498863m_313355801356882249m_-50921442851577088=
m_-1939768682591439961m_4959563591284099764gmail-Apple-interchange-newline"=
>
                                  Just looking at it and taking a guess,
                                  it doesn&#39;t seem to be *quite* the
                                  thing I was looking for.=C2=A0 I was
                                  thinking there&#39;s a method/class
                                  variable with a value that could be
                                  changed to affect the system, rather
                                  than &#39;poking in&#39; every thing I wa=
nt to
                                  play when I want to play it
                                  individually because the ultimate
                                  effect is that Etoys PLAYSOUND:SOUND
                                  tile will work as normal and this
                                  seems that it would have to be used
                                  instead of the tiles...I have no idea
                                  if this is possible, but I&#39;ll also di=
g
                                  around the class browser in Etoys,
                                  maybe I&#39;ll stumble into something, bu=
t
                                  so far, as I noted, I only found the
                                  sound-buffer and sample rates, not the
                                  imposed delay method that I remember
                                  reading about.=C2=A0 I remember the
                                  reasoning it was put in was to prevent
                                  accidental playing of sounds inside of
                                  a single-frame repeat-tile...i.e. a
                                  repeat tile with any value other than
                                  1 and inside of it having a
                                  playsound:sound tile would overload
                                  the speakers and make nasty noises
                                  because so many things are playing on
                                  top of each other. I actually WANT
                                  this.=C2=A0 Based on how sound plays now,
                                  you can hear an &#39;invisible&#39; metro=
nome
                                  that makes sure all sounds are
                                  separated and equally spaced apart and
                                  in the case of repeat tiles, only
                                  seems to accept the last sound as
                                  valid/playable.</div>
                                <div><br>
                                </div>
                                <div>Thanks for the help so far!=C2=A0 I&#3=
9;m
                                  not expecting a solution because I
                                  don&#39;t know if one exists, but my
                                  thought is &#39;if it was done, it can be
                                  undone&#39;...and just looking at how to
                                  undo it!=C2=A0 :p=C2=A0=C2=A0</div>
                                <div><br>
                                </div>
                                <div><br>
                                </div>
                              </div>
                              <div class=3D"gmail_extra"><br>
                                <div class=3D"gmail_quote">On Thu, Feb 22,
                                  2018 at 9:59 AM, David T. Lewis <span dir=
=3D"ltr">&lt;<a href=3D"mailto:[email protected]" target=3D"_blank">lewis=
@mail.msen.com</a>&gt;</span>
                                  wrote:<br>
                                  <blockquote class=3D"gmail_quote" style=
=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">There is
                                    some follow up discussion happening
                                    on the squeak-dev list. I don&#39;t<br>
                                    know if it helps, but you can read
                                    the posts here if you are not
                                    subscribed to<br>
                                    that list:<br>
                                    <br>
                                    <a href=3D"http://lists.squeakfoundatio=
n.org/pipermail/squeak-dev/2018-February/197508.html" rel=3D"noreferrer" ta=
rget=3D"_blank">http://lists.squeakfoundation.<wbr>org/pipermail/squeak-dev=
/2018-<wbr>February/197508.html</a><br>
                                    <br>
                                    HTH,<br>
                                    Dave<br>
                                    <div class=3D"m_1376157283908535302m_68=
51049898053500012m_6505211406727498863m_313355801356882249m_-50921442851577=
088m_-1939768682591439961m_4959563591284099764HOEnZb">
                                      <div class=3D"m_1376157283908535302m_=
6851049898053500012m_6505211406727498863m_313355801356882249m_-509214428515=
77088m_-1939768682591439961m_4959563591284099764h5"><br>
                                        On Thu, Feb 22, 2018 at
                                        10:27:18AM -0500, David T. Lewis
                                        wrote:<br>
                                        &gt; Hi Jeremy,<br>
                                        &gt;<br>
                                        &gt; I am copying this to the
                                        squeak-dev list in case someone
                                        there can offer<br>
                                        &gt; some guidance.<br>
                                        &gt;<br>
                                        &gt; Dave<br>
                                        &gt;<br>
                                        &gt;<br>
                                        &gt; On Wed, Feb 21, 2018 at
                                        02:44:21PM -0800, Jeremy Landry
                                        wrote:<br>
                                        &gt; &gt; Hi, I made a quick
                                        audio sequencer test in Etoys
                                        and found that there&#39;s a<br>
                                        &gt; &gt; hidden &#39;timer&#39; th=
at
                                        limits the responsiveness of new
                                        sounds that go into<br>
                                        &gt; &gt; the playback buffer
                                        (terminology isn&#39;t accurate, bu=
t
                                        hopefully it makes<br>
                                        &gt; &gt; sense to people).<br>
                                        &gt; &gt;<br>
                                        &gt; &gt; I found the sound
                                        buffer setting, but was
                                        wondering if there&#39;s something<=
br>
                                        &gt; &gt; else that limits how
                                        fast new sounds get added to the
                                        playback stream? I<br>
                                        &gt; &gt; read somewhere
                                        (old-man-aphasia here) that some
                                        code was added to prevent<br>
                                        &gt; &gt; overloading the buffer
                                        so surely there&#39;s a snippet of
                                        code I could add to a<br>
                                        &gt; &gt; project to reverse
                                        this, if it&#39;s what is causing
                                        the delay?<br>
                                        &gt; &gt;<br>
                                        &gt; &gt; Thanks for any help
                                        finding the solution.<br>
                                        &gt;<br>
                                        &gt; &gt;
                                        ______________________________<wbr>=
_________________<br>
                                        &gt; &gt; squeakland mailing
                                        list<br>
                                        &gt; &gt; <a href=3D"mailto:squeakl=
[email protected]" target=3D"_blank">[email protected]<=
wbr>g</a><br>
                                        &gt; &gt; <a href=3D"http://lists.s=
queakland.org/mailman/listinfo/squeakland" rel=3D"noreferrer" target=3D"_bl=
ank">http://lists.squeakland.org/ma<wbr>ilman/listinfo/squeakland</a><br>
                                        &gt;<br>
                                        &gt;
                                        ______________________________<wbr>=
_________________<br>
                                        &gt; squeakland mailing list<br>
                                        &gt; <a href=3D"mailto:squeakland@l=
ists.squeakland.org" target=3D"_blank">[email protected]<wbr>g=
</a><br>
                                        &gt; <a href=3D"http://lists.squeak=
land.org/mailman/listinfo/squeakland" rel=3D"noreferrer" target=3D"_blank">=
http://lists.squeakland.org/ma<wbr>ilman/listinfo/squeakland</a><br>
                                      </div>
                                    </div>
                                  </blockquote>
                                </div>
                                <br>
                              </div>
                              <br>
                              <fieldset class=3D"m_1376157283908535302m_685=
1049898053500012m_6505211406727498863m_313355801356882249m_-509214428515770=
88m_-1939768682591439961m_4959563591284099764mimeAttachmentHeader"></fields=
et>
                              <br>
                              <pre>______________________________<wbr>_____=
____________
squeakland mailing list
<a class=3D"m_1376157283908535302m_6851049898053500012m_6505211406727498863=
m_313355801356882249m_-50921442851577088m_-1939768682591439961m_49595635912=
84099764moz-txt-link-abbreviated" href=3D"mailto:[email protected]=
d.org" target=3D"_blank">[email protected]<wbr>g</a>
<a class=3D"m_1376157283908535302m_6851049898053500012m_6505211406727498863=
m_313355801356882249m_-50921442851577088m_-1939768682591439961m_49595635912=
84099764moz-txt-link-freetext" href=3D"http://lists.squeakland.org/mailman/=
listinfo/squeakland" target=3D"_blank">http://lists.squeakland.org/ma<wbr>i=
lman/listinfo/squeakland</a>
</pre>
                            </blockquote>
                            <br>
                          </div>
                        </div>
                      </div>
                      <br>
                      ______________________________<wbr>_________________<=
br>
                      squeakland mailing list<br>
                      <a href=3D"mailto:[email protected]" ta=
rget=3D"_blank">[email protected]<wbr>g</a><br>
                      <a href=3D"http://lists.squeakland.org/mailman/listin=
fo/squeakland" rel=3D"noreferrer" target=3D"_blank">http://lists.squeakland=
.org/ma<wbr>ilman/listinfo/squeakland</a><br>
                      <br>
                    </blockquote>
                  </div>
                  <br>
                </div>
              </div>
            </div>
          </blockquote>
        </div>
        <br>
      </div>
    </blockquote>
    <br>
  </div></div></div>

</blockquote></div><br></div>
</div></div><br>______________________________<wbr>_________________<br>
squeakland mailing list<br>
<a href=3D"mailto:[email protected]" target=3D"_blank">squeak=
[email protected]<wbr>g</a><br>
<a href=3D"http://lists.squeakland.org/mailman/listinfo/squeakland" rel=3D"=
noreferrer" target=3D"_blank">http://lists.squeakland.org/ma<wbr>ilman/list=
info/squeakland</a><br>
<br></blockquote></div><br></div>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>

--000000000000fcb12505679e39c1--


--===============2900267342369954828==
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: base64
Content-Disposition: inline

Cg==

--===============2900267342369954828==--