# getNibbleAddress

## Syntax

#include "dsptool.h"
u32 getNibbleAddress(u32 samples);

## Parameters

samples |
Indexed number of samples (zero-based). Zero is the first sample; 100 is the 101st sample. |

## Return Values

Corresponding nibble address.

## Description

`getNibbleAddress`

calculates and returns the corresponding nibble for a sample at a given offset.
For example, the 100th sample (counting from zero) corresponds to the 116th nibble (also counting from zero).

NOTE:

The calculated nibble address already accounts for the 2-nibble frame headers of the DSP-ADPCM compression format.

Another example: the zero^{th} sample corresponds to nibble offset 2, which is the third nibble (counting from zero).

## Do Not Call From

Wii U (Host PC only) |
Do not call this function on the Wii U console. It is available only on the host PC. |

## Revision History

2013/05/08 Automated cleanup pass.

2011/02/21 Initial version.

CONFIDENTIAL