Personal tools
You are here: Home documentation FAQ for Pd What is the difference between the [list] and [pack] objects?
Document Actions

What is the difference between the [list] and [pack] objects?

Up to Table of Contents

What is the difference between the [list] and [pack] objects? Which is the best to use if I want to generate a [X Y( message ?
  • [pack] creates a compound list from input atoms of a preset type (symbol float or pointer).
  • [list] creates (appends) a compound list from two input lists (these could be a floats or symbols because [list] will a convert these input elements to lists automatically).
  • [list] itself is not really an object but a wrapper for [list append], the list family is made up of ![list append], [list prepend], [list split], [list trim] and [list length]

So, for two input floats there is no matter which to use?

If you are using floats it is best practice to use [pack], as it has type recognition and will output errors if a foreign type tries to get calculated. And of course [pack] can handle more than two inputs..

by IOhannes m zmoelnig last modified 2008-05-07 10:02 AM

Powered by IEM Powered by Plone Section 508 WCAG Valid XHTML Valid CSS Usable in any browser