| line | stmt | bran | cond | sub | pod | time | code | 
| 1 |  |  |  |  |  |  | package SDL2::AudioCVT { | 
| 2 | 2 |  |  | 2 |  | 16 | use SDL2::Utils; | 
|  | 2 |  |  |  |  | 3 |  | 
|  | 2 |  |  |  |  | 21 |  | 
| 3 |  |  |  |  |  |  | has | 
| 4 |  |  |  |  |  |  | needed       => 'int', | 
| 5 |  |  |  |  |  |  | src_format   => 'uint16',    # SDL_AudioFormat | 
| 6 |  |  |  |  |  |  | dst_format   => 'uint16',    # SDL_AudioFormat | 
| 7 |  |  |  |  |  |  | rate_incr    => 'double', | 
| 8 |  |  |  |  |  |  | buf          => 'opaque',    # uint8 * | 
| 9 |  |  |  |  |  |  | len          => 'int', | 
| 10 |  |  |  |  |  |  | len_cvt      => 'int', | 
| 11 |  |  |  |  |  |  | len_mult     => 'int', | 
| 12 |  |  |  |  |  |  | len_ratio    => 'double', | 
| 13 |  |  |  |  |  |  | filters      => 'opaque',    #SDL_AudioFilter[SDL_AUDIOCVT_MAX_FILTERS + 1]; | 
| 14 |  |  |  |  |  |  | filter_index => 'int'; | 
| 15 |  |  |  |  |  |  |  | 
| 16 |  |  |  |  |  |  | =encoding utf-8 | 
| 17 |  |  |  |  |  |  |  | 
| 18 |  |  |  |  |  |  | =head1 NAME | 
| 19 |  |  |  |  |  |  |  | 
| 20 |  |  |  |  |  |  | SDL2::AudioCVT - The Structure that Holds a Set of Audio Conversion Filters | 
| 21 |  |  |  |  |  |  |  | 
| 22 |  |  |  |  |  |  | =head1 SYNOPSIS | 
| 23 |  |  |  |  |  |  |  | 
| 24 |  |  |  |  |  |  | use SDL2 qw[:all]; | 
| 25 |  |  |  |  |  |  | # TODO: I need to whip up a quick example | 
| 26 |  |  |  |  |  |  |  | 
| 27 |  |  |  |  |  |  | =head1 DESCRIPTION | 
| 28 |  |  |  |  |  |  |  | 
| 29 |  |  |  |  |  |  | SDL2::AudioCVT is a structure to hold a set of audio conversion filters and | 
| 30 |  |  |  |  |  |  | buffers. | 
| 31 |  |  |  |  |  |  |  | 
| 32 |  |  |  |  |  |  | Note that various parts of the conversion pipeline can take advantage of SIMD | 
| 33 |  |  |  |  |  |  | operations (like SSE2, for example). SDL2::AudioCVT doesn't require you to pass | 
| 34 |  |  |  |  |  |  | it aligned data, but can possibly run much faster if you set both its (C) | 
| 35 |  |  |  |  |  |  | field to a pointer that is aligned to 16 bytes, and its (C) field to | 
| 36 |  |  |  |  |  |  | something that's a multiple of 16, if possible. | 
| 37 |  |  |  |  |  |  |  | 
| 38 |  |  |  |  |  |  | =head1 Fields | 
| 39 |  |  |  |  |  |  |  | 
| 40 |  |  |  |  |  |  | =over | 
| 41 |  |  |  |  |  |  |  | 
| 42 |  |  |  |  |  |  | =item C - Set to 1 if conversion possible | 
| 43 |  |  |  |  |  |  |  | 
| 44 |  |  |  |  |  |  | =item C - Source audio format | 
| 45 |  |  |  |  |  |  |  | 
| 46 |  |  |  |  |  |  | =item C - Target audio format | 
| 47 |  |  |  |  |  |  |  | 
| 48 |  |  |  |  |  |  | =item C - Rate conversion increment | 
| 49 |  |  |  |  |  |  |  | 
| 50 |  |  |  |  |  |  | =item C - Buffer to hold entire audio data | 
| 51 |  |  |  |  |  |  |  | 
| 52 |  |  |  |  |  |  | =item C - Length of original audio buffer | 
| 53 |  |  |  |  |  |  |  | 
| 54 |  |  |  |  |  |  | =item C - Length of converted audio buffer | 
| 55 |  |  |  |  |  |  |  | 
| 56 |  |  |  |  |  |  | =item C - Buffer must be C big | 
| 57 |  |  |  |  |  |  |  | 
| 58 |  |  |  |  |  |  | =item C - Given C, final size is C | 
| 59 |  |  |  |  |  |  |  | 
| 60 |  |  |  |  |  |  | =item C - List of filter functions | 
| 61 |  |  |  |  |  |  |  | 
| 62 |  |  |  |  |  |  | =item C - Current audio conversion function | 
| 63 |  |  |  |  |  |  |  | 
| 64 |  |  |  |  |  |  | =back | 
| 65 |  |  |  |  |  |  |  | 
| 66 |  |  |  |  |  |  | =head1 AUTHOR | 
| 67 |  |  |  |  |  |  |  | 
| 68 |  |  |  |  |  |  | Sanko Robinson Esanko@cpan.orgE | 
| 69 |  |  |  |  |  |  |  | 
| 70 |  |  |  |  |  |  | =begin stopwords | 
| 71 |  |  |  |  |  |  |  | 
| 72 |  |  |  |  |  |  |  | 
| 73 |  |  |  |  |  |  | =end stopwords | 
| 74 |  |  |  |  |  |  |  | 
| 75 |  |  |  |  |  |  | =cut | 
| 76 |  |  |  |  |  |  |  | 
| 77 |  |  |  |  |  |  | }; | 
| 78 |  |  |  |  |  |  | 1; |