vp9_rtcd_arm.h 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. #ifndef VP9_RTCD_H_
  2. #define VP9_RTCD_H_
  3. #ifdef RTCD_C
  4. #define RTCD_EXTERN
  5. #else
  6. #define RTCD_EXTERN extern
  7. #endif
  8. /*
  9. * VP9
  10. */
  11. #include "vp9/common/vp9_common.h"
  12. #ifdef __cplusplus
  13. extern "C" {
  14. #endif
  15. void vp9_iht16x16_256_add_c(const tran_low_t *input, uint8_t *output, int pitch, int tx_type);
  16. #define vp9_iht16x16_256_add vp9_iht16x16_256_add_c
  17. void vp9_iht4x4_16_add_c(const tran_low_t *input, uint8_t *dest, int dest_stride, int tx_type);
  18. void vp9_iht4x4_16_add_neon(const tran_low_t *input, uint8_t *dest, int dest_stride, int tx_type);
  19. RTCD_EXTERN void (*vp9_iht4x4_16_add)(const tran_low_t *input, uint8_t *dest, int dest_stride, int tx_type);
  20. void vp9_iht8x8_64_add_c(const tran_low_t *input, uint8_t *dest, int dest_stride, int tx_type);
  21. void vp9_iht8x8_64_add_neon(const tran_low_t *input, uint8_t *dest, int dest_stride, int tx_type);
  22. RTCD_EXTERN void (*vp9_iht8x8_64_add)(const tran_low_t *input, uint8_t *dest, int dest_stride, int tx_type);
  23. void vp9_rtcd(void);
  24. #ifdef RTCD_C
  25. #include "vpx_ports/arm.h"
  26. static void setup_rtcd_internal(void)
  27. {
  28. int flags = arm_cpu_caps();
  29. vp9_iht4x4_16_add = vp9_iht4x4_16_add_c;
  30. #if HAVE_NEON
  31. if (flags & HAS_NEON) vp9_iht4x4_16_add = vp9_iht4x4_16_add_neon;
  32. #endif
  33. vp9_iht8x8_64_add = vp9_iht8x8_64_add_c;
  34. #if HAVE_NEON
  35. if (flags & HAS_NEON) vp9_iht8x8_64_add = vp9_iht8x8_64_add_neon;
  36. #endif
  37. }
  38. #endif
  39. #ifdef __cplusplus
  40. } // extern "C"
  41. #endif
  42. #endif