New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 872056 link

Starred by 2 users

Issue metadata

Status: WontFix
Owner:
Closed: Aug 31
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 1
Type: Bug



Sign in to add a comment

In tab switcher mode youtube video flashes purple

Project Member Reported by lethalantidote@chromium.org, Aug 7

Issue description

Precondition:
**Enable the flag 'Surfacelayer objects for videos' from Chrome://flags

Steps to reproduce: 
1.Launch Chrome 
2.Search or Enter URL(m.youtube.com)
3.Play video 
4.Open New Tab and click on any article
5.Click on tab switcher button
6.Click on tab with youtube video
7.Play video

Observed behavior: 
youtube video flashes purple before playing as normal

Expected behavior: 
Video shouldn't flash purple

Frequency:100%

 
Status: Started (was: Assigned)
Upon the purple flash, we get this error message:

08-07 15:58:33.037 11436 11436 E chromium: [ERROR:surface_manager.cc(329)] No surface in map for SurfaceId(FrameSinkId(5, 7), LocalSurfaceId(1, 1, 2266...))

So I did some preliminary research, and I think its because when we go to tab-switcher-mode, we tear down the SurfaceLayerBridge and the VideoFrameCompositor, but I don't think we are notifying the SurfaceManager of this change. Hypothesis: the SurfaceManager is waiting for the old SurfaceId, but gets the new one (created when we go back to the video) instead so it errors. 
Its actually the reverse, an old frame comes in, and the SurfaceManager no longer as reference to it. 
You're probably not assigning the fallback surface ID somewhere.
Does this only show up on Android?
FWIW, I've seen the same isuse when swapping video src in some cases. Though, on a release build, the frame stays black and would be pink on debug.

Given that YouTube is clearing the src when the page is no longer visible, I wonder if we may hit the same bug here.
to note, it doesnt seem to repro on mobile outside of Youtube, so it seems like it could be the same bug
re c#3: fallback should be set OnFirstSurfaceActivation to the newly-activated surface, along with the primary in SurfaceLayerBridge::OnFirst...()

when the CompositorFrameSink is destroyed, will the fallback surface ID continue to work?
If the GPU process crashes then no, the fallback will stop working. We should clear the fallback at that point.
wait -- did the gpu process crash in this case?  i thought nothing like that happened.  i thought the renderer just closed the CompositorFrameSink.

either way, but that's handy info -- we don't ever clear it, if i remember.
The GPU isnt crashing, we are just clearing the src. 
Try enabling surface synchronization? I'm kind of surprised this is happening.

--enable-surface-synchronization

--enable-features=SurfaceSynchronization
I am able to repro a similar issue on desktop (not m.youtube.com) and these flags did not help :(
I haven't been able to repro?
On desktop, using a debug build from trunk, you should be able to see a pink PIP window with one of the steps from  bug 870853 .

lethalantidote@, were you using a debug Chrome Android when you found that issue? On a release build, I see a black frame which would match what I see on desktop.
Yes it was a debug Chrome Android build. Sorry for omitting that from the repro steps. 
Are you still seeing this bug on the latest canary builds? We've been doing a lot of work on surface references and this bug might just be gone now.
Im no longer seeing the error message. 
Owner: mlamouri@chromium.org
@mlamouri, mind checking if this still exists on desktop?
Status: WontFix (was: Started)
I can't see any console error nor pink flash on the desktop repro too. Closing this.

Sign in to add a comment