<commit_before>About
=====

Finch is a dead-simple OpenAL-based sound effect player for iPhone.
The reasons for writing Finch instead of sticking with Apple’s
AVAudioPlayer are described in my question on Stack Overflow:

http://stackoverflow.com/questions/986983

The goals are simple: (1) Play sound effects without much fuss,
and (2) do not lag in the `play` method as AVAudioPlayer does.
Finch is not meant to play background music. If you want to play
background music, you can simply stick to AVAudioPlayer. Finch
will play the sound effects over the background music just fine.

Howto
=====

    #import "Finch.h"
    #import "Sound+IO.h"

    // Initializes Audio Session, opens OpenAL device.
    Finch *soundEngine = [[Finch alloc] init];

    NSString *soundPath = [[[NSBundle mainBundle] resourcePath]
        stringByAppendingPathComponent:@"SFX/click.wav"];
    Sound *click = [[Sound alloc] initWithFile:path];
    [sample play];

This is alpha code, the interface will almost certainly change.
That said, it should be fairly easy to adapt to changes.

Bugs, gotchas
=============

Many people are having problems with OpenAL sound in the simulator.
I have not found a definitive answer from Apple, but it seems that
OpenAL simply does not work in the simulator. When run on the
simulator, Finch will warn you that OpenAL is probably not going
to work.

License
=======

You can do with this code whatever you like.

Links
=====

* http://github.com/zoul/Finch/
* http://www.subfurther.com/blog/?p=602
* http://connect.creativelabs.com/openal/Documentation/OpenAL_Programmers_Guide.pdf
* http://connect.creativelabs.com/openal/Documentation/OpenAL%201.1%20Specification.pdf<commit_msg>Better markup in README.<commit_after>About
=====

Finch is a dead-simple OpenAL-based sound effect player for iPhone.
The reasons for writing Finch instead of sticking with Apple’s
`AVAudioPlayer` are described in my [question on Stack Overflow][so].

[so]: http://stackoverflow.com/questions/986983

The goals are simple: (1) Play sound effects without much fuss,
and (2) do not lag in the `play` method as `AVAudioPlayer` does.
Finch is not meant to play background music. If you want to play
background music, you can go with `AVAudioPlayer`. Finch will
play the sound effects over the background music just fine.

Howto
=====

    #import "Finch.h"
    #import "Sound+IO.h"

    // Initializes Audio Session, opens OpenAL device.
    Finch *soundEngine = [[Finch alloc] init];

    NSString *soundPath = [[[NSBundle mainBundle] resourcePath]
        stringByAppendingPathComponent:@"SFX/click.wav"];
    Sound *click = [[Sound alloc] initWithFile:path];
    [sample play];

This is alpha code, the interface will almost certainly change.
That said, it should be fairly easy to adapt to changes.

Bugs, gotchas
=============

Many people are having problems with OpenAL sound in the simulator.
I have not found a definitive answer from Apple, but it seems that
OpenAL simply does not work in the simulator. When run on the
simulator, Finch will warn you that OpenAL is probably not going
to work.

License
=======

You can do with this code whatever you like.

Links
=====

* [Finch on github][git]
* [An iPhone OpenAL brain dump][dump]
* [OpenAL Programmer’s Guide][guide]

[git]: http://github.com/zoul/Finch/
[dump]: http://www.subfurther.com/blog/?p=602
[guide]: http://connect.creativelabs.com/openal/Documentation/OpenAL_Programmers_Guide.pdf
{'fraction_non_alphanumeric': 0.09936268829663963, 'fraction_numerical': 0.008111239860950173, 'mean_word_length': 4.328703703703703, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2417282', 'n_tokens_mistral': 1037, 'n_tokens_neox': 978, 'n_words': 421}