[PD] Loading order of pd objects

Hans-Christoph Steiner hans at eds.org
Wed Feb 25 21:58:05 CET 2009


On Feb 25, 2009, at 3:50 PM, Frank Barknecht wrote:

> Hallo,
> Robert Gr?ndler hat gesagt: // Robert Gr?ndler wrote:
>
>> For example when i create a patch with 2 objects that are not  
>> connected
>> in any way,
>> in which order will they be created by pd when the patch is loaded ?
>
> The order you created them, but it's very bad practice to rely on  
> that,
> because it's an implementation detail that may change in future
> versions and it's generally error prone because you cannot see the
> creation order.
>
> You can test this with an abstraction that prints something with a
> loadbang, like:
>
> testme.pd:
>
> [loadbang]
> |
> [f $1]
> |
> [print]
>
> testme-for-real.pd:
>
> [testme 1]
> [testme 2]
>
> Then open testme-for-real.pd again.

I agree with Frank here, but I will give you the gun of knowledge with  
which to shot yourself in the foot with:

If you read the .pd file in a text editor, you can see the order of  
creation.  The file is read top-to-bottom, in one pass.

.hc


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



----------------------------------------------------------------------------

Computer science is no more related to the computer than astronomy is  
related to the telescope.      -Edsger Dykstra






More information about the Pd-list mailing list