All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.aws.sdk.kotlin.services.mediaconvert.model.FrameCaptureSettings.kt Maven / Gradle / Ivy

There is a newer version: 1.3.34
Show newest version
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.mediaconvert.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * Required when you set Codec to the value FRAME_CAPTURE.
 */
public class FrameCaptureSettings private constructor(builder: Builder) {
    /**
     * Frame capture will encode the first frame of the output stream, then one frame every framerateDenominator/framerateNumerator seconds. For example, settings of framerateNumerator = 1 and framerateDenominator = 3 (a rate of 1/3 frame per second) will capture the first frame, then 1 frame every 3s. Files will be named as filename.n.jpg where n is the 0-based sequence number of each Capture.
     */
    public val framerateDenominator: kotlin.Int? = builder.framerateDenominator
    /**
     * Frame capture will encode the first frame of the output stream, then one frame every framerateDenominator/framerateNumerator seconds. For example, settings of framerateNumerator = 1 and framerateDenominator = 3 (a rate of 1/3 frame per second) will capture the first frame, then 1 frame every 3s. Files will be named as filename.NNNNNNN.jpg where N is the 0-based frame sequence number zero padded to 7 decimal places.
     */
    public val framerateNumerator: kotlin.Int? = builder.framerateNumerator
    /**
     * Maximum number of captures (encoded jpg output files).
     */
    public val maxCaptures: kotlin.Int? = builder.maxCaptures
    /**
     * JPEG Quality - a higher value equals higher quality.
     */
    public val quality: kotlin.Int? = builder.quality

    public companion object {
        public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.mediaconvert.model.FrameCaptureSettings = Builder().apply(block).build()
    }

    override fun toString(): kotlin.String = buildString {
        append("FrameCaptureSettings(")
        append("framerateDenominator=$framerateDenominator,")
        append("framerateNumerator=$framerateNumerator,")
        append("maxCaptures=$maxCaptures,")
        append("quality=$quality")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = framerateDenominator ?: 0
        result = 31 * result + (framerateNumerator ?: 0)
        result = 31 * result + (maxCaptures ?: 0)
        result = 31 * result + (quality ?: 0)
        return result
    }

    override fun equals(other: kotlin.Any?): kotlin.Boolean {
        if (this === other) return true
        if (other == null || this::class != other::class) return false

        other as FrameCaptureSettings

        if (framerateDenominator != other.framerateDenominator) return false
        if (framerateNumerator != other.framerateNumerator) return false
        if (maxCaptures != other.maxCaptures) return false
        if (quality != other.quality) return false

        return true
    }

    public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.mediaconvert.model.FrameCaptureSettings = Builder(this).apply(block).build()

    @SdkDsl
    public class Builder {
        /**
         * Frame capture will encode the first frame of the output stream, then one frame every framerateDenominator/framerateNumerator seconds. For example, settings of framerateNumerator = 1 and framerateDenominator = 3 (a rate of 1/3 frame per second) will capture the first frame, then 1 frame every 3s. Files will be named as filename.n.jpg where n is the 0-based sequence number of each Capture.
         */
        public var framerateDenominator: kotlin.Int? = null
        /**
         * Frame capture will encode the first frame of the output stream, then one frame every framerateDenominator/framerateNumerator seconds. For example, settings of framerateNumerator = 1 and framerateDenominator = 3 (a rate of 1/3 frame per second) will capture the first frame, then 1 frame every 3s. Files will be named as filename.NNNNNNN.jpg where N is the 0-based frame sequence number zero padded to 7 decimal places.
         */
        public var framerateNumerator: kotlin.Int? = null
        /**
         * Maximum number of captures (encoded jpg output files).
         */
        public var maxCaptures: kotlin.Int? = null
        /**
         * JPEG Quality - a higher value equals higher quality.
         */
        public var quality: kotlin.Int? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.mediaconvert.model.FrameCaptureSettings) : this() {
            this.framerateDenominator = x.framerateDenominator
            this.framerateNumerator = x.framerateNumerator
            this.maxCaptures = x.maxCaptures
            this.quality = x.quality
        }

        @PublishedApi
        internal fun build(): aws.sdk.kotlin.services.mediaconvert.model.FrameCaptureSettings = FrameCaptureSettings(this)

        internal fun correctErrors(): Builder {
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy