The InputOutputArray
is "placeholder" type. Parameters of this type are modified in place, inside the function.
There are other 2 types:
InputArray
which is read-only inside the function. This parameters are used as source data for the function, but are not modified by the function.
OutputArray
which is write-only. Parameters of this type are modified inside the function. Usually this means they are created inside the function. This means that data in the array are replaced by the data generated by the function.
This principle is used so the function can "return" more than one value.