com.pulumi.azurenative.media.outputs.ImageResponse Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of azure-native Show documentation
Show all versions of azure-native Show documentation
A native Pulumi package for creating and managing Azure resources.
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package com.pulumi.azurenative.media.outputs;
import com.pulumi.core.annotations.CustomType;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
@CustomType
public final class ImageResponse {
/**
* @return The distance between two key frames. The value should be non-zero in the range [0.5, 20] seconds, specified in ISO 8601 format. The default is 2 seconds(PT2S). Note that this setting is ignored if VideoSyncMode.Passthrough is set, where the KeyFrameInterval value will follow the input source setting.
*
*/
private @Nullable String keyFrameInterval;
/**
* @return An optional label for the codec. The label can be used to control muxing behavior.
*
*/
private @Nullable String label;
/**
* @return The discriminator for derived types.
* Expected value is '#Microsoft.Media.Image'.
*
*/
private String odataType;
/**
* @return The position relative to transform preset start time 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.
*
*/
private @Nullable String range;
/**
* @return The position in the input video from where to start 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}.
*
*/
private String start;
/**
* @return The intervals at which thumbnails are generated. The 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.
*
*/
private @Nullable String step;
/**
* @return The resizing mode - how the input video will be resized to fit the desired output resolution(s). Default is AutoSize
*
*/
private @Nullable String stretchMode;
/**
* @return The Video Sync Mode
*
*/
private @Nullable String syncMode;
private ImageResponse() {}
/**
* @return The distance between two key frames. The value should be non-zero in the range [0.5, 20] seconds, specified in ISO 8601 format. The default is 2 seconds(PT2S). Note that this setting is ignored if VideoSyncMode.Passthrough is set, where the KeyFrameInterval value will follow the input source setting.
*
*/
public Optional keyFrameInterval() {
return Optional.ofNullable(this.keyFrameInterval);
}
/**
* @return An optional label for the codec. The label can be used to control muxing behavior.
*
*/
public Optional label() {
return Optional.ofNullable(this.label);
}
/**
* @return The discriminator for derived types.
* Expected value is '#Microsoft.Media.Image'.
*
*/
public String odataType() {
return this.odataType;
}
/**
* @return The position relative to transform preset start time 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.
*
*/
public Optional range() {
return Optional.ofNullable(this.range);
}
/**
* @return The position in the input video from where to start 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}.
*
*/
public String start() {
return this.start;
}
/**
* @return The intervals at which thumbnails are generated. The 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.
*
*/
public Optional step() {
return Optional.ofNullable(this.step);
}
/**
* @return The resizing mode - how the input video will be resized to fit the desired output resolution(s). Default is AutoSize
*
*/
public Optional stretchMode() {
return Optional.ofNullable(this.stretchMode);
}
/**
* @return The Video Sync Mode
*
*/
public Optional syncMode() {
return Optional.ofNullable(this.syncMode);
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(ImageResponse defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private @Nullable String keyFrameInterval;
private @Nullable String label;
private String odataType;
private @Nullable String range;
private String start;
private @Nullable String step;
private @Nullable String stretchMode;
private @Nullable String syncMode;
public Builder() {}
public Builder(ImageResponse defaults) {
Objects.requireNonNull(defaults);
this.keyFrameInterval = defaults.keyFrameInterval;
this.label = defaults.label;
this.odataType = defaults.odataType;
this.range = defaults.range;
this.start = defaults.start;
this.step = defaults.step;
this.stretchMode = defaults.stretchMode;
this.syncMode = defaults.syncMode;
}
@CustomType.Setter
public Builder keyFrameInterval(@Nullable String keyFrameInterval) {
this.keyFrameInterval = keyFrameInterval;
return this;
}
@CustomType.Setter
public Builder label(@Nullable String label) {
this.label = label;
return this;
}
@CustomType.Setter
public Builder odataType(String odataType) {
if (odataType == null) {
throw new MissingRequiredPropertyException("ImageResponse", "odataType");
}
this.odataType = odataType;
return this;
}
@CustomType.Setter
public Builder range(@Nullable String range) {
this.range = range;
return this;
}
@CustomType.Setter
public Builder start(String start) {
if (start == null) {
throw new MissingRequiredPropertyException("ImageResponse", "start");
}
this.start = start;
return this;
}
@CustomType.Setter
public Builder step(@Nullable String step) {
this.step = step;
return this;
}
@CustomType.Setter
public Builder stretchMode(@Nullable String stretchMode) {
this.stretchMode = stretchMode;
return this;
}
@CustomType.Setter
public Builder syncMode(@Nullable String syncMode) {
this.syncMode = syncMode;
return this;
}
public ImageResponse build() {
final var _resultValue = new ImageResponse();
_resultValue.keyFrameInterval = keyFrameInterval;
_resultValue.label = label;
_resultValue.odataType = odataType;
_resultValue.range = range;
_resultValue.start = start;
_resultValue.step = step;
_resultValue.stretchMode = stretchMode;
_resultValue.syncMode = syncMode;
return _resultValue;
}
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy