diff options
author | Nils Wallménius <nils@rockbox.org> | 2013-12-11 22:59:14 +0100 |
---|---|---|
committer | Nils Wallménius <nils@rockbox.org> | 2013-12-16 21:13:23 +0100 |
commit | e3c2ed7a71f65dc721c7210f120259ecd4ff65cb (patch) | |
tree | de593c1e927dcc036f1b6656f1f881995491b3b9 /lib/rbcodec/codecs/libopus/celt/os_support.h | |
parent | d0918b98fa0cfba21208a4fb5ed153687b8f02c3 (diff) | |
download | rockbox-e3c2ed7a71f65dc721c7210f120259ecd4ff65cb.tar.gz rockbox-e3c2ed7a71f65dc721c7210f120259ecd4ff65cb.zip |
Sync libopus to upstream release 1.1
Change-Id: I9fea7460fc33f60faff961b3389dd97b5191463c
Diffstat (limited to 'lib/rbcodec/codecs/libopus/celt/os_support.h')
-rw-r--r-- | lib/rbcodec/codecs/libopus/celt/os_support.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/lib/rbcodec/codecs/libopus/celt/os_support.h b/lib/rbcodec/codecs/libopus/celt/os_support.h index 2484f0b2f7..5e47e3cff9 100644 --- a/lib/rbcodec/codecs/libopus/celt/os_support.h +++ b/lib/rbcodec/codecs/libopus/celt/os_support.h | |||
@@ -35,13 +35,16 @@ | |||
35 | # include "custom_support.h" | 35 | # include "custom_support.h" |
36 | #endif | 36 | #endif |
37 | 37 | ||
38 | #include "opus_types.h" | ||
39 | #include "opus_defines.h" | ||
40 | |||
38 | #include <string.h> | 41 | #include <string.h> |
39 | #include <stdio.h> | 42 | #include <stdio.h> |
40 | #include <stdlib.h> | 43 | #include <stdlib.h> |
41 | 44 | ||
42 | /** Opus wrapper for malloc(). To do your own dynamic allocation, all you need to do is replace this function and opus_free */ | 45 | /** Opus wrapper for malloc(). To do your own dynamic allocation, all you need to do is replace this function and opus_free */ |
43 | #ifndef OVERRIDE_OPUS_ALLOC | 46 | #ifndef OVERRIDE_OPUS_ALLOC |
44 | static inline void *opus_alloc (size_t size) | 47 | static OPUS_INLINE void *opus_alloc (size_t size) |
45 | { | 48 | { |
46 | return malloc(size); | 49 | return malloc(size); |
47 | } | 50 | } |
@@ -49,7 +52,7 @@ static inline void *opus_alloc (size_t size) | |||
49 | 52 | ||
50 | /** Same as celt_alloc(), except that the area is only needed inside a CELT call (might cause problem with wideband though) */ | 53 | /** Same as celt_alloc(), except that the area is only needed inside a CELT call (might cause problem with wideband though) */ |
51 | #ifndef OVERRIDE_OPUS_ALLOC_SCRATCH | 54 | #ifndef OVERRIDE_OPUS_ALLOC_SCRATCH |
52 | static inline void *opus_alloc_scratch (size_t size) | 55 | static OPUS_INLINE void *opus_alloc_scratch (size_t size) |
53 | { | 56 | { |
54 | /* Scratch space doesn't need to be cleared */ | 57 | /* Scratch space doesn't need to be cleared */ |
55 | return opus_alloc(size); | 58 | return opus_alloc(size); |
@@ -58,7 +61,7 @@ static inline void *opus_alloc_scratch (size_t size) | |||
58 | 61 | ||
59 | /** Opus wrapper for free(). To do your own dynamic allocation, all you need to do is replace this function and opus_alloc */ | 62 | /** Opus wrapper for free(). To do your own dynamic allocation, all you need to do is replace this function and opus_alloc */ |
60 | #ifndef OVERRIDE_OPUS_FREE | 63 | #ifndef OVERRIDE_OPUS_FREE |
61 | static inline void opus_free (void *ptr) | 64 | static OPUS_INLINE void opus_free (void *ptr) |
62 | { | 65 | { |
63 | free(ptr); | 66 | free(ptr); |
64 | } | 67 | } |