QNTranscodingLiveStreamingConfig.h 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. //
  2. // QNTranscodingLiveStreamingConfig.h
  3. // QNRTCKit
  4. //
  5. // Created by tony.jing on 2021/8/17.
  6. // Copyright © 2021 Pili Engineering, Qiniu Inc. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. #import "QNTypeDefines.h"
  10. #import "QNTranscodingLiveStreamingImage.h"
  11. #import "QNTranscodingLiveStreamingTrack.h"
  12. @interface QNTranscodingLiveStreamingConfig : NSObject
  13. <
  14. NSCopying
  15. >
  16. /*!
  17. * @abstract 合流的 id
  18. *
  19. * @since v4.0.0
  20. */
  21. @property (nonatomic, strong) NSString *streamID;
  22. /*!
  23. * @abstract 合流的转推地址
  24. *
  25. * @since v4.0.0
  26. */
  27. @property (nonatomic, strong) NSString *publishUrl;
  28. /*!
  29. * @abstract 图像的宽度,默认值为 480
  30. *
  31. * @since v4.0.0
  32. */
  33. @property (nonatomic, assign) int width;
  34. /*!
  35. * @abstract 图像的高度,默认值为 848
  36. *
  37. * @since v4.0.0
  38. */
  39. @property (nonatomic, assign) int height;
  40. /*!
  41. * @abstract 帧率,默认值为 25
  42. *
  43. * @since v4.0.0
  44. */
  45. @property (nonatomic, assign) int fps;
  46. /*!
  47. * @abstract 码率,单位为 bps,默认值为 1000*1000
  48. *
  49. * @since v4.0.0
  50. */
  51. @property (nonatomic, assign) NSUInteger bitrateBps;
  52. /*!
  53. * @abstract 图像的填充模式,默认值为 QNVideoFillModePreserveAspectRatioAndFill
  54. *
  55. * @since v4.0.0
  56. */
  57. @property (nonatomic, assign) QNVideoFillModeType fillMode;
  58. /*!
  59. * @abstract 水印,为可选项
  60. *
  61. * @since v4.0.0
  62. */
  63. @property (nonatomic, strong) NSArray<QNTranscodingLiveStreamingImage *> *watermarks;
  64. /*!
  65. * @abstract 背景图片,为可选项
  66. *
  67. * @since v4.0.0
  68. */
  69. @property (nonatomic, strong) QNTranscodingLiveStreamingImage *background;
  70. /*!
  71. * @abstract 最小码率,为可选项
  72. *
  73. * @since v4.0.0
  74. */
  75. @property (nonatomic, assign) NSUInteger minBitrateBps;
  76. /*!
  77. * @abstract 最大码率,为可选项
  78. *
  79. * @since v4.0.0
  80. */
  81. @property (nonatomic, assign) NSUInteger maxBitrateBps;
  82. /*!
  83. * @abstract 是否开启纯音频合流任务,默认为 NO
  84. *
  85. * @since 5.1.1
  86. */
  87. @property (nonatomic, assign) BOOL isAudioOnly;
  88. /*!
  89. * @abstract 创建默认配置的实例
  90. *
  91. * @since v4.0.0
  92. */
  93. + (instancetype)defaultConfiguration;
  94. @end