Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve support for multiple metadata tracks #6676

Closed
phhusson opened this issue Nov 20, 2019 · 3 comments
Closed

Improve support for multiple metadata tracks #6676

phhusson opened this issue Nov 20, 2019 · 3 comments
Assignees

Comments

@phhusson
Copy link
Contributor

phhusson commented Nov 20, 2019

[REQUIRED] Searched documentation and issues

I've browsed https://github.com/google/exoplayer/issues?utf8=%E2%9C%93&q=is%3Aissue+metadata

[REQUIRED] Question

As far as I understand, ExoPlayer currently supports only one metadata track at the same time.
My usecase is to have EIT and TDT DVB tracks (respectively EPG and current time) reported back to the application through onMetadata. So what I want is to select all metadata tracks, instantiate related decoders (based on various mime-types), and have all those metadata sent to a single MetadataOutput.
I don't know if there are cases where we don't want all tracks (there is the case when there are multiple PMTs in the stream, but that's already not well handled by ExoPlayer anyway)
EIT and TDT are just examples, DVB has many other metadata on various tracks. (AIT, BAT, NIT, ...)

What is the recommendation to do that?
Currently i'm thinking of instantiating multiple MetadataRenderer (though it needs to be a constant number, that'll need to be magically set), and changing selectTracks to allow assigning multiple renderers, but that's not really clean...

@AquilesCanta
Copy link
Contributor

As things are now you'll need one Metadata renderer per metadata track you want to handle. The number of renderers depends on the formats you want to handle. For example, if you need to handle ID3 and SCTE35, you'll need to inject two renderers. You will also need to implement track selection so that each of the tracks gets mapped to a different metadata renderer.

In the case of PSI and TS tables in general, I think you can just inject custom payload readers (See TsPayloadReader.Factory) but keep in mind that those payload readers run on a worker thread, so keep cross-thread communication in mind.

I'll use this issue to track better support for multiple metadata tracks.

@AquilesCanta AquilesCanta changed the title Multiple metadata tracks? Improve support for multiple metadata tracks Nov 20, 2019
@tonihei
Copy link
Collaborator

tonihei commented Nov 20, 2019

For the point of using multiple renderers and making it simpler to set them up: There is also #6589 where this question has been asked for audio renderers and #6652 for video renderers (duped to the other one).

@tonihei
Copy link
Collaborator

tonihei commented Aug 27, 2020

This requested enhancement was implemented by #6678, so closing this issue. If there is something left to implement, please file a new issue for tracking. Thanks!

@tonihei tonihei closed this as completed Aug 27, 2020
@google google locked and limited conversation to collaborators Oct 27, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants