h264hwd_container.h 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. /*------------------------------------------------------------------------------
  2. -- --
  3. -- This software is confidential and proprietary and may be used --
  4. -- only as expressly authorized by a licensing agreement from --
  5. -- --
  6. -- Hantro Products Oy. --
  7. -- --
  8. -- (C) COPYRIGHT 2006 HANTRO PRODUCTS OY --
  9. -- ALL RIGHTS RESERVED --
  10. -- --
  11. -- The entire notice above must be reproduced --
  12. -- on all copies and should not be removed. --
  13. -- --
  14. --------------------------------------------------------------------------------
  15. --
  16. -- Abstract : Definition of decContainer_t data structure
  17. --
  18. --------------------------------------------------------------------------------
  19. --
  20. -- Version control information, please leave untouched.
  21. --
  22. -- $RCSfile: h264hwd_container.h,v $
  23. -- $Date: 2009/04/27 08:56:17 $
  24. -- $Revision: 1.10 $
  25. --
  26. ------------------------------------------------------------------------------*/
  27. #ifndef H264HWD_CONTAINER_H
  28. #define H264HWD_CONTAINER_H
  29. /*------------------------------------------------------------------------------
  30. 1. Include headers
  31. ------------------------------------------------------------------------------*/
  32. #include "basetype.h"
  33. #include "h264hwd_storage.h"
  34. #include "h264hwd_util.h"
  35. #include "refbuffer.h"
  36. #include "deccfg.h"
  37. #include "decppif.h"
  38. /*------------------------------------------------------------------------------
  39. 2. Module defines
  40. ------------------------------------------------------------------------------*/
  41. /*------------------------------------------------------------------------------
  42. 3. Data types
  43. ------------------------------------------------------------------------------*/
  44. #define H264DEC_UNINITIALIZED 0U
  45. #define H264DEC_INITIALIZED 1U
  46. #define H264DEC_BUFFER_EMPTY 2U
  47. #define H264DEC_NEW_HEADERS 3U
  48. /* asic interface */
  49. typedef struct DecAsicBuffers
  50. {
  51. u32 buff_status;
  52. DWLLinearMem_t mbCtrl;
  53. DWLLinearMem_t mv;
  54. DWLLinearMem_t intraPred;
  55. DWLLinearMem_t residual;
  56. DWLLinearMem_t *outBuffer;
  57. DWLLinearMem_t cabacInit;
  58. u32 refPicList[16];
  59. u32 maxRefFrm;
  60. u32 filterDisable;
  61. i32 chromaQpIndexOffset;
  62. i32 chromaQpIndexOffset2;
  63. u32 currentMB;
  64. u32 notCodedMask;
  65. u32 rlcWords;
  66. u32 picSizeInMbs;
  67. u32 wholePicConcealed;
  68. u32 disableOutWriting;
  69. u32 enableDmvAndPoc;
  70. } DecAsicBuffers_t;
  71. typedef struct decContainer
  72. {
  73. const void *checksum;
  74. u32 decStat;
  75. u32 picNumber;
  76. u32 asicRunning;
  77. u32 rlcMode;
  78. u32 tryVlc;
  79. u32 reallocate;
  80. const u8 *pHwStreamStart;
  81. u32 hwStreamStartBus;
  82. u32 hwBitPos;
  83. u32 hwLength;
  84. u32 streamPosUpdated;
  85. u32 nalStartCode;
  86. u32 modeChange;
  87. u32 gapsCheckedForThis;
  88. u32 packetDecoded;
  89. u32 forceRlcMode; /* by default stays 0, testing can set it to 1 for RLC mode */
  90. u32 h264Regs[DEC_X170_REGISTERS];
  91. storage_t storage; /* h264bsd storage */
  92. DecAsicBuffers_t asicBuff[1];
  93. const void *dwl; /* DWL instance */
  94. u32 refBufSupport;
  95. u32 h264ProfileSupport;
  96. u32 is8190;
  97. u32 maxDecPicWidth;
  98. refBuffer_t refBufferCtrl;
  99. u32 keepHwReserved;
  100. struct pp_
  101. {
  102. const void *ppInstance;
  103. void (*PPDecStart) (const void *, const DecPpInterface *);
  104. void (*PPDecWaitEnd) (const void *);
  105. void (*PPConfigQuery) (const void *, DecPpQuery *);
  106. void (*PPNextDisplayId)(const void *, u32); /* set the next PP outpic ID (multibuffer) */
  107. DecPpInterface decPpIf;
  108. DecPpQuery ppInfo;
  109. const DWLLinearMem_t * sentPicToPp[17]; /* list of pictures sent to pp */
  110. const DWLLinearMem_t * queuedPicToPp; /* queued picture that should be processed next */
  111. u32 multiMaxId; /* maximum position used in sentPicToPp[] */
  112. } pp;
  113. } decContainer_t;
  114. /*------------------------------------------------------------------------------
  115. 4. Function prototypes
  116. ------------------------------------------------------------------------------*/
  117. #endif /* #ifdef H264HWD_CONTAINER_H */