-
Notifications
You must be signed in to change notification settings - Fork 5
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
Add MPEG-DASH support to playback #27
Conversation
@@ -96,6 +96,8 @@ internal class ExoplayerDownloadEngine @Inject constructor(private val context: | |||
return when (@C.ContentType val type = Util.inferContentType(uri)) { | |||
C.TYPE_HLS -> | |||
DownloadHelper.forMediaItem(context, mediaItem, renderersFactory, DefaultDataSource.Factory(context, dataSourceFactory)) | |||
C.TYPE_DASH -> | |||
DownloadHelper.forMediaItem(context, mediaItem, renderersFactory, DefaultDataSource.Factory(context, dataSourceFactory)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is DASH likely to diverge from HLS? If not, you should combine these cases.
import javax.inject.Inject | ||
import javax.inject.Singleton | ||
|
||
@Singleton |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just curious what @Singleton
does here? I thought it only needs to be on the provides method.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're probably right, but I think it's helpful to see it here to see that it's a singleton, otherwise it's hidden.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Adds support for playback. Create new MediaSourceGenerator. Refactors some common code into a header aware helper.