Package 

Object FFMpegTranscoder

    • Method Detail

      • isSupported

         final Boolean isSupported(Context context)

        true if FFmpeg is supported.

        Parameters:
        context - application context
      • extractFramesFromVideo

         final Observable<Progress> extractFramesFromVideo(Context context, List<String> frameTimes, Uri inputVideo, String id, Uri outputDir, @IntRange(from = 1.toLong(), to = 31.toLong()) Integer photoQuality)
        Parameters:
        context - application context
        frameTimes - list of ms of the requested frames at source video - example "1.
        inputVideo - Uri of the source video
        id - unique output folder id
        outputDir - optional - output directory, if not provided internal storage will be used
        photoQuality - quality of extracted frames - Effective range for JPEG is 2-31 with 31 being the worst quality
      • transcode

         final Observable<Progress> transcode(Uri inputVideo, Uri outputUri)

        Stream copies and adds few more idr frames.

        Parameters:
        inputVideo - input video
        outputUri - output video
      • createVideoFromFrames

         final Observable<Progress> createVideoFromFrames(Uri frameFolder, Uri outputUri, EncodingConfig config, Boolean deleteFramesOnComplete)

        Merges a sequence of images into a video. Returns a stream with Progress.

        Parameters:
        frameFolder - extracted frames directory
        outputUri - video output directory
        deleteFramesOnComplete - removes image sequence directory after successful completion.