GetFormatFromSub
Description
Obtains the actual format based on the input primary format and sub-format.
The actual format is 4-byte long. The higher 4 bits of the first byte are reserved, and the lower 4 bits are C0 format. The second and third bytes describe the sub-format, and the fourth byte describes the primary format, as shown in the following:
/*
* ---------------------------------------------------
* | 4 bits | 4bits | 2 bytes | 1 byte |
* |------------|-------------|----------------|--------|
* | reserved | C0 format | Sub format | format |
* ---------------------------------------------------
*/
Prototype
inline int32_t GetFormatFromSub(int32_t primary_format, int32_t sub_format)
Parameters
Parameter |
Input/Output |
Description |
|---|---|---|
primary_format |
Input |
Primary format information. Must be within 0xffU. |
sub_format |
Input |
Sub-format information. Must be within 0xffffU. |
Returns
The actual format corresponding to the primary format and sub-format.
Exception Handling
None
Restrictions
None