Open Bug 941389 (BadSurfaceDescriptor) Opened 11 years ago Updated 2 years ago

Replace all bad uses of SurfaceDescriptor by TextureClient (evolving TextureClient as needed)

Categories

(Core :: Graphics, defect)

defect

Tracking

()

People

(Reporter: bjacob, Unassigned)

References

(Depends on 1 open bug, Blocks 1 open bug)

Details

Here is a command line to list files currently containing "SurfaceDecriptor" with number of affected lines for each file.

$ find . -type f | grep -v \\.hg  | grep -v \\./obj | grep -v \~$ | grep -v orig$ | grep -v rej$ | xargs grep SurfaceDescriptor | cut -d ':' -f 1 | sort | uniq -c | tee SurfaceDescriptorFiles 
      5 ./content/media/omx/OmxDecoder.cpp
      1 ./content/media/omx/OmxDecoder.h
     12 ./dom/plugins/ipc/PluginInstanceChild.cpp
      1 ./dom/plugins/ipc/PluginInstanceChild.h
     13 ./dom/plugins/ipc/PluginInstanceParent.cpp
      3 ./dom/plugins/ipc/PluginInstanceParent.h
      1 ./dom/plugins/ipc/PluginMessageUtils.h
     10 ./dom/plugins/ipc/PPluginInstance.ipdl
      6 ./gfx/gl/SharedSurfaceGralloc.cpp
      5 ./gfx/gl/SharedSurfaceGralloc.h
      6 ./gfx/layers/basic/AutoMaskData.h
     10 ./gfx/layers/basic/BasicCompositor.cpp
      2 ./gfx/layers/basic/BasicImageLayer.cpp
      2 ./gfx/layers/basic/BasicImplData.h
      3 ./gfx/layers/basic/BasicLayersImpl.cpp
      2 ./gfx/layers/client/CanvasClient.cpp
      3 ./gfx/layers/client/CanvasClient.h
      4 ./gfx/layers/client/ClientLayerManager.cpp
      2 ./gfx/layers/client/CompositableClient.h
     22 ./gfx/layers/client/ContentClient.cpp
      7 ./gfx/layers/client/ContentClient.h
     12 ./gfx/layers/client/ImageClient.cpp
      2 ./gfx/layers/client/ImageClient.h
     30 ./gfx/layers/client/TextureClient.cpp
     22 ./gfx/layers/client/TextureClient.h
      5 ./gfx/layers/client/TiledContentClient.cpp
      2 ./gfx/layers/client/TiledContentClient.h
      3 ./gfx/layers/composite/CompositableHost.cpp
      6 ./gfx/layers/composite/CompositableHost.h
     19 ./gfx/layers/composite/ContentHost.cpp
      9 ./gfx/layers/composite/ContentHost.h
      6 ./gfx/layers/composite/ImageHost.cpp
      8 ./gfx/layers/composite/ImageHost.h
      1 ./gfx/layers/composite/LayerManagerComposite.cpp
      3 ./gfx/layers/composite/LayerManagerComposite.h
     18 ./gfx/layers/composite/TextureHost.cpp
     25 ./gfx/layers/composite/TextureHost.h
      2 ./gfx/layers/composite/TiledContentHost.cpp
      3 ./gfx/layers/composite/TiledContentHost.h
      5 ./gfx/layers/CompositorTypes.h
     19 ./gfx/layers/d3d11/TextureD3D11.cpp
      4 ./gfx/layers/d3d11/TextureD3D11.h
     33 ./gfx/layers/d3d9/TextureD3D9.cpp
     15 ./gfx/layers/d3d9/TextureD3D9.h
      8 ./gfx/layers/GrallocImages.cpp
     11 ./gfx/layers/GrallocImages.h
      1 ./gfx/layers/ImageContainer.h
      2 ./gfx/layers/ipc/AutoOpenSurface.h
     15 ./gfx/layers/ipc/CompositableForwarder.h
      6 ./gfx/layers/ipc/CompositableTransactionParent.cpp
      4 ./gfx/layers/ipc/CompositorParent.cpp
      2 ./gfx/layers/ipc/CompositorParent.h
     34 ./gfx/layers/ipc/ImageBridgeChild.cpp
     22 ./gfx/layers/ipc/ImageBridgeChild.h
     27 ./gfx/layers/ipc/ISurfaceAllocator.cpp
     13 ./gfx/layers/ipc/ISurfaceAllocator.h
      6 ./gfx/layers/ipc/LayersMessages.ipdlh
     20 ./gfx/layers/ipc/LayersSurfaces.ipdlh
      2 ./gfx/layers/ipc/PCompositor.ipdl
      1 ./gfx/layers/ipc/PLayerTransaction.ipdl
     63 ./gfx/layers/ipc/ShadowLayers.cpp
     25 ./gfx/layers/ipc/ShadowLayers.h
     12 ./gfx/layers/ipc/ShadowLayerUtilsD3D10.cpp
      3 ./gfx/layers/ipc/ShadowLayerUtilsD3D10.h
     32 ./gfx/layers/ipc/ShadowLayerUtilsGralloc.cpp
      2 ./gfx/layers/ipc/ShadowLayerUtilsGralloc.h
      4 ./gfx/layers/ipc/ShadowLayerUtils.h
     12 ./gfx/layers/ipc/ShadowLayerUtilsMac.cpp
     22 ./gfx/layers/ipc/ShadowLayerUtilsX11.cpp
      8 ./gfx/layers/ipc/ShadowLayerUtilsX11.h
      7 ./gfx/layers/ipc/SharedPlanarYCbCrImage.cpp
      5 ./gfx/layers/ipc/SharedPlanarYCbCrImage.h
      7 ./gfx/layers/ipc/SharedRGBImage.cpp
      5 ./gfx/layers/ipc/SharedRGBImage.h
      1 ./gfx/layers/Layers.h
      6 ./gfx/layers/opengl/GrallocTextureClient.cpp
      2 ./gfx/layers/opengl/GrallocTextureClient.h
      1 ./gfx/layers/opengl/GrallocTextureHost.cpp
      1 ./gfx/layers/opengl/GrallocTextureHost.h
      2 ./gfx/layers/opengl/MacIOSurfaceTextureClientOGL.cpp
      1 ./gfx/layers/opengl/MacIOSurfaceTextureClientOGL.h
      1 ./gfx/layers/opengl/MacIOSurfaceTextureHostOGL.cpp
      1 ./gfx/layers/opengl/MacIOSurfaceTextureHostOGL.h
      4 ./gfx/layers/opengl/TextureClientOGL.cpp
      3 ./gfx/layers/opengl/TextureClientOGL.h
     36 ./gfx/layers/opengl/TextureHostOGL.cpp
     11 ./gfx/layers/opengl/TextureHostOGL.h
      2 ./gfx/layers/TiledLayerBuffer.h
      6 ./gfx/tests/gtest/TestTextures.cpp
      1 ./ipc/glue/Shmem.h
      2 ./media/webrtc/signaling/src/mediapipeline/MediaPipeline.cpp
     26 ./widget/gonk/nativewindow/GonkBufferQueue.cpp
     10 ./widget/gonk/nativewindow/GonkBufferQueue.h
     26 ./widget/gonk/nativewindow/GonkNativeWindowICS.cpp
      9 ./widget/gonk/nativewindow/GonkNativeWindowICS.h
      4 ./widget/gonk/nativewindow/GonkNativeWindowJB.cpp
      5 ./widget/gonk/nativewindow/GonkNativeWindowJB.h
