Taylor Holberton | f1080d3 | 2017-04-06 23:04:06 -0700 | [diff] [blame] | 1 | /* interval.h |
| 2 | ** |
| 3 | ** Copyright 2011, The Android Open Source Project |
| 4 | ** |
| 5 | ** Redistribution and use in source and binary forms, with or without |
| 6 | ** modification, are permitted provided that the following conditions are met: |
| 7 | ** * Redistributions of source code must retain the above copyright |
| 8 | ** notice, this list of conditions and the following disclaimer. |
| 9 | ** * Redistributions in binary form must reproduce the above copyright |
| 10 | ** notice, this list of conditions and the following disclaimer in the |
| 11 | ** documentation and/or other materials provided with the distribution. |
| 12 | ** * Neither the name of The Android Open Source Project nor the names of |
| 13 | ** its contributors may be used to endorse or promote products derived |
| 14 | ** from this software without specific prior written permission. |
| 15 | ** |
| 16 | ** THIS SOFTWARE IS PROVIDED BY The Android Open Source Project ``AS IS'' AND |
| 17 | ** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
| 18 | ** IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE |
| 19 | ** ARE DISCLAIMED. IN NO EVENT SHALL The Android Open Source Project BE LIABLE |
| 20 | ** FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
| 21 | ** DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR |
| 22 | ** SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER |
| 23 | ** CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT |
| 24 | ** LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY |
| 25 | ** OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH |
| 26 | ** DAMAGE. |
| 27 | */ |
| 28 | |
| 29 | #ifndef TINYALSA_INTERVAL_H |
| 30 | #define TINYALSA_INTERVAL_H |
| 31 | |
| 32 | #include <stdlib.h> |
Baruch Siach | 685e530 | 2017-06-02 12:19:03 +0300 | [diff] [blame] | 33 | #include <unistd.h> |
Taylor Holberton | f1080d3 | 2017-04-06 23:04:06 -0700 | [diff] [blame] | 34 | |
| 35 | /** A closed range signed interval. */ |
| 36 | |
| 37 | struct tinyalsa_signed_interval { |
| 38 | /** The maximum value of the interval */ |
| 39 | ssize_t max; |
| 40 | /** The minimum value of the interval */ |
| 41 | ssize_t min; |
| 42 | }; |
| 43 | |
| 44 | /** A closed range unsigned interval. */ |
| 45 | |
| 46 | struct tinyalsa_unsigned_interval { |
| 47 | /** The maximum value of the interval */ |
| 48 | size_t max; |
| 49 | /** The minimum value of the interval */ |
| 50 | size_t min; |
| 51 | }; |
| 52 | |
| 53 | #endif /* TINYALSA_INTERVAL_H */ |
| 54 | |