preset-unpack

bradzilla84/preset-select/preset-unpack

UnPack a Preset
preset-unpack
@/preset-unpack
UnPack a Preset
IN@/preset-pack
Packed Preset
preset-unpack
IN
Num1
Num2
Num3
Num3number
Unpacked Number 3
Num2number
Unpacked Number 2
Num1number
Unpacked Number 1
To use the node in your project you should have the bradzilla84/preset-select library installed. Use the “File → Add Library” menu item in XOD IDE if you don’t have it yet. See Using libraries for more info.

C++ implementation

struct State {
};

{{ GENERATED_CODE }}

void evaluate(Context ctx) {

    auto Pack = getValue<input_IN>(ctx);    //Get Packed Preset

    emitValue<output_Num1>(ctx, Pack.N1);   //Update each pin with it's Packed Number
    emitValue<output_Num2>(ctx, Pack.N2);
    emitValue<output_Num3>(ctx, Pack.N3);
}