Class TranscodingTransformer


  • @RequiresApi(18)
    public final class TranscodingTransformer
    extends Object
    A transcoding transformer to transform media inputs.

    Temporary copy of the Transformer class, which transforms by transcoding rather than by muxing. This class is intended to replace the Transformer class.

    TODO(http://b/202131097): Replace the Transformer class with TranscodingTransformer, and rename this class to Transformer.

    The same TranscodingTransformer instance can be used to transform multiple inputs (sequentially, not concurrently).

    TranscodingTransformer instances must be accessed from a single application thread. For the vast majority of cases this should be the application's main thread. The thread on which a TranscodingTransformer instance must be accessed can be explicitly specified by passing a Looper when creating the transcoding transformer. If no Looper is specified, then the Looper of the thread that the TranscodingTransformer.Builder is created on is used, or if that thread does not have a Looper, the Looper of the application's main thread is used. In all cases the Looper of the thread from which the transcoding transformer must be accessed can be queried using getApplicationLooper().

    • Field Detail

      • PROGRESS_STATE_WAITING_FOR_AVAILABILITY

        public static final int PROGRESS_STATE_WAITING_FOR_AVAILABILITY
        Indicates that the progress is unavailable for the current transformation, but might become available.
        See Also:
        Constant Field Values
      • PROGRESS_STATE_AVAILABLE

        public static final int PROGRESS_STATE_AVAILABLE
        Indicates that the progress is available.
        See Also:
        Constant Field Values
      • PROGRESS_STATE_UNAVAILABLE

        public static final int PROGRESS_STATE_UNAVAILABLE
        Indicates that the progress is permanently unavailable for the current transformation.
        See Also:
        Constant Field Values
      • PROGRESS_STATE_NO_TRANSFORMATION

        public static final int PROGRESS_STATE_NO_TRANSFORMATION
        Indicates that there is no current transformation.
        See Also:
        Constant Field Values