Bit Depth From Channel Mode

The Channel Mode property contains a bit depth value on file types where appropriate. Two actions are supplied which can be used to extract the bit depth from the property. The Text variant extracts the value as text. For example 16 bit. The Numeric variant extracts only the integer value. For example 16. Both actions return the value in Variable 1. If the bit depth was not available, Variable 1 will be empty.

----- Start of action 'Extract Bit Depth from Channel Mode - Text'

'

Extract the bit depth from the Channel Mode, if available.

Variable 1 either contains '# bit' or will be empty.

Get Property Channel Mode -> Variable 1

Find "," from the end in Variable 1, remove it and everything before, set state

if true

Trim Variable 1 (SP) [Leading] [Trailing]

else

Clear Variable 1

endif

----- End of action 'Extract Bit Depth from Channel Mode - Text'

----- Start of action 'Extract Bit Depth from Channel Mode - Numeric'

'

Extract the bit depth from the Channel Mode, if available.

Variable 1 either contains an integer value or will be empty.

Get Property Channel Mode -> Variable 1

Find "," from the end in Variable 1, remove it and everything before, set state