Summary: Replace all bad uses of SurfaceDescriptor by TextureClient (and evolve TextureClient to make up to the task) → Replace all bad uses of SurfaceDescriptor by TextureClient (and evolve TextureClient accordingly)
Blocks: Surfaces
Depends on: 941400
No longer blocks: KillSharedSurface
Summary: Replace all bad uses of SurfaceDescriptor by TextureClient (and evolve TextureClient accordingly) → Replace all bad uses of SurfaceDescriptor by TextureClient (evolving TextureClient as needed)
Depends on: 941411
Depends on: 941413
No longer depends on: 941411
Depends on: 941902
If we want to replace the SurfaceDescriptor by TextureClient. We have to re-think about a life cycle of TextureClient. In media area, TextureClient is used as one time only use. Every video frame rendering, new TextureClient is created and then deleted when next video frame rendering.

If we want to replace the SurfaceDescriptor by TextureClient, we need to extend the lifetime of Texture client as same to gralloc buffer. This affect a lot around media framework and camera. I think we should not progress Bug 941413, Bug 941902 and Bug 951870 until we make clear the over all change.
Comment 1 is already discussed in Paris work week. And today I explain about an overview to pchang.
If Comment 1 is implemented correctly Bug 941902 is not necessary.
Depends on: 952540
Depends on: 985772
No longer depends on: 985772
Depends on: 985772
Depends on: 990309
Depends on: 990310
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.