hv_drv_OsdCommon.h 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. /**
  2. * @file hv_drv_OsdCommon.h
  3. * @brief Osd Drv layer common interface.
  4. * @verbatim
  5. * ==============================================================================
  6. * ##### How to use this driver #####
  7. * ==============================================================================
  8. * @endverbatim
  9. *
  10. * @author HiView SoC Software Team
  11. * @version 0.0.1
  12. * @date 2022-08-22
  13. */
  14. #ifndef _HV_DRV_OSDCOMMON_H
  15. #define _HV_DRV_OSDCOMMON_H
  16. #include "hv_drv_OsdWindow.h"
  17. #include "hv_drv_OsdTypes.h"
  18. /**
  19. * @brief convert pixel format enum to string
  20. * @param[in] enFormat pixel format
  21. * @return string required
  22. */
  23. const CHAR8* Hv_Drv_OsdCommon_GetPixelFormatStr(OsdPixelFormat enFormat);
  24. /**
  25. * @brief convert resource type enum to string
  26. * @param[in] enType resource type
  27. * @return string required
  28. */
  29. const CHAR8 *Hv_Drv_OsdCommon_GetResourceTypeStr(OsdResourceType enType);
  30. /**
  31. * @brief convert text align enum to string
  32. * @param[in] ucAlignType align type
  33. * @return string required
  34. */
  35. const CHAR8 *Hv_Drv_OsdCommon_GetTextAlignTypeStr(UCHAR8 ucAlignType);
  36. /**
  37. * @brief convert resource size enum to string
  38. * @param[in] enSize resource size
  39. * @return string required
  40. */
  41. const CHAR8 *Hv_Drv_OsdCommon_GetResourceSizeStr(OsdResourceSize enSize);
  42. /**
  43. * @brief convert blending stage enum to string
  44. * @param[in] enStage stage enum
  45. * @return string required
  46. */
  47. const CHAR8 *Hv_Drv_OsdCommon_GetBlendingStageStr(OsdBlendingStage enStage);
  48. /**
  49. * @brief convert SRAM change type to string
  50. * @param[in] enType change type
  51. * @return string required
  52. */
  53. const CHAR8 *Hv_Drv_OsdCommon_GetSRAMChangeTypeStr(OsdSRAMChangeType enType);
  54. /**
  55. * @brief get font size in bytes
  56. * @param[in] enSize width and height of font
  57. * @param[in] enType bit of font
  58. * @return font size in bytes
  59. */
  60. USHORT16 Hv_Drv_OsdCommon_GetResourceBytes(OsdResourceSize enSize, OsdResourceType enType);
  61. /**
  62. * @brief get bits of pixel format
  63. * @param[in] enFormat pixel format
  64. * @return bits of pixel format
  65. */
  66. UCHAR8 Hv_Drv_OsdCommon_GetPixelBits(OsdPixelFormat enFormat);
  67. #endif