OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2010 The WebM project authors. All Rights Reserved. | 2 * Copyright (c) 2010 The WebM project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
84 return new_addr; | 84 return new_addr; |
85 } | 85 } |
86 | 86 |
87 void vpx_free(void *memblk) { | 87 void vpx_free(void *memblk) { |
88 if (memblk) { | 88 if (memblk) { |
89 void *addr = (void *)(((size_t *)memblk)[-1]); | 89 void *addr = (void *)(((size_t *)memblk)[-1]); |
90 free(addr); | 90 free(addr); |
91 } | 91 } |
92 } | 92 } |
93 | 93 |
94 #if CONFIG_VP9 && CONFIG_VP9_HIGHBITDEPTH | 94 #if CONFIG_VP9_HIGHBITDEPTH |
95 void *vpx_memset16(void *dest, int val, size_t length) { | 95 void *vpx_memset16(void *dest, int val, size_t length) { |
96 int i; | 96 int i; |
97 void *orig = dest; | 97 void *orig = dest; |
98 uint16_t *dest16 = dest; | 98 uint16_t *dest16 = dest; |
99 for (i = 0; i < length; i++) | 99 for (i = 0; i < length; i++) |
100 *dest16++ = val; | 100 *dest16++ = val; |
101 return orig; | 101 return orig; |
102 } | 102 } |
103 #endif // CONFIG_VP9 && CONFIG_VP9_HIGHBITDEPTH | 103 #endif // CONFIG_VP9_HIGHBITDEPTH |
OLD | NEW |