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

Live H.264 encoding not playing back with ExoPlayer 2.0.4 #2020

Closed
sapanda opened this issue Oct 31, 2016 · 5 comments
Closed

Live H.264 encoding not playing back with ExoPlayer 2.0.4 #2020

sapanda opened this issue Oct 31, 2016 · 5 comments
Assignees
Labels

Comments

@sapanda
Copy link

sapanda commented Oct 31, 2016

Our live streams aren't playing with ExoPlayer 2.0.4. They play fine in 1.5.7. I've attached a sample chunk that doesn't play in ExoPlayer 2. Unfortunately we didn't see anything out of the ordinary in the logs.

Streams are encoded and packaged into HLS using Ateme Titan encoders.

LiveChunk.ts.zip

@sapanda
Copy link
Author

sapanda commented Nov 14, 2016

We noticed an issue around the earlier video - we had GOP size at 60K and fps at 25. Changing the GOP to be a multiple (50K) resolved that issue.

However, we're now trying with a completely different encoder & this time HEVC 4K. Same issue - Everything plays fine in 1.5.7, but only audio plays back in 2.0.4.

LiveChunk_2.ts.zip

Device in question is a Samsung Galaxy S7. But we've had this issue with the Google Pixel as well.

@AquilesCanta AquilesCanta self-assigned this Nov 14, 2016
@AquilesCanta
Copy link
Contributor

Have you seen #1967 ? For me, the first chunk doesn't play in any of exoplayer versions, unless I set FLAG_ALLOW_NON_IDR_KEYFRAMES.

The second one does not play on Nexus 5X(any exopayer version), but I think it's related to decoding capabilities.

I wonder if you are setting the FLAG_ALLOW_NON_IDR_KEYFRAMES flag for version 1.5.7 but not for 2.0.4. Please check if that's the case. If not, let me know and I will explore further.

@sapanda
Copy link
Author

sapanda commented Nov 15, 2016

How do I check if FLAG_ALLOW_NON_IDR_KEYFRAMES is set in 1.5.7? I don't see that flag when doing a global search on 1.5.7. Definitely not set in 2.0.4 though.

@sapanda
Copy link
Author

sapanda commented Nov 16, 2016

OK I just verified, in 1.5.7 we do set H264Reader.sampleIsKeyframe to true in H264Reader.endNalUnit(). I presume that's the equivalent of FLAG_ALLOW_NON_IDR_KEYFRAMES and would explain the issues around the first chunk.

For the 2nd chunk, the issue still persists though - and trackInfo.hasOnlyUnplayableTracks(C.TRACK_TYPE_VIDEO) returns false. So probably something on the decoder side.

@ojw28 ojw28 added the question label Jan 13, 2017
@ojw28
Copy link
Contributor

ojw28 commented Jan 13, 2017

Closing due to inactivity.

@ojw28 ojw28 closed this as completed Jan 13, 2017
@google google locked and limited conversation to collaborators Jun 28, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants