mid_sub.h 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. #ifndef __MID_LIBSUB_H__
  2. #define __MID_LIBSUB_H__
  3. #include <middleware/common/libsubparser/mid_sub_type.h>
  4. #include <middleware/common/gui_eng/font_common.h>
  5. #include <middleware/media/AL_Media_CodePage.h>
  6. #include "region.h"
  7. #define ENCODETYPE_AUTO MCP_AUTO
  8. #define ENCODETYPE_MAX MEDIA_CODEPAGE_MAX
  9. #define ENCODETYPE MediaCodePage_e
  10. /*======================
  11. subtitle new feature
  12. =======================*/
  13. typedef enum {
  14. Sub_POS_Y_TOP_H = 0,
  15. Sub_POS_Y_TOP_M = 1,
  16. Sub_POS_Y_TOP_L = 2,
  17. Sub_POS_Y_BOTTOM_H = 3,
  18. Sub_POS_Y_BOTTOM_M = 4,
  19. Sub_POS_Y_BOTTOM_L = 5,
  20. } Subtitle_PosY_t;
  21. typedef enum {
  22. Sub_FONT_COLOR_R = 0, // Red
  23. Sub_FONT_COLOR_G, // Green
  24. Sub_FONT_COLOR_Y, // Yellow
  25. Sub_FONT_COLOR_B, // Blue
  26. Sub_FONT_COLOR_P, // Purple
  27. Sub_FONT_COLOR_W, // White
  28. } Subtitle_FontColor_t;
  29. typedef enum {
  30. Sub_FONT_SIZE_LARGE_L = 0, // largest
  31. Sub_FONT_SIZE_LARGE_M = 1,
  32. Sub_FONT_SIZE_LARGE_S = 2,
  33. Sub_FONT_SIZE_SMALL_L = 3,
  34. Sub_FONT_SIZE_SMALL_M = 4,
  35. Sub_FONT_SIZE_SMALL_S = 5, // Smallest
  36. } Subtitle_FontSize_t;
  37. void Sub_ColorSet(Subtitle_FontColor_t ColorSet);
  38. void Sub_PositionSet(Subtitle_PosY_t PosYSet);
  39. void Sub_SizeSet(int SizeSet);
  40. int Sub_SetUserLangEncode(MediaCodePage_e encode);
  41. void *rav_intf_init(const char *pmedianame, void *arg);
  42. int rav_intf_set_data(int index, char *data, int size, UINT64 pts, UINT64 Audio_pts, UINT64 Video_pts,int duration, UINT64 convergence_duration);
  43. int rav_intf_subt_off(void);
  44. int rav_intf_subt_on(int id, char magNo, char pageNo);
  45. int rav_intf_change_state(int movie_state);
  46. int rav_intf_exit(void);
  47. int SetEncode(MediaCodePage_e encode);
  48. int GetEncode();
  49. #if 0 // newfontmask
  50. void Sub_SetFontInfo(FONTInfo_t *FontInfo, UINT32 FontBlockNum, UINT32 FontStyleNum, UINT8 LangNum);
  51. #endif
  52. void mid_sub_media_uninit();
  53. void MID_Subtitle_constructor();
  54. void MID_Subtitle_destructor(void);
  55. extern SubInfoListPtr pSubInfoList;
  56. #endif //__SUBPARSER_H__