od_defs.h 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. /*Daala video codec
  2. Copyright (c) 2013 Daala project contributors. All rights reserved.
  3. Redistribution and use in source and binary forms, with or without
  4. modification, are permitted provided that the following conditions are met:
  5. - Redistributions of source code must retain the above copyright notice, this
  6. list of conditions and the following disclaimer.
  7. - Redistributions in binary form must reproduce the above copyright notice,
  8. this list of conditions and the following disclaimer in the documentation
  9. and/or other materials provided with the distribution.
  10. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS”
  11. AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  12. IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  13. DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
  14. FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  15. DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
  16. SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
  17. CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  18. OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  19. OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.*/
  20. #if !defined(_od_defs_H)
  21. # define _od_defs_H (0)
  22. #include "intra_fit_tools.h"
  23. #include "../src/filter.h"
  24. #if defined(_OPENMP)
  25. # include <omp.h>
  26. # define NUM_PROCS (4)
  27. # define OD_OMP_GET_THREAD (omp_get_thread_num())
  28. # define OD_OMP_SET_THREADS(_x) (omp_set_num_threads(_x))
  29. #else
  30. # pragma GCC warning "Compiler enviroment does not support OpenMP. The training tools will be very slow."
  31. # define NUM_PROCS (1)
  32. # define OD_OMP_GET_THREAD (0)
  33. # define OD_OMP_SET_THREADS(_x)
  34. #endif
  35. #define FAST_MATH (1)
  36. #define FILTER_BITS (4)
  37. #define USE_TYPE3 (1)
  38. #define NN_SEARCH (1)
  39. #define APPLY_FILTER (1)
  40. #define APPLY_DCT (1)
  41. #define APPLY_PRED (1)
  42. #define APPLY_PCA (1)
  43. #define INPUT_SCALE_BITS (4)
  44. #define INPUT_SCALE (1<<INPUT_SCALE_BITS)
  45. #define ZERO_MEAN (1)
  46. #define MASK_BLOCKS (0)
  47. #define TF_BLOCKS (1)
  48. #endif