mirror of
https://github.com/samsonjs/media.git
synced 2026-03-26 09:35:47 +00:00
HDR Tests: Rename remote URIs to REMOTE instead of ASSET.
Following naming conventions throughout AndroidTestUtil, REMOTE files should have REMOTE instead of ASSET. Update the URI and FORMAT names accordingly. PiperOrigin-RevId: 490237673
This commit is contained in:
parent
fa531b7924
commit
d0c5168902
4 changed files with 26 additions and 26 deletions
|
|
@ -86,9 +86,9 @@ public final class AndroidTestUtil {
|
|||
.setFrameRate(30.472f)
|
||||
.build();
|
||||
|
||||
public static final String MP4_ASSET_1080P_5_SECOND_HLG10 =
|
||||
public static final String MP4_REMOTE_1080P_5_SECOND_HLG10 =
|
||||
"https://storage.googleapis.com/exoplayer-test-media-1/mp4/Pixel7Pro_HLG_1080P.mp4";
|
||||
public static final Format MP4_ASSET_1080P_5_SECOND_HLG10_FORMAT =
|
||||
public static final Format MP4_REMOTE_1080P_5_SECOND_HLG10_FORMAT =
|
||||
new Format.Builder()
|
||||
.setSampleMimeType(VIDEO_H265)
|
||||
.setWidth(1920)
|
||||
|
|
@ -101,9 +101,9 @@ public final class AndroidTestUtil {
|
|||
C.COLOR_TRANSFER_HLG,
|
||||
/* hdrStaticInfo= */ null))
|
||||
.build();
|
||||
public static final String MP4_ASSET_1080P_4_SECOND_HDR10 =
|
||||
public static final String MP4_REMOTE_1080P_4_SECOND_HDR10 =
|
||||
"https://storage.googleapis.com/exoplayer-test-media-1/mp4/samsung-s21-hdr-hdr10.mp4";
|
||||
public static final Format MP4_ASSET_1080P_4_SECOND_HDR10_FORMAT =
|
||||
public static final Format MP4_REMOTE_1080P_4_SECOND_HDR10_FORMAT =
|
||||
new Format.Builder()
|
||||
.setSampleMimeType(VIDEO_H265)
|
||||
.setWidth(1920)
|
||||
|
|
|
|||
|
|
@ -15,10 +15,10 @@
|
|||
*/
|
||||
package androidx.media3.transformer.mh;
|
||||
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_ASSET_1080P_4_SECOND_HDR10;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_ASSET_1080P_4_SECOND_HDR10_FORMAT;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_ASSET_1080P_5_SECOND_HLG10;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_ASSET_1080P_5_SECOND_HLG10_FORMAT;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_REMOTE_1080P_4_SECOND_HDR10;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_REMOTE_1080P_4_SECOND_HDR10_FORMAT;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_REMOTE_1080P_5_SECOND_HLG10;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_REMOTE_1080P_5_SECOND_HLG10_FORMAT;
|
||||
import static androidx.media3.transformer.mh.analysis.FileUtil.assertFileHasColorTransfer;
|
||||
|
||||
import android.content.Context;
|
||||
|
|
@ -54,7 +54,7 @@ public class ForceInterpretHdrVideoAsSdrTest {
|
|||
if (AndroidTestUtil.skipAndLogIfInsufficientCodecSupport(
|
||||
context,
|
||||
testId,
|
||||
/* decodingFormat= */ MP4_ASSET_1080P_4_SECOND_HDR10_FORMAT,
|
||||
/* decodingFormat= */ MP4_REMOTE_1080P_4_SECOND_HDR10_FORMAT,
|
||||
/* encodingFormat= */ null)) {
|
||||
return;
|
||||
}
|
||||
|
|
@ -71,7 +71,7 @@ public class ForceInterpretHdrVideoAsSdrTest {
|
|||
TransformationTestResult transformationTestResult =
|
||||
new TransformerAndroidTestRunner.Builder(context, transformer)
|
||||
.build()
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_ASSET_1080P_4_SECOND_HDR10)));
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_REMOTE_1080P_4_SECOND_HDR10)));
|
||||
assertFileHasColorTransfer(transformationTestResult.filePath, C.COLOR_TRANSFER_SDR);
|
||||
Log.i(TAG, "Transformed.");
|
||||
} catch (TransformationException exception) {
|
||||
|
|
@ -90,7 +90,7 @@ public class ForceInterpretHdrVideoAsSdrTest {
|
|||
if (AndroidTestUtil.skipAndLogIfInsufficientCodecSupport(
|
||||
context,
|
||||
testId,
|
||||
/* decodingFormat= */ MP4_ASSET_1080P_5_SECOND_HLG10_FORMAT,
|
||||
/* decodingFormat= */ MP4_REMOTE_1080P_5_SECOND_HLG10_FORMAT,
|
||||
/* encodingFormat= */ null)) {
|
||||
return;
|
||||
}
|
||||
|
|
@ -107,7 +107,7 @@ public class ForceInterpretHdrVideoAsSdrTest {
|
|||
TransformationTestResult transformationTestResult =
|
||||
new TransformerAndroidTestRunner.Builder(context, transformer)
|
||||
.build()
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_ASSET_1080P_5_SECOND_HLG10)));
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_REMOTE_1080P_5_SECOND_HLG10)));
|
||||
assertFileHasColorTransfer(transformationTestResult.filePath, C.COLOR_TRANSFER_SDR);
|
||||
Log.i(TAG, "Transformed.");
|
||||
} catch (TransformationException exception) {
|
||||
|
|
|
|||
|
|
@ -18,8 +18,8 @@ package androidx.media3.transformer.mh;
|
|||
import static androidx.media3.common.MimeTypes.VIDEO_H265;
|
||||
import static androidx.media3.common.util.Assertions.checkNotNull;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_ASSET_1080P_1_SECOND_HDR10_VIDEO_SDR_CONTAINER;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_ASSET_1080P_4_SECOND_HDR10;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_ASSET_1080P_5_SECOND_HLG10;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_REMOTE_1080P_4_SECOND_HDR10;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_REMOTE_1080P_5_SECOND_HLG10;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.recordTestSkipped;
|
||||
import static androidx.media3.transformer.mh.analysis.FileUtil.assertFileHasColorTransfer;
|
||||
import static com.google.common.truth.Truth.assertThat;
|
||||
|
|
@ -74,7 +74,7 @@ public class HdrEditingTest {
|
|||
TransformationTestResult transformationTestResult =
|
||||
new TransformerAndroidTestRunner.Builder(context, transformer)
|
||||
.build()
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_ASSET_1080P_4_SECOND_HDR10)));
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_REMOTE_1080P_4_SECOND_HDR10)));
|
||||
Log.i(TAG, "Transformed.");
|
||||
assertFileHasColorTransfer(transformationTestResult.filePath, C.COLOR_TRANSFER_ST2084);
|
||||
return;
|
||||
|
|
@ -97,7 +97,7 @@ public class HdrEditingTest {
|
|||
TransformationTestResult transformationTestResult =
|
||||
new TransformerAndroidTestRunner.Builder(context, transformer)
|
||||
.build()
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_ASSET_1080P_5_SECOND_HLG10)));
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_REMOTE_1080P_5_SECOND_HLG10)));
|
||||
Log.i(TAG, "Transformed.");
|
||||
assertFileHasColorTransfer(transformationTestResult.filePath, C.COLOR_TRANSFER_HLG);
|
||||
return;
|
||||
|
|
@ -128,7 +128,7 @@ public class HdrEditingTest {
|
|||
TransformationTestResult transformationTestResult =
|
||||
new TransformerAndroidTestRunner.Builder(context, transformer)
|
||||
.build()
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_ASSET_1080P_4_SECOND_HDR10)));
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_REMOTE_1080P_4_SECOND_HDR10)));
|
||||
assertFileHasColorTransfer(transformationTestResult.filePath, C.COLOR_TRANSFER_ST2084);
|
||||
}
|
||||
|
||||
|
|
@ -151,7 +151,7 @@ public class HdrEditingTest {
|
|||
TransformationTestResult transformationTestResult =
|
||||
new TransformerAndroidTestRunner.Builder(context, transformer)
|
||||
.build()
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_ASSET_1080P_5_SECOND_HLG10)));
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_REMOTE_1080P_5_SECOND_HLG10)));
|
||||
assertFileHasColorTransfer(transformationTestResult.filePath, C.COLOR_TRANSFER_HLG);
|
||||
}
|
||||
|
||||
|
|
@ -192,7 +192,7 @@ public class HdrEditingTest {
|
|||
TransformationTestResult transformationTestResult =
|
||||
new TransformerAndroidTestRunner.Builder(context, transformer)
|
||||
.build()
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_ASSET_1080P_4_SECOND_HDR10)));
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_REMOTE_1080P_4_SECOND_HDR10)));
|
||||
Log.i(TAG, "Tone mapped.");
|
||||
assertThat(isToneMappingFallbackApplied.get()).isTrue();
|
||||
assertFileHasColorTransfer(transformationTestResult.filePath, C.COLOR_TRANSFER_SDR);
|
||||
|
|
@ -245,7 +245,7 @@ public class HdrEditingTest {
|
|||
TransformationTestResult transformationTestResult =
|
||||
new TransformerAndroidTestRunner.Builder(context, transformer)
|
||||
.build()
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_ASSET_1080P_5_SECOND_HLG10)));
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_REMOTE_1080P_5_SECOND_HLG10)));
|
||||
Log.i(TAG, "Tone mapped.");
|
||||
assertThat(isToneMappingFallbackApplied.get()).isTrue();
|
||||
assertFileHasColorTransfer(transformationTestResult.filePath, C.COLOR_TRANSFER_SDR);
|
||||
|
|
|
|||
|
|
@ -16,8 +16,8 @@
|
|||
package androidx.media3.transformer.mh;
|
||||
|
||||
import static androidx.media3.common.util.Assertions.checkNotNull;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_ASSET_1080P_4_SECOND_HDR10;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_ASSET_1080P_5_SECOND_HLG10;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_REMOTE_1080P_4_SECOND_HDR10;
|
||||
import static androidx.media3.transformer.AndroidTestUtil.MP4_REMOTE_1080P_5_SECOND_HLG10;
|
||||
import static androidx.media3.transformer.mh.analysis.FileUtil.assertFileHasColorTransfer;
|
||||
import static com.google.common.truth.Truth.assertThat;
|
||||
|
||||
|
|
@ -74,7 +74,7 @@ public class HdrToSdrToneMapTest {
|
|||
TransformationTestResult transformationTestResult =
|
||||
new TransformerAndroidTestRunner.Builder(context, transformer)
|
||||
.build()
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_ASSET_1080P_4_SECOND_HDR10)));
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_REMOTE_1080P_4_SECOND_HDR10)));
|
||||
Log.i(TAG, "Tone mapped.");
|
||||
assertFileHasColorTransfer(transformationTestResult.filePath, C.COLOR_TRANSFER_SDR);
|
||||
return;
|
||||
|
|
@ -119,7 +119,7 @@ public class HdrToSdrToneMapTest {
|
|||
TransformationTestResult transformationTestResult =
|
||||
new TransformerAndroidTestRunner.Builder(context, transformer)
|
||||
.build()
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_ASSET_1080P_5_SECOND_HLG10)));
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_REMOTE_1080P_5_SECOND_HLG10)));
|
||||
Log.i(TAG, "Tone mapped.");
|
||||
assertFileHasColorTransfer(transformationTestResult.filePath, C.COLOR_TRANSFER_SDR);
|
||||
return;
|
||||
|
|
@ -165,7 +165,7 @@ public class HdrToSdrToneMapTest {
|
|||
TransformationTestResult transformationTestResult =
|
||||
new TransformerAndroidTestRunner.Builder(context, transformer)
|
||||
.build()
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_ASSET_1080P_4_SECOND_HDR10)));
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_REMOTE_1080P_4_SECOND_HDR10)));
|
||||
Log.i(TAG, "Tone mapped.");
|
||||
assertFileHasColorTransfer(transformationTestResult.filePath, C.COLOR_TRANSFER_SDR);
|
||||
return;
|
||||
|
|
@ -211,7 +211,7 @@ public class HdrToSdrToneMapTest {
|
|||
TransformationTestResult transformationTestResult =
|
||||
new TransformerAndroidTestRunner.Builder(context, transformer)
|
||||
.build()
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_ASSET_1080P_5_SECOND_HLG10)));
|
||||
.run(testId, MediaItem.fromUri(Uri.parse(MP4_REMOTE_1080P_5_SECOND_HLG10)));
|
||||
Log.i(TAG, "Tone mapped.");
|
||||
assertFileHasColorTransfer(transformationTestResult.filePath, C.COLOR_TRANSFER_SDR);
|
||||
return;
|
||||
|
|
|
|||
Loading…
Reference in a new issue