On 26/07/10 17:14, Mathieu Bouchard wrote:
On Thu, 15 Jul 2010, Hans-Christoph Steiner wrote:
On Jul 15, 2010, at 11:59 AM, Mathieu Bouchard wrote:
Oops, right. I looked at my auto-screenshot tool, which uses
[folder_list], and it's using a messagebox with "add2", to build a
list from the output of [folder_list]. But I only remembered using
the list, not how I got to have a list in the first place.
Seems like [folder_list] should probably output a proper list... can
anyone shed any light on the advantages of the two approaches?

Getting a folder listing is not an atomic operation, and interfaces that try present it as atomic are made of fail (for example, try using GIMP's file open dialog in a directory containing 10000+ files - I ended up having to kill GIMP from the console because I couldn't wait for the "cancel" button to be operable).

the list output approach allows to use [list split] on it in any way you
want... go back and forth... access items by index.

First-next and start-next approaches are good when you're really thin on
memory and have lots of files, which is very relative, considering how
much RAM we have to waste these days.

The latter would have more of an advantage if you needed to output
multi-element entries, especially when those entries have variable
number of elements, but that typically doesn't happen with something
like [folder_list] (it could happen for some other classes for which
you'd ask yourself that question). It's related to the lack of
nested-lists in Pd.


Claude
--
http://claudiusmaximus.goto10.org

_______________________________________________
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list

Reply via email to