<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=windows-1252">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<font face="DejaVu Sans Mono"><br>
@Cristoph, I am not experienced enough in this language to help
you. I may be able to discuss this in a few months;) <br>
<br>
bye<br>
n.<br>
</font><br>
<div class="moz-cite-prefix">On 9/14/19 6:35 AM, Thiede, Christoph
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:e96d1d33f6cb485bbff3ad8d5a6682aa@student.hpi.uni-potsdam.de">
<meta http-equiv="Content-Type" content="text/html;
charset=windows-1252">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
<div id="divtagdefaultwrapper"
style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;"
dir="ltr">
<div id="divtagdefaultwrapper" dir="ltr" style="font-size: 12pt;
color: rgb(0, 0, 0); font-family: Calibri, Helvetica,
sans-serif, EmojiFont, "Apple Color Emoji",
"Segoe UI Emoji", NotoColorEmoji, "Segoe UI
Symbol", "Android Emoji", EmojiSymbols;">
<p>Well, maybe I should mention I activated the "windows
always active" preferences (that I am a big fan of). So
@Nicola, when I move my cursor quickly about five windows,
this might result in a quite large number of boosts &
unboosts ... Apart from that, all morphs are drawn using the
central #drawOn: mechanism, so I guess this would be a
completely new approach?</p>
<p><br>
</p>
<p>@Jeremy Very interesting, I have always assumed that
#drawOn: would be somehow optimized. Still, I cannot
reproduce your statements completely, do the following:</p>
<p><br>
</p>
<div>Morph subclass: #CTDebugMorph</div>
<div><span style="white-space:pre"></span>instanceVariableNames:
''</div>
<div><span style="white-space:pre"></span>classVariableNames:
''</div>
<div><span style="white-space:pre"></span>poolDictionaries: ''</div>
<div><span style="white-space:pre"></span>category:
'CT-Experiments'.</div>
<div>CTDebugMorph compile: 'drawOn: aCanvas</div>
<div><span style="font-size:12pt; white-space:pre"></span><span
style="font-size:12pt">aCanvas fillRectangle: self bounds
color: (Color h: 0 s: 0 v: Random new next).'</span><br>
</div>
<div><span style="font-size:12pt">CTDebugMorph openInWorld.</span></div>
<br>
<p>The color changes very infrequent, even if you move another
morph partially above it ...</p>
<p>How can you compare this to BouncingAtoms? In the atom
example, the expensive task might be rather the stepping
logic than #drawOn:. I think it would bring you a bucket of
problems if only parts of the stepping list were processed?</p>
<p>However, I think BouncingAtoms does not match my current
problem, as SystemWindows usually do a maximum of one step
per second.</p>
<p><br>
</p>
<p>> <span style="font-size:12pt">100 windows? This seems
an abomination to me;)</span></p>
<p><span style="font-size:12pt">Well, why throw away a window
you might need again sometime? ;-) Also, I can distribute
them over several separate spaces, which makes a quite
tidy impression.</span></p>
<p><span style="font-size:12pt"><br>
</span></p>
<p><span style="font-size:12pt">Best,</span></p>
<p><span style="font-size:12pt">Christoph</span></p>
<div id="Signature">
<div name="divtagdefaultwrapper"
style="font-family:Calibri,Arial,Helvetica,sans-serif;
font-size:; margin:0">
</div>
</div>
</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="divRplyFwdMsg" dir="ltr"><font style="font-size:11pt"
face="Calibri, sans-serif" color="#000000"><b>Von:</b>
Jeremy Landry <a class="moz-txt-link-rfc2396E" href="mailto:hakyoku@gmail.com"><hakyoku@gmail.com></a><br>
<b>Gesendet:</b> Samstag, 14. September 2019 07:29:46<br>
<b>An:</b> A friendly place to get answers to even the most
basic questions about Squeak.<br>
<b>Cc:</b> Thiede, Christoph<br>
<b>Betreff:</b> Re: [Newbies] Morphic is slow</font>
<div> </div>
</div>
<div>
<div dir="ltr">Oh and I forgot to mention how to test the
apple theory. If you move a bunch of rectangle morphs
individually and at the same time in the same direction as
if it's one static image, it will be slower than if you put
them all into a single playfield and moved the playfield by
itself as a single object. The catch is, that if you want
specific actions to happen to those morphs, you have to
conjure up a different way to interact with them than you
would if they were 'naked' and individual objects. I did a
personal test where I made 100 squares and moved them
individually and, as you would think, the frame rate dropped
dramatically. However, moving 100 squares inside of a
playfield and just moving the playfield, there was no
noticible change in frame rate.</div>
<div id="DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2"><br>
<table style="border-top:1px solid #d3d4de">
<tbody>
<tr>
<td style="width:55px; padding-top:13px"><a
href="https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=icon"
target="_blank" moz-do-not-send="true"><img alt=""
style="width: 46px; height: 29px; user-select:
none;"
src="https://ipmcdn.avast.com/images/icons/icon-envelope-tick-round-orange-animated-no-repeat-v1.gif"
moz-do-not-send="true" height="29" width="46"></a></td>
<td style="width:470px; padding-top:12px;
color:#41424e; font-size:13px;
font-family:Arial,Helvetica,sans-serif;
line-height:18px">
Virus-free. <a
href="https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=link"
target="_blank" style="color:#4453ea"
moz-do-not-send="true">
www.avast.com</a> </td>
</tr>
</tbody>
</table>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">On Fri, Sep 13, 2019 at
10:24 PM Jeremy Landry <<a
href="mailto:hakyoku@gmail.com" moz-do-not-send="true">hakyoku@gmail.com</a>>
wrote:<br>
</div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px
0.8ex; border-left:1px solid rgb(204,204,204);
padding-left:1ex">
<div dir="ltr">I've looked at morphic performance via
Etoys many times and am not certain if this ever got
addressed, but from my understanding, morphic doesn't do
anything to detect what should be drawn and what should
not (i.e. covered up items). So for instance, if you
move a window over a lot of other windows (or move your
mouse, it has to draw this too, afaik), then it's going
to redraw every unseen thing under neath. <br>
<br>
You can test this in a 'micro' example by looking at
frames per second by dragging a simple rectangle around
the screen over various stacks of other rectangles and
just the blank world. Instead of treating things that
aren't moving as a 'static image', it tries to redraw
every single thing affected from scratch. I did quite a
lot of research into 'how' morphic works in this way
when I was developing some action-game type stuff in
EToys. What I found is that the less dynamic things are
(i.e. static pictures, for instance where it simply
needs to be read from memory) vs. drawing things from
scratch (i.e. a rectangle morphic object), speed is
dramatically increased. So having 100 windows, each one
using drawing commands instead of reading memory would
definitely slow things down, even for just drawing the
mouse, I would think.
<div><br>
</div>
<div>Again, just my guess. There's a lot of
'workarounds' for this, but I think the biggest one
would be for morphic to figure out what is static and
what is moving, take proper bitmapped copy into a
buffer to redraw any 'mess' made by moving something.
I am not smart enough to program this so I can only
say what I think is the problem and what I think could
be done to fix it. <br>
<br>
<br>
There was a video on this phenomena using Cuis
Smalltalk and it exhibits the same issues, except they
used the bouncing atoms example, showing that atoms in
the morph drawing behind things still are drawn when
they don't need to be and as a result, would hurt the
rate of the screen updates.</div>
<div><br>
</div>
<div>I hope this helps in some way and maybe someone
smarter than me (and with spare time and will power)
can tackle this issue. Video performance can be much
greater even without using tricks like sending
everything to OpenGL or some such if this were looked
at and, imo, probably is really more an issue with
extremely old legacy objects and methods tied to
screen drawing regardless of morphic, but that's just
speculation on my part. I really don't know. </div>
<div><br>
</div>
<div>If it's of interest, some other things I've found
that speed things up is the number of times the same
methods are called by multiple objects. As an example,
it seems like if you have, say, 5 apples and you want
to move them from one desk to another, the quickest
way is to put the apples into a container then move
the container full of all the apples at once, but it
appears as if Smalltalk's solution is to move back and
forth 5 times between the two desks, each time
carrying a single apple. Again, this is just a hunch,
and if it were true, I wouldn't know the first thing
about fixing it or how much of a smalltalk image would
break as a result.</div>
<div><br>
</div>
<div><br>
</div>
<div><br>
</div>
<div><br>
</div>
</div>
<div
id="gmail-m_-1776581026489562128DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2"><br>
<table style="border-top:1px solid rgb(211,212,222)">
<tbody>
<tr>
<td style="width:55px; padding-top:13px"><a
href="https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=icon"
target="_blank" moz-do-not-send="true"><img
alt="" style="width: 46px; height: 29px;
user-select: none;"
src="https://ipmcdn.avast.com/images/icons/icon-envelope-tick-round-orange-animated-no-repeat-v1.gif"
moz-do-not-send="true" height="29"
width="46"></a></td>
<td style="width:470px; padding-top:12px;
color:rgb(65,66,78); font-size:13px;
font-family:Arial,Helvetica,sans-serif;
line-height:18px">
Virus-free. <a
href="https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=link"
target="_blank" style="color:rgb(68,83,234)"
moz-do-not-send="true">
www.avast.com</a> </td>
</tr>
</tbody>
</table>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">On Fri, Sep 13, 2019
at 10:05 PM Nicola Mingotti <<a
href="mailto:nmingotti@gmail.com" target="_blank"
moz-do-not-send="true">nmingotti@gmail.com</a>>
wrote:<br>
</div>
<blockquote class="gmail_quote" style="margin:0px 0px
0px 0.8ex; border-left:1px solid rgb(204,204,204);
padding-left:1ex">
<div bgcolor="#FFFFFF"><br>
100 windows? This seems an abomination to me;) <br>
<br>
Anyhow, this is what i am fancying:<br>
- Suppose you open each window in its own (green)
thread and give it an insignificant priority<br>
- When you click on one window then you increase
that thread priority, and make it good enough to be
interactive.<br>
<br>
I don't know if it is feasible, if it is, i fell it
will work;)<br>
<br>
Happy experimentation<br>
bye<br>
nicola<br>
<br>
<br>
<br>
<br>
<br>
<br>
<div
class="gmail-m_-1776581026489562128gmail-m_-6942649292964195966moz-cite-prefix">On
9/13/19 5:14 PM, Thiede, Christoph wrote:<br>
</div>
<blockquote type="cite">
<div
id="gmail-m_-1776581026489562128gmail-m_-6942649292964195966divtagdefaultwrapper"
dir="ltr">
<p>Hi all,</p>
<p><br>
</p>
<p>I'm sure this is a FAQ, but I still don't
know the perfect answer on it.</p>
<p>I often have opened more than 100 windows in
a project (no problem to keep an overview
using WindowAcrobatics), and it can be really
slow to operate the image when I move my
cursor over the world - often only 1 FPS.</p>
<p>I attached a MessageTally report because I
hope it reveals some anomalies that could be
specific to my image.</p>
<p><br>
</p>
<p>I see that my <span>CTStatusMonitorMorph*
costs some percents, but even if I disable
it, my FPS are often <= 10. Do you have
any tips for me?</span></p>
<p><span><br>
</span></p>
<p>Best,</p>
<p>Christoph</p>
<div
id="gmail-m_-1776581026489562128gmail-m_-6942649292964195966Signature">
</div>
</div>
<br>
<fieldset
class="gmail-m_-1776581026489562128gmail-m_-6942649292964195966mimeAttachmentHeader"></fieldset>
<pre class="gmail-m_-1776581026489562128gmail-m_-6942649292964195966moz-quote-pre">_______________________________________________
Beginners mailing list
<a class="gmail-m_-1776581026489562128gmail-m_-6942649292964195966moz-txt-link-abbreviated" href="mailto:Beginners@lists.squeakfoundation.org" target="_blank" moz-do-not-send="true">Beginners@lists.squeakfoundation.org</a>
<a class="gmail-m_-1776581026489562128gmail-m_-6942649292964195966moz-txt-link-freetext" href="http://lists.squeakfoundation.org/mailman/listinfo/beginners" target="_blank" moz-do-not-send="true">http://lists.squeakfoundation.org/mailman/listinfo/beginners</a>
</pre>
</blockquote>
<br>
</div>
_______________________________________________<br>
Beginners mailing list<br>
<a href="mailto:Beginners@lists.squeakfoundation.org"
target="_blank" moz-do-not-send="true">Beginners@lists.squeakfoundation.org</a><br>
<a
href="http://lists.squeakfoundation.org/mailman/listinfo/beginners"
rel="noreferrer" target="_blank"
moz-do-not-send="true">http://lists.squeakfoundation.org/mailman/listinfo/beginners</a><br>
</blockquote>
</div>
</blockquote>
</div>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<pre class="moz-quote-pre" wrap="">_______________________________________________
Beginners mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Beginners@lists.squeakfoundation.org">Beginners@lists.squeakfoundation.org</a>
<a class="moz-txt-link-freetext" href="http://lists.squeakfoundation.org/mailman/listinfo/beginners">http://lists.squeakfoundation.org/mailman/listinfo/beginners</a>
</pre>
</blockquote>
<br>
</body>
</html>