media3/libraries
kimvde a1d2310170 Fix stuck player after seek
Seeking was causing the player to hang in the following scenario:
1. The surfaceTexture's onFrameAvailableListener is called in
   ExternalTextureManager to notify that a new frame is available.
2. This call submits a task on the GL thread.
3. A seek is performed and DefaultVideoFrameProcessor.flush() is called
   before the task submitted in 2 is executed.
4. DefaultVideoFrameProcessor.flush() flushes the task executor, so that
   the task submitted in 2 never gets executed.
5. Once the seek is over, the first frame is registered and rendered on
   the surface texture.
6. Playback hangs because the onFrameAvailableListener is never called
   for this new frame. This is because surfaceTexture.updateTexImage()
   was never called on the frame that became available in 1.

This fix is making sure that the task submitted in 2 always gets executed.

Issue: androidx/media#1535
PiperOrigin-RevId: 671389215
2024-09-05 08:54:55 -07:00
..
2024-08-07 12:28:25 -07:00
2024-07-24 16:17:00 +01:00
2024-07-24 16:17:00 +01:00
2024-07-24 16:17:00 +01:00
2024-09-05 08:54:55 -07:00
2024-08-07 12:28:25 -07:00
2024-07-24 16:17:00 +01:00
2024-08-29 10:25:06 +01:00