<br><br>
<div class="gmail_quote">On Wed, Mar 25, 2009 at 10:22 AM, marius schebella <span dir="ltr">&lt;<a href="mailto:marius.schebella@gmail.com">marius.schebella@gmail.com</a>&gt;</span> wrote:<br></div>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">hi john,<br>I just looked at your patches, here&#39;s what I think:<br>1) pix_buffer_write seems to copy and clear the pix buffer. so if your<br>
pix_video is connected to pix_buffer_write it is gone and you don&#39;t<br>see it anymore (rectangle stays white). I am not sure if this is a<br>bug, it seems strange to me, too. but as soon as you disconnect the<br>pix_buffer_write the image will be shown on the rotated rectangle.</blockquote>

<div class="gmail_quote"> </div>
<div class="gmail_quote">Yes I also noticed that disconnecting the [pix_buffer_write] fixes the problem. i see that sort of thing in Gem all the time ([pix_mix] for example.) But wouldn&#39;t a [pix_separator] fix this then? It doesn&#39;t...</div>

<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid"><span id=""></span><br>2) the rotateXYZ does not rotate the pixels, but only the geometry<br>that this texture is mapped to (the rectangle). so in your left<br>
example you go from gemhead through buffer_read, texture to the<br>rectangle. in that line no rotationXYZ is applied to the rectangle.<br>marius.</blockquote>
<div class="gmail_quote">So why does the right example work? Because the rotation happens after the [pix_buffer_write] even though [pix_buffer_write] is later in the rendering chain? Or perhaps the rotation is ignored by [pix_buffer_write]? And at the same time [pix_buffer_write] sends the output of the rotation as a &quot;passthrough&quot; on its outlet? And also you are saying it would be normal and expected for the output of [pix_buffer_write] to be different than what [pix_buffer_write] is actually storing? If that isn&#39;t the case, example 1 and example 3 should produce the same results.</div>

<div class="gmail_quote"> </div>
<div class="gmail_quote">Perhaps I need some rules about how Gem is different than Pd in terms of dataflow. So far it seems to me that a rendering chain in Gem shows conections but does not reveal the order in which these connections are processed i.e. if 3 objects are all connected to each other in a rendering chain in Gem i.e.</div>

<div class="gmail_quote"> </div>
<div class="gmail_quote">[Gemhead]</div>
<div class="gmail_quote">|</div>
<div class="gmail_quote">[object 1]</div>
<div class="gmail_quote">|</div>
<div class="gmail_quote">[object 2]</div>
<div class="gmail_quote">|</div>
<div class="gmail_quote">[object 3]</div>
<div class="gmail_quote"> </div>
<div class="gmail_quote">we cannot conclude that the output of [object 1] feeds the input of [object 2] and the output of [object 2] feeds the input of [object 3]. We only know that the data will be processed by objects 1, 2 and 3 but not in what order they will be processed.</div>

<div class="gmail_quote"> </div>
<div class="gmail_quote">Further perhaps we cannot conclude that the output of an object is actually the result of the object having processed the data. Demonstrating this: in my patch example, [pix_buffer_write] outputs different data than it stores, or examples 1 and 3 would be the same.</div>

<div class="gmail_quote"> </div>
<div class="gmail_quote">And this leads me to a more general statement of my original question: how can I determine the order in which objects are processed in Gem?</div>
<div class="gmail_quote"> </div>
<div class="gmail_quote">And my specific example which started this thread: how would one apply a rotation to an image, then apply [pix_rtx] to the rotated image?</div>
<div class="gmail_quote"> </div>
<div class="gmail_quote">-John</div>
<div class="gmail_quote"> </div>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid"><span id=""></span><br><br>2009/3/24 John Harrison &lt;<a href="mailto:john.harrison@alum.mit.edu">john.harrison@alum.mit.edu</a>&gt;:<br>

<div>
<div></div>
<div class="h5">&gt; Attached is a small example patch of how I just don&#39;t get Gem...still...<br>&gt;<br>&gt; [pix_rtx] has a steady wave that normally flows from left to right.<br>&gt;<br>&gt; I would have thought that the attached patch shows me rotating the image<br>
&gt; first, then applying [pix_rtx]. So it would stand to reason in my mind I<br>&gt; would see a rotated image with [pix_rtx] flowing from left to right.<br>&gt;<br>&gt; But that isn&#39;t the result I see. The patch has [pix_rtx] flowing from right<br>
&gt; to left now. It is as if [pix_rtx] is applied *before* the rotation instead<br>&gt; of *after* as I would have expected.<br>&gt;<br>&gt; Grasping at straws, I have tried [pix_separator] between just about every<br>&gt; object, but that makes no difference.<br>
&gt;<br>&gt; What am I misunderstanding that makes the behavior of the patch make sense?<br>&gt; And...how would I get [pix_rtx] to flow from left to right on a mirrored<br>&gt; image?<br>&gt;<br>&gt; -John<br>&gt;<br>&gt; P.S. Are questions like this better on the Gem-dev list? That&#39;s a developer<br>
&gt; list but at the same time I feel a bit awkward putting too many Gem<br>&gt; questions on a Pd list<br>&gt;<br>&gt;<br></div></div>
<div>
<div></div>
<div class="h5">&gt; #N canvas 962 171 305 227 10;<br>&gt; #X obj 29 -58 gemhead;<br>&gt; #X obj 29 -35 pix_video;<br>&gt; #X obj 29 44 pix_texture;<br>&gt; #X obj 28 72 rectangle 4 3;<br>&gt; #X obj 159 9 gemwin;<br>&gt; #X msg 136 -34 create \, 1;<br>
&gt; #X msg 214 -33 destroy;<br>&gt; #X obj 135 -57 loadbang;<br>&gt; #X obj 29 17 pix_rtx;<br>&gt; #X obj 29 -10 rotateXYZ 0 180 0;<br>&gt; #X connect 0 0 1 0;<br>&gt; #X connect 1 0 9 0;<br>&gt; #X connect 2 0 3 0;<br>&gt; #X connect 5 0 4 0;<br>
&gt; #X connect 6 0 4 0;<br>&gt; #X connect 7 0 5 0;<br>&gt; #X connect 8 0 2 0;<br>&gt; #X connect 9 0 8 0;<br>&gt;<br>&gt; _______________________________________________<br>&gt; <a href="mailto:Pd-list@iem.at">Pd-list@iem.at</a> mailing list<br>
&gt; UNSUBSCRIBE and account-management -&gt;<br>&gt; <a href="http://lists.puredata.info/listinfo/pd-list" target="_blank">http://lists.puredata.info/listinfo/pd-list</a><br>&gt;<br>&gt;<br></div></div></blockquote><br>