Questions tagged [exoplayer-media-item]
32 questions
6
votes
2 answers
ExoPlayer initialize player deprecated
I'm currently working with the latest ExoPlayer update and I'm getting calls that it is deprecated, could someone help me?
private fun initializePlayer () {
if (simpleExoPlayer == null) {
val trackSelector = DefaultTrackSelector(this)
…

Kevin Paul Montealegre Melo
- 121
- 1
- 1
- 10
1
vote
1 answer
Android exoplayer how i can set the resolution of the video?
i am using exoplayer library in my android tv application, i need to make the resolution of the video better , i tried to set setMAxVideoSize(1920,1080) but not working, also trying to set the minimunBitrate value to Integer.Max_value but not…

Malo
- 1,232
- 2
- 17
- 28
1
vote
1 answer
Unresolved reference: ExoPlayerFactory in ExoPlayerFactory.newSimpleInstance and Type mismatch: inferred type is Uri! but MediaItem was expected in
after updating to the latest build version of ExoPlayer i.e "2.18.1",
ExoPlayerFactory.newSimpleInstance showing unresolved reference Error,
Want to reformat this Initialize Function to the latest version of exoplayer
without changing its…

Sidharth
- 79
- 10
1
vote
1 answer
How to pre-cache HLS adaptive stream in ExoPlayer?
I am trying to pre-cache/pre-buffer HLS videos to my app. I used CacheWriter to cache the (.mp4) file, But it was not able to cache segments of HLS video. Basically, I have only URL of the master playlist file which has media playlists of different…

Abhay Kumar Tiwari
- 31
- 4
1
vote
1 answer
How to convert normal URI to dash URI?
Currently, I have been making streaming video player app. so for that reason I want to use dash streaming. I have a normal URI of video from my firebase storage. but for dash streaming, I think I need a file that ends with .mpd.
ExoPlayer player =…

Parth Kanpariya
- 13
- 3
0
votes
0 answers
Just_audio player is automatically stopped in some device in android after playing few part of audio from internet
I want to make an audio player using just_audio, but when I am playing music from the internet there is some kind of glitch, and it automatically stops the player from playing music, I checked this issue with the emulator and physical device, but…

korner253vn
- 74
- 4
0
votes
1 answer
Problem with exoplayer: can't play stream in android 9 and above
I am making online radio streaming, for a local radio station.
Unfortunately, the stream works ok with android version 8 and below, but it fails in android version 9 and above.
here is my code so far (for the play function)
player = new…

Moh'd Khamis Songoro
- 73
- 4
0
votes
1 answer
exoplayer MediaItem setClippingConfiguration not working if using CacheDataSource
my code is:
val mediaItem: MediaItem = MediaItem.Builder()
.setUri(recitationUri)
.setMediaId("$surah:${ayah}")
.setClippingConfiguration(
ClippingConfiguration.Builder()
…

Hadi Ahmadi
- 1,924
- 2
- 17
- 38
0
votes
0 answers
how to set tag or id for Exoplayer MediaSource?
I am using Exoplayer for playing multiple audio files.
We can set media an Id when creation using:
MediaItem.Builder()
.setUri(uri)
.setMediaId("my_unique_id")
and get media Item id in onMediaItemTransition listener using…

Hadi Ahmadi
- 1,924
- 2
- 17
- 38
0
votes
1 answer
No suitable media source factory found for content type: 2 (type 2 is M3U8)
I'm getting this error when using exoplayer even though i'm specifying the mimo type so don't understand why this crash is happening. The version i'm using is 2.18.7:
videoUrl?.let {
if (it.endsWith(".m3u8")) {
…
0
votes
0 answers
How to Configure license clearkey in exoplayer2
I'm trying to make a media player application with exoplayer2 android. I'm having trouble configuring when the media is clearkey licensed
I've tried with syntax like this, but the video fails to play
String keyString =…

Lionel Yayan
- 1
- 1
0
votes
0 answers
ExoPlayer Video fit inside the view bounds preserving the aspect ratio
I am trying to make an ExoPlayer custom texture view. I intend to make it so that the video should fill in the whole UI container for a given fixed width & height.
For instance, I know most of my videos are of 9:16 aspect ratio so I kept the UI…

Shahbaz Hussain
- 542
- 4
- 21
0
votes
1 answer
Exoplayer DAI with dynamic headers
I'm using Exoplayer (androidx v1.0.1) to implement dynamic ad insertion (DAI) and i must set some custom headers when "live" in playing and remove those headers when ads rolling.
Without headers "live" will not play and i want to remove them when…

BejanCorneliu
- 65
- 3
- 13
0
votes
0 answers
Long duration video not working in Exo player
I have used exoplayer in my app for video playing. Everthing working fine but a video with resolution 1920×1040 and duration 41hr is not playing not even app crashing but getting the errors Following is my source code and then error
public class…
0
votes
1 answer
Exoplayer Downloading Media, DefaultHTTPDataSource is crashing the app
I'm using DownloadService from Exoplayer to download HLS videos. https://exoplayer.dev/downloading-media.html
The links I'm supplying are pre-authorized links for downloading HLS videos. Sometimes I'm seeing an app crash on 401. Stack…

Akshansh Choudhary
- 11
- 2