diff options
author | Deb Mukherjee <debargha@google.com> | 2014-08-26 12:35:15 -0700 |
---|---|---|
committer | Deb Mukherjee <debargha@google.com> | 2014-09-02 14:37:10 -0700 |
commit | 5acfafb18e1720abfc0dc5baafce8e1a1b292b14 (patch) | |
tree | a89c5e2e79283e58a613b98dc3d7b3434ba6affe /vpx_mem | |
parent | 72037944df611abccac02c225e20adc9479200db (diff) | |
download | libvpx-5acfafb18e1720abfc0dc5baafce8e1a1b292b14.tar.gz |
Adds config opt for highbitdepth + misc. vpx
Adds config parameter vp9_highbitdepth, to support highbitdepth profiles.
Also includes most vpx level high bit-depth functions. However
encode/decode in the highbitdepth profiles will not work until
the rest of the code is in place.
Change-Id: I34c53b253c38873611057a6cbc89a1361b8985a6
Diffstat (limited to 'vpx_mem')
-rw-r--r-- | vpx_mem/vpx_mem.c | 24 | ||||
-rw-r--r-- | vpx_mem/vpx_mem.h | 3 |
2 files changed, 27 insertions, 0 deletions
diff --git a/vpx_mem/vpx_mem.c b/vpx_mem/vpx_mem.c index 059248bab..da616425c 100644 --- a/vpx_mem/vpx_mem.c +++ b/vpx_mem/vpx_mem.c @@ -16,6 +16,7 @@ #include <stdlib.h> #include <string.h> #include "include/vpx_mem_intrnl.h" +#include "vpx/vpx_integer.h" #if CONFIG_MEM_TRACKER #ifndef VPX_NO_GLOBALS @@ -452,6 +453,29 @@ void *vpx_memset(void *dest, int val, size_t length) { return VPX_MEMSET_L(dest, val, length); } +#if CONFIG_VP9 && CONFIG_VP9_HIGHBITDEPTH +void *vpx_memset16(void *dest, int val, size_t length) { +#if CONFIG_MEM_CHECKS + if ((int)dest < 0x4000) { + _P(printf("WARNING: vpx_memset dest:0x%x val:%d len:%d\n", + (int)dest, val, length);) + +#if defined(VXWORKS) + sp(get_my_tt, task_id_self(), 0, 0, 0, 0, 0, 0, 0, 0); + + vx_sleep(10000); +#endif + } +#endif + int i; + void *orig = dest; + uint16_t *dest16 = dest; + for (i = 0; i < length; i++) + *dest16++ = val; + return orig; +} +#endif // CONFIG_VP9 && CONFIG_VP9_HIGHBITDEPTH + void *vpx_memmove(void *dest, const void *src, size_t count) { #if CONFIG_MEM_CHECKS diff --git a/vpx_mem/vpx_mem.h b/vpx_mem/vpx_mem.h index 33686b276..e2391f496 100644 --- a/vpx_mem/vpx_mem.h +++ b/vpx_mem/vpx_mem.h @@ -73,6 +73,9 @@ extern "C" { void *vpx_memcpy(void *dest, const void *src, size_t length); void *vpx_memset(void *dest, int val, size_t length); +#if CONFIG_VP9 && CONFIG_VP9_HIGHBITDEPTH + void *vpx_memset16(void *dest, int val, size_t length); +#endif void *vpx_memmove(void *dest, const void *src, size_t count); /* special memory functions */ |