You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

60 lines
1.7KB

  1. /*
  2. * This file is part of FFmpeg.
  3. *
  4. * FFmpeg is free software; you can redistribute it and/or
  5. * modify it under the terms of the GNU Lesser General Public
  6. * License as published by the Free Software Foundation; either
  7. * version 2.1 of the License, or (at your option) any later version.
  8. *
  9. * FFmpeg is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  12. * Lesser General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU Lesser General Public
  15. * License along with FFmpeg; if not, write to the Free Software
  16. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  17. */
  18. #ifndef AVCODEC_INTRAX8_H
  19. #define AVCODEC_INTRAX8_H
  20. #include "get_bits.h"
  21. #include "mpegvideo.h"
  22. #include "intrax8dsp.h"
  23. typedef struct IntraX8Context {
  24. VLC * j_ac_vlc[4];//they point to the static j_mb_vlc
  25. VLC * j_orient_vlc;
  26. VLC * j_dc_vlc[3];
  27. int use_quant_matrix;
  28. //set by ff_intrax8_common_init
  29. uint8_t * prediction_table;//2*(mb_w*2)
  30. ScanTable scantable[3];
  31. //set by the caller codec
  32. MpegEncContext * s;
  33. IntraX8DSPContext dsp;
  34. int quant;
  35. int dquant;
  36. int qsum;
  37. //calculated per frame
  38. int quant_dc_chroma;
  39. int divide_quant_dc_luma;
  40. int divide_quant_dc_chroma;
  41. //changed per block
  42. int edges;
  43. int flat_dc;
  44. int predicted_dc;
  45. int raw_orient;
  46. int chroma_orient;
  47. int orient;
  48. int est_run;
  49. } IntraX8Context;
  50. void ff_intrax8_common_init(IntraX8Context * w, MpegEncContext * const s);
  51. void ff_intrax8_common_end(IntraX8Context * w);
  52. int ff_intrax8_decode_picture(IntraX8Context * w, int quant, int halfpq);
  53. #endif /* AVCODEC_INTRAX8_H */