Skip to content

How might one change the number of inlets based on an attribute value? #8

@CheeseTurtle

Description

@CheeseTurtle

Hi,
I'm trying to make an object that is a cross between select~ and radiogroup. I've successfully created a select~ clone that changes the number of inlets based on an argument, and I've also created a radiogroup clone that enables the user to change a value by clicking on the corresponding radiobutton and represents the radiobuttons' state graphically.

Now it is time to put them together and I've just realized that you can't really modify the arguments of graphical objects after they have been created, as their box is no longer visible once they have been rendered in their UI form.

I've tried just calling dsp_setup() again with the new number of inlets, but that seems to add around a hundred inlets (with no apparent relationship to the attribute value). Do I need to stop relying on dsp_setup() and just manually create and remove proxies? (And if so, how and when might I go about doing that?)

Alternatively, might there be a way to completely reinstantiate the object, carrying over all struct member and attribute values except for the number of inlets?

Or is what I am trying to do impossible?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions