H264Sei.h 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  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. -- Description : H.264 SEI Messages.
  17. --
  18. ------------------------------------------------------------------------------*/
  19. #ifndef H264_SEI_H
  20. #define H264_SEI_H
  21. #include "basetype.h"
  22. #include "H264PutBits.h"
  23. typedef struct
  24. {
  25. u32 fts; /* Full time stamp */
  26. u32 timeScale;
  27. u32 nuit; /* number of units in tick */
  28. u32 time; /* Modulo time */
  29. u32 secf;
  30. u32 sec; /* Seconds */
  31. u32 minf;
  32. u32 min; /* Minutes */
  33. u32 hrf;
  34. u32 hr; /* Hours */
  35. } timeStamp_s;
  36. typedef struct
  37. {
  38. timeStamp_s ts;
  39. u32 nalUnitSize;
  40. u32 enabled;
  41. true_e byteStream;
  42. u32 hrd; /* HRD conformance */
  43. u32 seqId;
  44. u32 icrd; /* initial cpb removal delay */
  45. u32 icrdLen;
  46. u32 icrdo; /* initial cpb removal delay offset */
  47. u32 icrdoLen;
  48. u32 crd; /* CPB removal delay */
  49. u32 crdLen;
  50. u32 dod; /* DPB removal delay */
  51. u32 dodLen;
  52. u32 psp;
  53. u32 ps;
  54. u32 cts;
  55. u32 cntType;
  56. u32 cdf;
  57. u32 nframes;
  58. u32 toffs;
  59. u32 toffsLen;
  60. u32 userDataEnabled;
  61. const u8 * pUserData;
  62. u32 userDataSize;
  63. } sei_s;
  64. void H264InitSei(sei_s * sei, true_e byteStream, u32 hrd, u32 timeScale,
  65. u32 nuit);
  66. void H264UpdateSeiTS(sei_s * sei, u32 timeInc);
  67. void H264FillerSei(stream_s * sp, sei_s * sei, i32 cnt);
  68. void H264BufferingSei(stream_s * stream, sei_s * sei);
  69. void H264PicTimingSei(stream_s * stream, sei_s * sei);
  70. void H264UserDataUnregSei(stream_s * sp, sei_s * sei);
  71. #endif