Class: Azure::MediaServices::Mgmt::V2020_05_01::Models::Image
- Includes:
- MsRestAzure
- Defined in:
- lib/2020-05-01/generated/azure_mgmt_media_services/models/image.rb
Overview
Describes the basic properties for generating thumbnails from the input video
Instance Attribute Summary collapse
-
#odatatype ⇒ Object
Returns the value of attribute odatatype.
-
#range ⇒ String
in the input video at which to stop generating thumbnails.
-
#start ⇒ String
generating thumbnails.
-
#step ⇒ String
value can be in ISO 8601 format (For example, PT05S for one image every 5 seconds), or a frame count (For example, 30 for one image every 30 frames), or a relative value to stream duration (For example, 10% for one image every 10% of stream duration).
Attributes inherited from Video
#key_frame_interval, #stretch_mode, #sync_mode
Attributes inherited from Codec
Class Method Summary collapse
-
.mapper ⇒ Object
Mapper for Image class as Ruby Hash.
Instance Method Summary collapse
-
#initialize ⇒ Image
constructor
A new instance of Image.
Constructor Details
#initialize ⇒ Image
17 18 19 |
# File 'lib/2020-05-01/generated/azure_mgmt_media_services/models/image.rb', line 17 def initialize @odatatype = "#Microsoft.Media.Image" end |
Instance Attribute Details
#odatatype ⇒ Object
Returns the value of attribute odatatype.
21 22 23 |
# File 'lib/2020-05-01/generated/azure_mgmt_media_services/models/image.rb', line 21 def odatatype @odatatype end |
#range ⇒ String
in the input video at which to stop generating thumbnails. The value can be in ISO 8601 format (For example, PT5M30S to stop at 5 minutes and 30 seconds from start time), or a frame count (For example, 300 to stop at the 300th frame from the frame at start time. If this value is 1, it means only producing one thumbnail at start time), or a relative value to the stream duration (For example, 50% to stop at half of stream duration from start time). The default value is 100%, which means to stop at the end of the stream.
59 60 61 |
# File 'lib/2020-05-01/generated/azure_mgmt_media_services/models/image.rb', line 59 def range @range end |
#start ⇒ String
generating thumbnails. The value can be in ISO 8601 format (For example, PT05S to start at 5 seconds), or a frame count (For example, 10 to start at the 10th frame), or a relative value to stream duration (For example, 10% to start at 10% of stream duration). Also supports a macro Best, which tells the encoder to select the best thumbnail from the first few seconds of the video and will only produce one thumbnail, no matter what other settings are for Step and Range. The default value is macro Best.
32 33 34 |
# File 'lib/2020-05-01/generated/azure_mgmt_media_services/models/image.rb', line 32 def start @start end |
#step ⇒ String
value can be in ISO 8601 format (For example, PT05S for one image every 5 seconds), or a frame count (For example, 30 for one image every 30 frames), or a relative value to stream duration (For example, 10% for one image every 10% of stream duration). Note: Step value will affect the first generated thumbnail, which may not be exactly the one specified at transform preset start time. This is due to the encoder, which tries to select the best thumbnail between start time and Step position from start time as the first output. As the default value is 10%, it means if stream has long duration, the first generated thumbnail might be far away from the one specified at start time. Try to select reasonable value for Step if the first thumbnail is expected close to start time, or set Range value at 1 if only one thumbnail is needed at start time.
48 49 50 |
# File 'lib/2020-05-01/generated/azure_mgmt_media_services/models/image.rb', line 48 def step @step end |
Class Method Details
.mapper ⇒ Object
Mapper for Image class as Ruby Hash. This will be used for serialization/deserialization.
66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 |
# File 'lib/2020-05-01/generated/azure_mgmt_media_services/models/image.rb', line 66 def self.mapper() { client_side_validation: true, required: false, serialized_name: '#Microsoft.Media.Image', type: { name: 'Composite', class_name: 'Image', model_properties: { label: { client_side_validation: true, required: false, serialized_name: 'label', type: { name: 'String' } }, odatatype: { client_side_validation: true, required: true, serialized_name: '@odata\\.type', type: { name: 'String' } }, key_frame_interval: { client_side_validation: true, required: false, serialized_name: 'keyFrameInterval', type: { name: 'TimeSpan' } }, stretch_mode: { client_side_validation: true, required: false, serialized_name: 'stretchMode', type: { name: 'String' } }, sync_mode: { client_side_validation: true, required: false, serialized_name: 'syncMode', type: { name: 'String' } }, start: { client_side_validation: true, required: true, serialized_name: 'start', type: { name: 'String' } }, step: { client_side_validation: true, required: false, serialized_name: 'step', type: { name: 'String' } }, range: { client_side_validation: true, required: false, serialized_name: 'range', type: { name: 'String' } } } } } end |