Remove DefaultSsChunkSource from nullness blacklist
Issue: #6981 PiperOrigin-RevId: 295584705
This commit is contained in:
parent
3591562364
commit
1dbf2997c4
@ -46,12 +46,13 @@ public abstract class Chunk implements Loadable {
|
||||
public final Format trackFormat;
|
||||
/**
|
||||
* One of the {@link C} {@code SELECTION_REASON_*} constants if the chunk belongs to a track.
|
||||
* {@link C#SELECTION_REASON_UNKNOWN} if the chunk does not belong to a track.
|
||||
* {@link C#SELECTION_REASON_UNKNOWN} if the chunk does not belong to a track, or if the selection
|
||||
* reason is unknown.
|
||||
*/
|
||||
public final int trackSelectionReason;
|
||||
/**
|
||||
* Optional data associated with the selection of the track to which this chunk belongs. Null if
|
||||
* the chunk does not belong to a track.
|
||||
* the chunk does not belong to a track, or if there is no associated track selection data.
|
||||
*/
|
||||
@Nullable public final Object trackSelectionData;
|
||||
/**
|
||||
|
@ -15,6 +15,7 @@
|
||||
*/
|
||||
package com.google.android.exoplayer2.source.chunk;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
import com.google.android.exoplayer2.C;
|
||||
import com.google.android.exoplayer2.Format;
|
||||
import com.google.android.exoplayer2.extractor.DefaultExtractorInput;
|
||||
@ -67,7 +68,7 @@ public class ContainerMediaChunk extends BaseMediaChunk {
|
||||
DataSpec dataSpec,
|
||||
Format trackFormat,
|
||||
int trackSelectionReason,
|
||||
Object trackSelectionData,
|
||||
@Nullable Object trackSelectionData,
|
||||
long startTimeUs,
|
||||
long endTimeUs,
|
||||
long clippedStartTimeUs,
|
||||
|
@ -38,6 +38,7 @@ import com.google.android.exoplayer2.upstream.DataSource;
|
||||
import com.google.android.exoplayer2.upstream.DataSpec;
|
||||
import com.google.android.exoplayer2.upstream.LoaderErrorThrower;
|
||||
import com.google.android.exoplayer2.upstream.TransferListener;
|
||||
import com.google.android.exoplayer2.util.Assertions;
|
||||
import java.io.IOException;
|
||||
import java.util.List;
|
||||
|
||||
@ -80,7 +81,7 @@ public class DefaultSsChunkSource implements SsChunkSource {
|
||||
private SsManifest manifest;
|
||||
private int currentManifestChunkOffset;
|
||||
|
||||
private IOException fatalError;
|
||||
@Nullable private IOException fatalError;
|
||||
|
||||
/**
|
||||
* @param manifestLoaderErrorThrower Throws errors affecting loading of manifests.
|
||||
@ -106,8 +107,11 @@ public class DefaultSsChunkSource implements SsChunkSource {
|
||||
for (int i = 0; i < extractorWrappers.length; i++) {
|
||||
int manifestTrackIndex = trackSelection.getIndexInTrackGroup(i);
|
||||
Format format = streamElement.formats[manifestTrackIndex];
|
||||
@Nullable
|
||||
TrackEncryptionBox[] trackEncryptionBoxes =
|
||||
format.drmInitData != null ? manifest.protectionElement.trackEncryptionBoxes : null;
|
||||
format.drmInitData != null
|
||||
? Assertions.checkNotNull(manifest.protectionElement).trackEncryptionBoxes
|
||||
: null;
|
||||
int nalUnitLengthFieldLength = streamElement.type == C.TRACK_TYPE_VIDEO ? 4 : 0;
|
||||
Track track = new Track(manifestTrackIndex, streamElement.type, streamElement.timescale,
|
||||
C.TIME_UNSET, manifest.durationUs, format, Track.TRANSFORMATION_NONE,
|
||||
@ -277,7 +281,7 @@ public class DefaultSsChunkSource implements SsChunkSource {
|
||||
long chunkEndTimeUs,
|
||||
long chunkSeekTimeUs,
|
||||
int trackSelectionReason,
|
||||
Object trackSelectionData,
|
||||
@Nullable Object trackSelectionData,
|
||||
ChunkExtractorWrapper extractorWrapper) {
|
||||
DataSpec dataSpec = new DataSpec(uri);
|
||||
// In SmoothStreaming each chunk contains sample timestamps relative to the start of the chunk.
|
||||
|
Loading…
x
Reference in New Issue
Block a user