ShiftPixAttrib

Declaration: TMetaData.ShiftPixAttrib (AttribLayer, Delta: integer; ShiftNames: boolean);
Shifts all pixel attributes of the attribute layer AttribLayer (valid range: 0 to 4) by a value of Delta. If the AttribLayer parameter is zero, all four layers of the attributes are shifted simultaneously. If any of the attributes become either negative of greater than 127 they are automatically limited to 0 or 127, respectively. The parameter ShiftNames controls whether the attribute names are shifted as well.

Please keep in mind that shifting the attributes of a single attribute layer will result in wrong attribute names after the shift. Which attribute layers fall out of sync depends on the parameter ShiftNames.

Hint: In order to directly access the metadata of the currently loaded dataset you can use the pre-declared global variable MData.