// probably only called from UI, // can err on the side of caution vs speed io_t net_inc_in_value(s32 inIdx, io_t inc) { op_t* op; /* print_dbg("\r\n incrementing input in network, value: "); */ /* print_dbg_hex(net_get_in_value(inIdx < 0 ? 0 : (u16)inIdx)); */ /* print_dbg(" , increment: "); */ /* print_dbg_hex(inc); */ if(inIdx >= net->numIns) { // hack to get param idx inIdx -= net->numIns; // set_param_value(inIdx, op_sadd(get_param_value(inIdx), inc)); // return get_param_value(inIdx); return inc_param_value(inIdx, inc); } else { op = net->ops[net->ins[inIdx].opIdx]; (*(op->inc_fn))(op, net->ins[inIdx].opInIdx, inc); print_dbg(" , result: "); print_dbg_hex( net_get_in_value(inIdx)); return net_get_in_value(inIdx); } }
// probably only called from UI, // can err on the side of caution vs speed io_t net_inc_in_value(s32 inIdx, io_t inc) { op_t* op; if(inIdx >= net->numIns) { // hack to get param idx inIdx -= net->numIns; return inc_param_value(inIdx, inc); } else { op = net->ops[net->ins[inIdx].opIdx]; op_inc_in_val(op, net->ins[inIdx].opInIdx, inc); return net_get_in_value(inIdx); } }