transcoding: Enable the benchmark for video file with audio.
They are disabled due to bug in transcoding file with audio. Bug: 154734675 Test: Benchmarking test. Change-Id: Id4b6d4da5b09cc1f8cc6fc1604bf55d73f9a2cf1
This commit is contained in:
@@ -89,7 +89,7 @@ public class MediaTranscodingBenchmark
|
||||
Log.d(TAG, "setUp");
|
||||
super.setUp();
|
||||
mContext = getInstrumentation().getContext();
|
||||
mMediaTranscodeManager = MediaTranscodeManager.getInstance(mContext);
|
||||
mMediaTranscodeManager = mContext.getSystemService(MediaTranscodeManager.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -132,9 +132,9 @@ public class MediaTranscodingBenchmark
|
||||
Log.d(TAG,
|
||||
"Transcoding completed with result: " + transcodingJob.getResult());
|
||||
assertEquals(transcodingJob.getResult(), TranscodingJob.RESULT_SUCCESS);
|
||||
transcodeCompleteSemaphore.release();
|
||||
transcodingTime.set(System.currentTimeMillis() - startTimeMs);
|
||||
totalTimeMs.addAndGet(transcodingTime.get());
|
||||
transcodeCompleteSemaphore.release();
|
||||
});
|
||||
|
||||
if (job != null) {
|
||||
@@ -173,9 +173,6 @@ public class MediaTranscodingBenchmark
|
||||
transcode(testVideoName, transcodedVideoName);
|
||||
}
|
||||
|
||||
// TODO(hkuang): Enable this after b/160268606 is fixed. Transcoding video with audio takes way
|
||||
// more long time that leads to timeout failure.
|
||||
/*
|
||||
@Test
|
||||
public void testBenchmarkingAVCToAVCWith66FramesWithAudio() throws Exception {
|
||||
String videoNameWithoutExtension = "video_1920x1080_66frame_h264_22Mbps_30fps_aac";
|
||||
@@ -183,7 +180,7 @@ public class MediaTranscodingBenchmark
|
||||
String transcodedVideoName = videoNameWithoutExtension + "_transcode.mp4";
|
||||
|
||||
transcode(testVideoName, transcodedVideoName);
|
||||
}*/
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testBenchmarkingAVCToAVCWith361FramesWithoutAudio() throws Exception {
|
||||
@@ -194,16 +191,14 @@ public class MediaTranscodingBenchmark
|
||||
transcode(testVideoName, transcodedVideoName);
|
||||
}
|
||||
|
||||
// TODO(hkuang): Enable this after b/160268606 is fixed. Transcoding video with audio takes way
|
||||
// more long time that leads to timeout failure.
|
||||
/*@Test
|
||||
@Test
|
||||
public void testBenchmarkingAVCToAVCWith361FramesWithAudio() throws Exception {
|
||||
String videoNameWithoutExtension = "video_1920x1080_361frame_h264_22Mbps_30fps_aac";
|
||||
String testVideoName = videoNameWithoutExtension + ".mp4";
|
||||
String transcodedVideoName = videoNameWithoutExtension + "_transcode.mp4";
|
||||
|
||||
transcode(testVideoName, transcodedVideoName);
|
||||
}*/
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testBenchmarkingAVCToAVCWith943FramesWithoutAudio() throws Exception {
|
||||
@@ -214,16 +209,14 @@ public class MediaTranscodingBenchmark
|
||||
transcode(testVideoName, transcodedVideoName);
|
||||
}
|
||||
|
||||
// TODO(hkuang): Enable this after b/160268606 is fixed. Transcoding video with audio takes way
|
||||
// more long time that leads to timeout failure.
|
||||
/* @Test
|
||||
@Test
|
||||
public void testBenchmarkingAVCToAVCWith943FramesWithAudio() throws Exception {
|
||||
String videoNameWithoutExtension = "video_1920x1080_943frame_h264_22Mbps_30fps_aac";
|
||||
String testVideoName = videoNameWithoutExtension + ".mp4";
|
||||
String transcodedVideoName = videoNameWithoutExtension + "_transcode.mp4";
|
||||
|
||||
transcode(testVideoName, transcodedVideoName);
|
||||
}*/
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testBenchmarkingAVCToAVCWith1822FramesWithoutAudio() throws Exception {
|
||||
@@ -234,16 +227,14 @@ public class MediaTranscodingBenchmark
|
||||
transcode(testVideoName, transcodedVideoName);
|
||||
}
|
||||
|
||||
// TODO(hkuang): Enable this after b/160268606 is fixed. Transcoding video with audio takes way
|
||||
// more long time that leads to timeout failure.
|
||||
/*@Test
|
||||
@Test
|
||||
public void testBenchmarkingAVCToAVCWith1822FramesWithAudio() throws Exception {
|
||||
String videoNameWithoutExtension = "video_1920x1080_1822frame_h264_22Mbps_30fps_aac";
|
||||
String testVideoName = videoNameWithoutExtension + ".mp4";
|
||||
String transcodedVideoName = videoNameWithoutExtension + "_transcode.mp4";
|
||||
|
||||
transcode(testVideoName, transcodedVideoName);
|
||||
}*/
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testBenchmarkingAVCToAVCWith3648FramesWithoutAudio() throws Exception {
|
||||
@@ -254,16 +245,14 @@ public class MediaTranscodingBenchmark
|
||||
transcode(testVideoName, transcodedVideoName);
|
||||
}
|
||||
|
||||
// TODO(hkuang): Enable this after b/160268606 is fixed. Transcoding video with audio takes way
|
||||
// more long time that leads to timeout failure.
|
||||
/*@Test
|
||||
@Test
|
||||
public void testBenchmarkingAVCToAVCWith3648FramesWithAudio() throws Exception {
|
||||
String videoNameWithoutExtension = "video_1920x1080_3648frame_h264_22Mbps_30fps_aac";
|
||||
String testVideoName = videoNameWithoutExtension + ".mp4";
|
||||
String transcodedVideoName = videoNameWithoutExtension + "_transcode.mp4";
|
||||
|
||||
transcode(testVideoName, transcodedVideoName);
|
||||
}*/
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testBenchmarkingAVCToAVCWith11042FramesWithoutAudio() throws Exception {
|
||||
@@ -274,16 +263,14 @@ public class MediaTranscodingBenchmark
|
||||
transcode(testVideoName, transcodedVideoName);
|
||||
}
|
||||
|
||||
// TODO(hkuang): Enable this after b/160268606 is fixed. Transcoding video with audio takes way
|
||||
// more long time that leads to timeout failure.
|
||||
/*@Test
|
||||
@Test
|
||||
public void testBenchmarkingAVCToAVCWith11042FramesWithAudio() throws Exception {
|
||||
String videoNameWithoutExtension = "video_1920x1080_11042frame_h264_22Mbps_30fps_aac";
|
||||
String testVideoName = videoNameWithoutExtension + ".mp4";
|
||||
String transcodedVideoName = videoNameWithoutExtension + "_transcode.mp4";
|
||||
|
||||
transcode(testVideoName, transcodedVideoName);
|
||||
} */
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testBenchmarkingHEVCToAVCWith107FramesWithoutAudio() throws Exception {
|
||||
|
||||
Reference in New Issue
Block a user