mirror of
https://github.com/samsonjs/media.git
synced 2026-03-25 09:25:53 +00:00
Handle both media3-cues and 'raw' vtt
This commit is contained in:
parent
74885558e4
commit
9e3c64866e
1 changed files with 5 additions and 1 deletions
|
|
@ -355,7 +355,11 @@ public class PlayerActivity extends AppCompatActivity
|
|||
int size,
|
||||
int offset,
|
||||
@Nullable CryptoData cryptoData) {
|
||||
if (format != null && Objects.equals(format.sampleMimeType, MimeTypes.APPLICATION_MP4VTT)) {
|
||||
if (format != null
|
||||
&& (Objects.equals(format.sampleMimeType, MimeTypes.APPLICATION_MP4VTT)
|
||||
|| (Objects.equals(format.sampleMimeType, MimeTypes.APPLICATION_MEDIA3_CUES)
|
||||
&& format.codecs != null
|
||||
&& format.codecs.contains(MimeTypes.APPLICATION_MP4VTT)))) {
|
||||
flags |= C.BUFFER_FLAG_KEY_FRAME;
|
||||
}
|
||||
super.sampleMetadata(timeUs, flags, size, offset, cryptoData);
|
||||
|
|
|
|||
Loading…
Reference in a new issue