Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6bc5ae0c authored by hkuang's avatar hkuang
Browse files

Transcoding: Add HEVC->AVC performance test.

Due to slowness in transcoding video with audio, only adding
the video only file for now.

Bug: 154734456
Test: Unit test.
Change-Id: I5a353e24cca0a6624df4e9309ac64bc2fef4b0ed
parent 0b06c341
Loading
Loading
Loading
Loading
+46 −1
Original line number Diff line number Diff line
@@ -284,4 +284,49 @@ public class MediaTranscodingBenchmark

        transcode(testVideoName, transcodedVideoName);
    } */

    @Test
    public void testBenchmarkingHEVCToAVCWith107FramesWithoutAudio() throws Exception {
        String videoNameWithoutExtension = "video_1920x1080_107frame_hevc_4Mbps_30fps";
        String testVideoName = videoNameWithoutExtension + ".mp4";
        String transcodedVideoName = videoNameWithoutExtension + "_transcode.mp4";

        transcode(testVideoName, transcodedVideoName);
    }

    @Test
    public void testBenchmarkingHEVCToAVCWith928FramesWithoutAudio() throws Exception {
        String videoNameWithoutExtension = "video_1920x1080_928frame_hevc_4Mbps_30fps";
        String testVideoName = videoNameWithoutExtension + ".mp4";
        String transcodedVideoName = videoNameWithoutExtension + "_transcode.mp4";

        transcode(testVideoName, transcodedVideoName);
    }

    @Test
    public void testBenchmarkingHEVCToAVCWith1863FramesWithoutAudio() throws Exception {
        String videoNameWithoutExtension = "video_1920x1080_1863frame_hevc_4Mbps_30fps";
        String testVideoName = videoNameWithoutExtension + ".mp4";
        String transcodedVideoName = videoNameWithoutExtension + "_transcode.mp4";

        transcode(testVideoName, transcodedVideoName);
    }

    @Test
    public void testBenchmarkingHEVCToAVCWith3863FramesWithoutAudio() throws Exception {
        String videoNameWithoutExtension = "video_1920x1080_3863frame_hevc_4Mbps_30fps";
        String testVideoName = videoNameWithoutExtension + ".mp4";
        String transcodedVideoName = videoNameWithoutExtension + "_transcode.mp4";

        transcode(testVideoName, transcodedVideoName);
    }

    @Test
    public void testBenchmarkingHEVCToAVCWith9374FramesWithoutAudio() throws Exception {
        String videoNameWithoutExtension = "video_1920x1080_9374frame_hevc_4Mbps_30fps";
        String testVideoName = videoNameWithoutExtension + ".mp4";
        String transcodedVideoName = videoNameWithoutExtension + "_transcode.mp4";

        transcode(testVideoName, transcodedVideoName);
    }
}