StreamOptions.cs 5.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219
  1. namespace MediaBrowser.Model.Dto
  2. {
  3. /// <summary>
  4. /// Class VideoStreamOptions
  5. /// </summary>
  6. public class VideoStreamOptions : StreamOptions
  7. {
  8. /// <summary>
  9. /// Gets or sets the video codec.
  10. /// Omit to copy
  11. /// </summary>
  12. /// <value>The video codec.</value>
  13. public VideoCodecs? VideoCodec { get; set; }
  14. /// <summary>
  15. /// Gets or sets the video bit rate.
  16. /// </summary>
  17. /// <value>The video bit rate.</value>
  18. public int? VideoBitRate { get; set; }
  19. /// <summary>
  20. /// Gets or sets the width.
  21. /// </summary>
  22. /// <value>The width.</value>
  23. public int? Width { get; set; }
  24. /// <summary>
  25. /// Gets or sets the height.
  26. /// </summary>
  27. /// <value>The height.</value>
  28. public int? Height { get; set; }
  29. /// <summary>
  30. /// Gets or sets the width of the max.
  31. /// </summary>
  32. /// <value>The width of the max.</value>
  33. public int? MaxWidth { get; set; }
  34. /// <summary>
  35. /// Gets or sets the height of the max.
  36. /// </summary>
  37. /// <value>The height of the max.</value>
  38. public int? MaxHeight { get; set; }
  39. /// <summary>
  40. /// Gets or sets the frame rate.
  41. /// </summary>
  42. /// <value>The frame rate.</value>
  43. public double? FrameRate { get; set; }
  44. /// <summary>
  45. /// Gets or sets the index of the audio stream.
  46. /// </summary>
  47. /// <value>The index of the audio stream.</value>
  48. public int? AudioStreamIndex { get; set; }
  49. /// <summary>
  50. /// Gets or sets the index of the video stream.
  51. /// </summary>
  52. /// <value>The index of the video stream.</value>
  53. public int? VideoStreamIndex { get; set; }
  54. /// <summary>
  55. /// Gets or sets the index of the subtitle stream.
  56. /// </summary>
  57. /// <value>The index of the subtitle stream.</value>
  58. public int? SubtitleStreamIndex { get; set; }
  59. /// <summary>
  60. /// Gets or sets the profile.
  61. /// </summary>
  62. /// <value>The profile.</value>
  63. public string Profile { get; set; }
  64. /// <summary>
  65. /// Gets or sets the level.
  66. /// </summary>
  67. /// <value>The level.</value>
  68. public string Level { get; set; }
  69. /// <summary>
  70. /// Gets or sets the baseline stream audio bit rate.
  71. /// </summary>
  72. /// <value>The baseline stream audio bit rate.</value>
  73. public int? BaselineStreamAudioBitRate { get; set; }
  74. /// <summary>
  75. /// Gets or sets a value indicating whether [append baseline stream].
  76. /// </summary>
  77. /// <value><c>true</c> if [append baseline stream]; otherwise, <c>false</c>.</value>
  78. public bool AppendBaselineStream { get; set; }
  79. /// <summary>
  80. /// Gets or sets the time stamp offset ms. Only used with HLS.
  81. /// </summary>
  82. /// <value>The time stamp offset ms.</value>
  83. public int? TimeStampOffsetMs { get; set; }
  84. }
  85. /// <summary>
  86. /// Class StreamOptions
  87. /// </summary>
  88. public class StreamOptions
  89. {
  90. /// <summary>
  91. /// Gets or sets the audio bit rate.
  92. /// </summary>
  93. /// <value>The audio bit rate.</value>
  94. public int? AudioBitRate { get; set; }
  95. /// <summary>
  96. /// Gets or sets the audio codec.
  97. /// Omit to copy the original stream
  98. /// </summary>
  99. /// <value>The audio encoding format.</value>
  100. public AudioCodecs? AudioCodec { get; set; }
  101. /// <summary>
  102. /// Gets or sets the item id.
  103. /// </summary>
  104. /// <value>The item id.</value>
  105. public string ItemId { get; set; }
  106. /// <summary>
  107. /// Gets or sets the max audio channels.
  108. /// </summary>
  109. /// <value>The max audio channels.</value>
  110. public int? MaxAudioChannels { get; set; }
  111. /// <summary>
  112. /// Gets or sets the max audio sample rate.
  113. /// </summary>
  114. /// <value>The max audio sample rate.</value>
  115. public int? MaxAudioSampleRate { get; set; }
  116. /// <summary>
  117. /// Gets or sets the start time ticks.
  118. /// </summary>
  119. /// <value>The start time ticks.</value>
  120. public long? StartTimeTicks { get; set; }
  121. /// <summary>
  122. /// Gets or sets a value indicating whether the original media should be served statically
  123. /// Only used with progressive streaming
  124. /// </summary>
  125. /// <value><c>true</c> if static; otherwise, <c>false</c>.</value>
  126. public bool? Static { get; set; }
  127. /// <summary>
  128. /// Gets or sets the output file extension.
  129. /// </summary>
  130. /// <value>The output file extension.</value>
  131. public string OutputFileExtension { get; set; }
  132. }
  133. /// <summary>
  134. /// These are the codecs the api is capable of encoding to
  135. /// </summary>
  136. public enum AudioCodecs
  137. {
  138. /// <summary>
  139. /// The aac
  140. /// </summary>
  141. Aac,
  142. /// <summary>
  143. /// The MP3
  144. /// </summary>
  145. Mp3,
  146. /// <summary>
  147. /// The vorbis
  148. /// </summary>
  149. Vorbis,
  150. /// <summary>
  151. /// The wma
  152. /// </summary>
  153. Wma,
  154. /// <summary>
  155. /// The copy
  156. /// </summary>
  157. Copy
  158. }
  159. /// <summary>
  160. /// Enum VideoCodecs
  161. /// </summary>
  162. public enum VideoCodecs
  163. {
  164. H263,
  165. /// <summary>
  166. /// The H264
  167. /// </summary>
  168. H264,
  169. /// <summary>
  170. /// The mpeg4
  171. /// </summary>
  172. Mpeg4,
  173. /// <summary>
  174. /// The theora
  175. /// </summary>
  176. Theora,
  177. /// <summary>
  178. /// The VPX
  179. /// </summary>
  180. Vpx,
  181. /// <summary>
  182. /// The WMV
  183. /// </summary>
  184. Wmv,
  185. /// <summary>
  186. /// The copy
  187. /// </summary>
  188. Copy
  189. }
  190. }