<html><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:12pt"><div style="" class=""><span style="" class="">tcl/tk is just doing what it's told, which is to send mouse movement notifications over the socket to Pd.</span></div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; font-style: normal;"><br style="" class=""><span style="" class=""></span></div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; font-style: normal;"><span style="" class="">For each mouse motion message Pd receives from the GUI, it does a full loop over all the objects in the canvas to find out who was clicked.  In edit mode, it can
 do up to two full loops if you did a "select all".  (See canvas_findhitbox in g_editor.c)</span><span style="" class="">.  I'm assuming those are the most labor intensive parts of moving the mouse in Pd, but I haven't actually done any profiling.</span></div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; font-style: normal;"><br style="" class=""><span style="" class=""></span></div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; font-style: normal;"><span style="" class="">Additionally, each iteration of the loop calls a getrectfn for the object being inspected.  Typically that function just spits back the last values stored for the object's bbox.  But if a single GUI external happens
 to do something oddly inefficient in that function, it is doing it every mouse motion message.</span></div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; font-style: normal;"><br style="" class=""><span style="" class=""></span></div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; font-style: normal;"><span style="" class="">If these calculations + dsp graph calculation don't finish in the time it takes to compute a block, you'll get a dropout.  And of course if you got a dropout, and you continue moving the mouse, you'll probably continue getting dropouts.</span></div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue,Helvetica Neue,Helvetica,Arial,Lucida
 Grande,sans-serif; background-color: transparent; font-style: normal;"><br style="" class=""><span style="" class=""></span></div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; background-color: transparent; font-style: normal;"><span style="" class="">On the other hand, tk will put off redrawing the canvas until it has free time to do so.  Thus redrawing may come regularly, sporadically, or in some unfortunate cases with Pd -rt, never.  The fact that tk happily stops drawing at all when the core Pd process has realtime scheduling should tell you that tk is usually not the culprit in dropouts.</span></div><br style="" class="">It's unclear what the solution should be.  If one removed all the widgetbehavior from "core" and put it in a separate "gui" process, then the patch author no longer has easy access to the visual diagram data.  (Easy
 as in deterministic behavior when querying object positions or bboxes in a chain of objects that compute in zero logical time.)  On the other hand, I think the GUI could just send a message telling Pd which object was actually clicked.  (But keep all the getrect and hitbox functionality around so that if the user needs to fetch that data programmatically they can do so.)<br><br>-Jonathan<br style="" class=""><div class="qtdSeparateBR"><br><br></div><div style="display: block;" class="yahoo_quoted"> <div class="" style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 12pt;"> <div class="" style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 12pt;"> <div style="" class="" dir="ltr"> <font style="" class="" face="Arial" size="2"> On Friday, June 27, 2014 5:50 AM, Billy Stiltner via Pd-list <pd-list@lists.iem.at> wrote:<br style=""
 class=""> </font> </div>  <br style="" class=""><br style="" class=""> <div style="" class=""><div style="" class="" id="yiv0127175357"><div style="" class=""><div style="" class="" dir="ltr">i think it has something to do with tcl and the mouse<br style="" class="" clear="none"><br style="" class="" clear="none"></div><div style="" class="" id="yiv0127175357yqt72009"><div style="" class=""><br style="" class="" clear="none"><br style="" class="" clear="none"><div style="" class="">On Thu, Jun 19, 2014 at 5:55 PM, Simon Iten via Pd-list <span style="" class="" dir="ltr"><<a style="" class="" rel="nofollow" shape="rect" ymailto="mailto:pd-list@lists.iem.at" target="_blank" href="mailto:pd-list@lists.iem.at">pd-list@lists.iem.at</a>></span> wrote:<br style="" class="" clear="none">
<blockquote class="" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">i was Not clear i guess. I mean it never worked properly. A lot of dropouts and lock ups.<br style="" class="" clear="none">
<div style="" class=""><div style="" class=""><br style="" class="" clear="none">
<br style="" class="" clear="none">
_______________________________________________<br style="" class="" clear="none">
<a style="" class="" rel="nofollow" shape="rect" ymailto="mailto:Pd-list@lists.iem.at" target="_blank" href="mailto:Pd-list@lists.iem.at">Pd-list@lists.iem.at</a> mailing list<br style="" class="" clear="none">
UNSUBSCRIBE and account-management -> <a style="" class="" rel="nofollow" shape="rect" target="_blank" href="http://lists.puredata.info/listinfo/pd-list">http://lists.puredata.info/listinfo/pd-list</a><br style="" class="" clear="none">
</div></div></blockquote></div><br style="" class="" clear="none"></div></div></div></div><br style="" class=""><div style="" class="" id="yqt85423">_______________________________________________<br style="" class="" clear="none"><a style="" class="" shape="rect" ymailto="mailto:Pd-list@lists.iem.at" href="mailto:Pd-list@lists.iem.at">Pd-list@lists.iem.at</a> mailing list<br style="" class="" clear="none">UNSUBSCRIBE and account-management -> <a style="" class="" shape="rect" href="http://lists.puredata.info/listinfo/pd-list" target="_blank">http://lists.puredata.info/listinfo/pd-list</a><br style="" class="" clear="none"></div><br style="" class=""><br style="" class=""></div>  </div> </div>  </div> </div></body></html>