Class ExportResult.Builder
- java.lang.Object
-
- com.google.android.exoplayer2.transformer.ExportResult.Builder
-
- Enclosing class:
- ExportResult
public static final class ExportResult.Builder extends Object
A builder forExportResult
instances.
-
-
Constructor Summary
Constructors Constructor Description Builder()
Creates a builder.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ExportResult
build()
Builds anExportResult
instance.ExportResult.Builder
setAudioEncoderName(String audioEncoderName)
Sets the name of the audio encoder used.ExportResult.Builder
setAverageAudioBitrate(int averageAudioBitrate)
Sets the average audio bitrate.ExportResult.Builder
setAverageVideoBitrate(int averageVideoBitrate)
Sets the average video bitrate.ExportResult.Builder
setChannelCount(int channelCount)
Sets the channel count.ExportResult.Builder
setColorInfo(ColorInfo colorInfo)
Sets theColorInfo
.ExportResult.Builder
setDurationMs(long durationMs)
Sets the duration of the output in milliseconds.ExportResult.Builder
setExportException(ExportException exportException)
Sets theExportException
that caused the export to fail.ExportResult.Builder
setFileSizeBytes(long fileSizeBytes)
Sets the file size in bytes.ExportResult.Builder
setHeight(int height)
Sets the height.ExportResult.Builder
setProcessedInputs(ImmutableList<ExportResult.ProcessedInput> processedInputs)
Sets the processed inputs.ExportResult.Builder
setSampleRate(int sampleRate)
Sets the sample rate.ExportResult.Builder
setVideoEncoderName(String videoEncoderName)
Sets the name of the video encoder used.ExportResult.Builder
setVideoFrameCount(int videoFrameCount)
Sets the number of video frames.ExportResult.Builder
setWidth(int width)
Sets the width.
-
-
-
Method Detail
-
setProcessedInputs
@CanIgnoreReturnValue public ExportResult.Builder setProcessedInputs(ImmutableList<ExportResult.ProcessedInput> processedInputs)
Sets the processed inputs.
-
setDurationMs
@CanIgnoreReturnValue public ExportResult.Builder setDurationMs(long durationMs)
Sets the duration of the output in milliseconds.Must be positive or
C.TIME_UNSET
.
-
setFileSizeBytes
@CanIgnoreReturnValue public ExportResult.Builder setFileSizeBytes(long fileSizeBytes)
Sets the file size in bytes.Must be positive or
C.LENGTH_UNSET
.
-
setAverageAudioBitrate
@CanIgnoreReturnValue public ExportResult.Builder setAverageAudioBitrate(int averageAudioBitrate)
Sets the average audio bitrate.Must be positive or
C.RATE_UNSET_INT
.
-
setChannelCount
@CanIgnoreReturnValue public ExportResult.Builder setChannelCount(int channelCount)
Sets the channel count.Must be positive or
C.LENGTH_UNSET
.
-
setSampleRate
@CanIgnoreReturnValue public ExportResult.Builder setSampleRate(int sampleRate)
Sets the sample rate.Must be positive or
C.RATE_UNSET_INT
.
-
setAudioEncoderName
@CanIgnoreReturnValue public ExportResult.Builder setAudioEncoderName(@Nullable String audioEncoderName)
Sets the name of the audio encoder used.
-
setAverageVideoBitrate
@CanIgnoreReturnValue public ExportResult.Builder setAverageVideoBitrate(int averageVideoBitrate)
Sets the average video bitrate.Must be positive or
C.RATE_UNSET_INT
.
-
setColorInfo
@CanIgnoreReturnValue public ExportResult.Builder setColorInfo(@Nullable ColorInfo colorInfo)
Sets theColorInfo
.
-
setHeight
@CanIgnoreReturnValue public ExportResult.Builder setHeight(int height)
Sets the height.Must be positive or
C.LENGTH_UNSET
.
-
setWidth
@CanIgnoreReturnValue public ExportResult.Builder setWidth(int width)
Sets the width.Must be positive or
C.LENGTH_UNSET
.
-
setVideoFrameCount
@CanIgnoreReturnValue public ExportResult.Builder setVideoFrameCount(int videoFrameCount)
Sets the number of video frames.Must be positive or
0
.
-
setVideoEncoderName
@CanIgnoreReturnValue public ExportResult.Builder setVideoEncoderName(@Nullable String videoEncoderName)
Sets the name of the video encoder used.
-
setExportException
@CanIgnoreReturnValue public ExportResult.Builder setExportException(@Nullable ExportException exportException)
Sets theExportException
that caused the export to fail.
-
build
public ExportResult build()
Builds anExportResult
instance.
-
-