Register a method to handle current dimensions update.
void ssAddOutputDimsDependencyRule(SimStruct *S, int_T outIdx, DimsDependInfo_T *ruleInfo)
S
SimStruct representing an S-Function block.
outIdx
Output port index.
ruleInfo
Structure containing the dimensions propagation method information.
No return value
Use this function in mdlSetWorkWidths
to register a method that
updates the dimensions for the output port when there is a change in the current
input signal dimensions. The method is for the case when the output signal size
depends only on the input signal size. It is called only when a dimensions update is
necessary, instead of calling in each sim loop pass.
Requires you to set up a ruleinfo struct, which includes
int *inputs — Index to inputs whose dimensions affect the output dimensions
int numInputs — Number of inputs that affect the output dimensions
SetOutputDimsFcn — Function to update the output dimensions based on the input dimensions.