PlayerView.h 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. //
  2. // PlayerView.h
  3. // VclustersGemini
  4. //
  5. // Created by APPLE on 2019/6/13.
  6. // Copyright © 2019 APPLE. All rights reserved.
  7. //
  8. #import <UIKit/UIKit.h>
  9. #import <GLKit/GLKit.h>
  10. #import "ShowImageView.h"
  11. #import "Masonry.h"
  12. NS_ASSUME_NONNULL_BEGIN
  13. @protocol PlayerViewDelegate <NSObject>
  14. @optional
  15. - (void)useInfoBtnBePressed:(id)sender;
  16. - (void)playerShowImageViewtouchesStr:(NSString *)commondStr;
  17. - (void)mueBtnBePressed:(id)sender;
  18. - (void)homeBtnBePressed:(id)sender;
  19. - (void)backBtnBePressed:(id)sender;
  20. @end
  21. @interface PlayerView : UIView
  22. @property(nonatomic,strong)ShowImageView *showImageView;
  23. /**
  24. * @brief openGL渲染视图
  25. *
  26. */
  27. @property(nonatomic,strong)GLKView *glkshowImageView;
  28. /**
  29. * @brief 悬浮控制按钮
  30. *
  31. *专业模式下隐藏,普通模式下显示。
  32. *注意横竖屏切换时需要注意坐标的转换。
  33. *自动置于屏幕边缘时要考虑灵动岛以及底部滑块的干扰问题,建议置于4个角。
  34. *
  35. */
  36. @property(nonatomic,strong)UIButton *controlBtn;
  37. @property (nonatomic, weak) id<PlayerViewDelegate> delegate;
  38. /**
  39. * @brief 标记是否为横屏
  40. *
  41. */
  42. @property(nonatomic,assign)BOOL isLan;
  43. /**
  44. * @brief 云手机类型 VIP星动云手机 SVIP星曜云手机 STAR 唔即云手机
  45. */
  46. @property(copy,nonatomic)NSString *buyVipType;
  47. /**
  48. * @brief 渲染图片
  49. *
  50. * @param ciImage 待渲染的图片数据源
  51. *
  52. */
  53. - (void)glkShowImage:(CIImage *)ciImage;
  54. /**
  55. * @brief 布局渲染视图横屏模式视图
  56. *
  57. * @param w_h_rate 原始图片宽高比
  58. *
  59. * @param isOpenVirtual 是否有打开虚拟按键视图
  60. *
  61. * @param isUsageMode 是否为专业模式
  62. *
  63. */
  64. - (void)setLanMas_makeWithImageRate:(CGFloat)w_h_rate isOpenVirtual:(BOOL)isOpenVirtual isUsageMode:(BOOL)isUsageMode;
  65. /**
  66. * @brief 布局渲染视图竖屏模式视图
  67. *
  68. * @param w_h_rate 原始图片宽高比
  69. *
  70. * @param isOpenVirtual 是否有打开虚拟按键视图
  71. *
  72. * @param isUsageMode 是否为专业模式
  73. *
  74. */
  75. - (void)setPoMas_makeWithImageRate:(CGFloat)w_h_rate isOpenVirtual:(BOOL)isOpenVirtual isUsageMode:(BOOL)isUsageMode;
  76. /**
  77. * @brief 默认布局渲染视图竖屏模式视图宽高比默认为9/16
  78. *
  79. * @param isOpenVirtual 是否有打开虚拟按键视图
  80. *
  81. * @param isUsageMode 是否为专业模式
  82. *
  83. */
  84. - (void)initPoMas_makeWithImageRate:(BOOL)isOpenVirtual isUsageMode:(BOOL)isUsageMode;
  85. @end
  86. NS_ASSUME_NONNULL_END