N64® Functions Menu

al - Audio Library Functions
gDP - DP GBI Macros
gdSP - General GBI Macros
gSP - SP GBI Macros
gt - Turbo Microcode RDP
gu - Graphics Utilities
Math - Math Functions
Mus - Mus Library
nuSys - NuSystem
os - N64 Operating System
sp - Sprite Library Functions
uh - Host to Target IO
64DD - N64 Disk Drive

Nintendo® Confidential




Mus Library Reference


MusHandleWaveCount()

Get the wave lookup table count.

Syntax

  int MusHandleWaveAddress(musHandle handle);

Arguments

  • handle is the sound handle

Explanation
Get the number of entries in the wave lookup table being used for the sound channels associated with the specified sound handle. The wave lookup table is used by the library to convert internal sample numbers in songs and sound effect banks to sample bank indexes.

The handle must be a sound handle returned by MusStartSong(), MusStartSongFromMarker(), MusStartEffect() or MusStartEffect2(). If a handle of zero is supplied, this function will always return zero.

Return Value
Wave table lookup size.

Example

  unsigned short *DuplicateLookUp(musHandle handle)
  {
    int I, count;
    unsigned short *src, *dest;

    count = MusHandleWaveCount(handle);
    dest = MemMalloc(sizeof(unsigned short)*count);
    src = MusHandleWaveAddress(handle);

    for (I=0; I<count; I++)
      dest[I]=src[I];

    return (dest);
  }

See Also
MusHandleWaveAddress()


Nintendo® Confidential

Warning: all information in this document is confidential and covered by a non-disclosure agreement. You are responsible for keeping this information confidential and protected. Nintendo will vigorously enforce this responsibility.


Copyright © 1998-1999
Nintendo of America Inc. All rights reserved
Nintendo and N64 are registered trademarks of Nintendo
Last updated March 1999