Class: Google::Apis::TranscoderV1::Vp9CodecSettings
- Inherits:
-
Object
- Object
- Google::Apis::TranscoderV1::Vp9CodecSettings
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/transcoder_v1/classes.rb,
lib/google/apis/transcoder_v1/representations.rb,
lib/google/apis/transcoder_v1/representations.rb
Overview
VP9 codec settings.
Instance Attribute Summary collapse
-
#bitrate_bps ⇒ Fixnum
Required.
-
#crf_level ⇒ Fixnum
Target CRF level.
-
#frame_rate ⇒ Float
Required.
-
#frame_rate_conversion_strategy ⇒ String
Optional.
-
#gop_duration ⇒ String
Select the GOP size based on the specified duration.
-
#gop_frame_count ⇒ Fixnum
Select the GOP size based on the specified frame count.
-
#height_pixels ⇒ Fixnum
The height of the video in pixels.
-
#hlg ⇒ Google::Apis::TranscoderV1::Vp9ColorFormatHlg
Convert the input video to a Hybrid Log Gamma (HLG) video.
-
#pixel_format ⇒ String
Pixel format to use.
-
#profile ⇒ String
Enforces the specified codec profile.
-
#rate_control_mode ⇒ String
Specify the mode.
-
#sdr ⇒ Google::Apis::TranscoderV1::Vp9ColorFormatSdr
Convert the input video to a Standard Dynamic Range (SDR) video.
-
#width_pixels ⇒ Fixnum
The width of the video in pixels.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Vp9CodecSettings
constructor
A new instance of Vp9CodecSettings.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Vp9CodecSettings
Returns a new instance of Vp9CodecSettings.
2354 2355 2356 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2354 def initialize(**args) update!(**args) end |
Instance Attribute Details
#bitrate_bps ⇒ Fixnum
Required. The video bitrate in bits per second. The minimum value is 1,000.
The maximum value is 480,000,000.
Corresponds to the JSON property bitrateBps
2263 2264 2265 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2263 def bitrate_bps @bitrate_bps end |
#crf_level ⇒ Fixnum
Target CRF level. Must be between 10 and 36, where 10 is the highest quality
and 36 is the most efficient compression. The default is 21. Note: This
field is not supported.
Corresponds to the JSON property crfLevel
2270 2271 2272 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2270 def crf_level @crf_level end |
#frame_rate ⇒ Float
Required. The target video frame rate in frames per second (FPS). Must be less
than or equal to 120.
Corresponds to the JSON property frameRate
2276 2277 2278 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2276 def frame_rate @frame_rate end |
#frame_rate_conversion_strategy ⇒ String
Optional. Frame rate conversion strategy for desired frame rate. The default
is DOWNSAMPLE
.
Corresponds to the JSON property frameRateConversionStrategy
2282 2283 2284 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2282 def frame_rate_conversion_strategy @frame_rate_conversion_strategy end |
#gop_duration ⇒ String
Select the GOP size based on the specified duration. The default is 3s
. Note
that gopDuration
must be less than or equal to segmentDuration
, and segmentDuration
must be divisible
by gopDuration
.
Corresponds to the JSON property gopDuration
2290 2291 2292 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2290 def gop_duration @gop_duration end |
#gop_frame_count ⇒ Fixnum
Select the GOP size based on the specified frame count. Must be greater than
zero.
Corresponds to the JSON property gopFrameCount
2296 2297 2298 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2296 def gop_frame_count @gop_frame_count end |
#height_pixels ⇒ Fixnum
The height of the video in pixels. Must be an even integer. When not specified,
the height is adjusted to match the specified width and input aspect ratio.
If both are omitted, the input height is used. For portrait videos that
contain horizontal ASR and rotation metadata, provide the height, in pixels,
per the horizontal ASR. The API calculates the width per the horizontal ASR.
The API detects any rotation metadata and swaps the requested height and width
for the output.
Corresponds to the JSON property heightPixels
2307 2308 2309 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2307 def height_pixels @height_pixels end |
#hlg ⇒ Google::Apis::TranscoderV1::Vp9ColorFormatHlg
Convert the input video to a Hybrid Log Gamma (HLG) video.
Corresponds to the JSON property hlg
2312 2313 2314 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2312 def hlg @hlg end |
#pixel_format ⇒ String
Pixel format to use. The default is yuv420p
. Supported pixel formats: -
yuv420p
pixel format - yuv422p
pixel format - yuv444p
pixel format -
yuv420p10
10-bit HDR pixel format - yuv422p10
10-bit HDR pixel format -
yuv444p10
10-bit HDR pixel format - yuv420p12
12-bit HDR pixel format -
yuv422p12
12-bit HDR pixel format - yuv444p12
12-bit HDR pixel format
Corresponds to the JSON property pixelFormat
2321 2322 2323 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2321 def pixel_format @pixel_format end |
#profile ⇒ String
Enforces the specified codec profile. The following profiles are supported: *
profile0
(default) * profile1
* profile2
* profile3
The available
options are WebM-compatible. Note
that certain values for this field may cause the transcoder to override other
fields you set in the Vp9CodecSettings
message.
Corresponds to the JSON property profile
2330 2331 2332 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2330 def profile @profile end |
#rate_control_mode ⇒ String
Specify the mode. The default is vbr
. Supported rate control modes: - vbr
-
variable bitrate
Corresponds to the JSON property rateControlMode
2336 2337 2338 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2336 def rate_control_mode @rate_control_mode end |
#sdr ⇒ Google::Apis::TranscoderV1::Vp9ColorFormatSdr
Convert the input video to a Standard Dynamic Range (SDR) video.
Corresponds to the JSON property sdr
2341 2342 2343 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2341 def sdr @sdr end |
#width_pixels ⇒ Fixnum
The width of the video in pixels. Must be an even integer. When not specified,
the width is adjusted to match the specified height and input aspect ratio. If
both are omitted, the input width is used. For portrait videos that contain
horizontal ASR and rotation metadata, provide the width, in pixels, per the
horizontal ASR. The API calculates the height per the horizontal ASR. The API
detects any rotation metadata and swaps the requested height and width for the
output.
Corresponds to the JSON property widthPixels
2352 2353 2354 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2352 def width_pixels @width_pixels end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 |
# File 'lib/google/apis/transcoder_v1/classes.rb', line 2359 def update!(**args) @bitrate_bps = args[:bitrate_bps] if args.key?(:bitrate_bps) @crf_level = args[:crf_level] if args.key?(:crf_level) @frame_rate = args[:frame_rate] if args.key?(:frame_rate) @frame_rate_conversion_strategy = args[:frame_rate_conversion_strategy] if args.key?(:frame_rate_conversion_strategy) @gop_duration = args[:gop_duration] if args.key?(:gop_duration) @gop_frame_count = args[:gop_frame_count] if args.key?(:gop_frame_count) @height_pixels = args[:height_pixels] if args.key?(:height_pixels) @hlg = args[:hlg] if args.key?(:hlg) @pixel_format = args[:pixel_format] if args.key?(:pixel_format) @profile = args[:profile] if args.key?(:profile) @rate_control_mode = args[:rate_control_mode] if args.key?(:rate_control_mode) @sdr = args[:sdr] if args.key?(:sdr) @width_pixels = args[:width_pixels] if args.key?(:width_pixels) end |