Id3Decoder
@UnstableApi
public final class Id3Decoder extends SimpleMetadataDecoder
| java.lang.Object | ||
| ↳ | androidx.media3.extractor.metadata.SimpleMetadataDecoder | |
| ↳ | androidx.media3.extractor.metadata.id3.Id3Decoder |
Decodes ID3 tags.
Summary
Nested types |
|---|
public interface Id3Decoder.FramePredicateA predicate for determining whether individual frames should be decoded. |
Constants |
|
|---|---|
static final int |
ID3_HEADER_LENGTH = 10Length of an ID3 tag header. |
static final int |
ID3_TAG = 4801587The first three bytes of a well formed ID3 tag header. |
static final Id3Decoder.FramePredicate |
A predicate that indicates artwork frames should not be decoded. |
static final Id3Decoder.FramePredicate |
A predicate that indicates no frames should be decoded. |
Public constructors |
|---|
Id3Decoder(@Nullable Id3Decoder.FramePredicate framePredicate) |
Protected methods |
|
|---|---|
@Nullable Metadata |
decode(MetadataInputBuffer inputBuffer, ByteBuffer buffer)Called by |
Inherited methods |
||
|---|---|---|
|
Constants
ID3_TAG
public static final int ID3_TAG = 4801587
The first three bytes of a well formed ID3 tag header.
NO_ARTWORK_PREDICATE
public static final Id3Decoder.FramePredicate NO_ARTWORK_PREDICATE
A predicate that indicates artwork frames should not be decoded.
NO_FRAMES_PREDICATE
public static final Id3Decoder.FramePredicate NO_FRAMES_PREDICATE
A predicate that indicates no frames should be decoded.
Public constructors
Id3Decoder
public Id3Decoder(@Nullable Id3Decoder.FramePredicate framePredicate)
| Parameters | |
|---|---|
@Nullable Id3Decoder.FramePredicate framePredicate |
Determines which frames are decoded. May be null to decode all frames. |
Public methods
Protected methods
decode
protected @Nullable Metadata decode(MetadataInputBuffer inputBuffer, ByteBuffer buffer)
Called by decode after input buffer validation has been performed.
| Parameters | |
|---|---|
MetadataInputBuffer inputBuffer |
The input buffer to decode. |
ByteBuffer buffer |
The input buffer's |