Colet Patrice
----- Mail original ----- > De: "João Pais" <[email protected]> > À: "pd-list" <[email protected]>, "Patrice Colet" <[email protected]> > Envoyé: Vendredi 21 Juin 2013 10:00:58 > Objet: Re: [PD] Data structures: no object for freeing pointers? > > > Yes with visibility setting we can access an element of an array > > only, > > so each state can be stored, retrieved, replaced at will by > > accessing an > > element of te array... The matter is how accessing an element, > > idealy it > > would be a [nbx] where max value is the number of array elements, > > or a > > that's very easy, just get the number of elements from the array's > pointer, and send it as [max $1( to the nbox (or whichever command > defines > the limits, I don't have Pd open). > Without opening pd I think it's something like range $1 $2 and that's what I'm doing when controlling DS from GOP, it seems the best way to go.. I'd like one day to understand how to implement DS into a GOP, it's a bit triky, then on a single window it's possible to have the whole interface. > > scalar but I don't how it's possible to fix limits to [drawnumber] > > I think not from the gui. Unless you enforce it programatically: > route the > "change" output from the [struct] in the template, and use it to > force the > maximum number to a [set] object. Like: > > [struct drawnumber...] > | > [route change] > | > [50( (assuming 50 is the current max number) > | > [set drawnumber...] > > > In a parallel part, the current pointer gets and sets the maximum > number > of elements (now at 50) > > Look at the current help file for [drawnumber] for more details. > it's not really possible to do this in the context we're talking about because we don't know which scalar is modified when it's embedded into an array, a way would be about using y value, but in this case y is always = 0 > > >> De: "João Pais" <[email protected]> > >> À: "pd-list" <[email protected]>, "Patrice Colet" > >> <[email protected]> > >> Envoyé: Jeudi 20 Juin 2013 11:09:26 > >> Objet: Re: [PD] Data structures: no object for freeing pointers? > >> > >> One approach is to assign a variable for active/unactive scalars. > >> And > >> then > >> use that variable to render the scalar visible/invisible. After a > >> work > >> session, the user can hide the active scalars, display the > >> inactive > >> ones, > >> and select + delete these. It's still far from ideal, but a > >> compromise. > >> > >> > > >> >> Envoyé: Mardi 11 Juin 2013 11:25:23 > >> >> Objet: Re: [PD] Data structures: no object for freeing > >> >> pointers? > >> >> > >> >> On Die, 2013-06-11 at 11:00 +0200, Jan Baumgart wrote: > >> >> > I've been building a sequencer with data structs. But now > >> >> > I've > >> >> > come > >> >> > to a > >> >> > dead end, because there seems to be no object, that let's you > >> >> > remove > >> >> > structs. > >> >> > The only way seems to be deleting them in the gui. > >> >> > >> > > >> > It's still possible to put only one pointer and then arrays on > >> > it, > >> > then > >> > you can add or delete at the last array item, or it's possible > >> > to > >> > put an > >> > id at each array element and then remove the element id to > >> > delete, > >> > then > >> > it's possible to have undo's. > >> > > >> > pc > >> > > >> > _______________________________________________ > >> > [email protected] mailing list > >> > UNSUBSCRIBE and account-management -> > >> > http://lists.puredata.info/listinfo/pd-list > _______________________________________________ [email protected] mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
