[PD-dev] how math objects respond to a bang

Hans-Christoph Steiner hans at eds.org
Wed Feb 8 15:33:06 CET 2006


On Feb 8, 2006, at 5:20 AM, Thomas Grill wrote:

>>
>> well the difference is, that [+],... are binops while [sin],... are  
>> unary
>> operations.
>>
>>
>> the [bang(-method for binops is there for things like
>> |
>> [t b f]
>> |     |
>> [+    ]
>> |
>>
>>
>> since this is not needed it is not there for unops.
>
> I wonder what should be outout by a bang to a unary object.
> Right now the result of the last operation is not stored - a  
> respective field would have to be added to the object.
> That's exactly what an [f] object does in a patch.

Except that you can't force [atan2] to recalculate when you only update  
the number on the right inlet if the [float] stores the result.  You'd  
have to do this:

   |
   [t b f]
  /       \
[float]  |
\        /
  [atan2]
  |

This is then the exact same as an [atan2] bang method, which all other  
2-inlet math objects have.

.hc

________________________________________________________________________ 
____

"I have the audacity to believe that peoples everywhere can have three  
meals a day for their bodies, education and culture for their minds,  
and dignity, equality and freedom for their spirits."
                                             - Martin Luther King, Jr.





More information about the Pd-dev mailing list