cscg22-gearboy

CSCG 2022 Challenge 'Gearboy'
git clone https://git.sinitax.com/sinitax/cscg22-gearboy
Log | Files | Refs | sfeed.txt

sample.h (574B)


      1/** @file gb/sample.h
      2    Playback raw sound sample with length len from start at 8192Hz rate.
      3    len defines the length of the sample in samples/32 or bytes/16.
      4    The format of the data is unsigned 4-bit samples,
      5    2 samples per byte, upper 4-bits played before lower 4 bits.
      6
      7    Adaption for GBDK by Lars Malmborg.
      8    Original code by Jeff Frohwein.
      9*/
     10#ifndef _SAMPLE_H
     11#define _SAMPLE_H
     12
     13#include <types.h>
     14#include <stdint.h>
     15
     16/** Play the given, appropriatly formatted sample.
     17 */
     18void play_sample(uint8_t *start, uint16_t len) OLDCALL;
     19
     20#endif /* _SAMPLE_H */