Confirmed users
753
edits
No edit summary |
|||
Line 73: | Line 73: | ||
We mentioned that in the Android world, android::GraphicBuffer provided two key features: serialization, and locking. As we mentioned, in our world, serialization is done by GrallocBufferActor and wrapped by SurfaceDescriptor in cross-platform code. If we walk one level of abstraction up, we're now going to see where we take care of locking. | We mentioned that in the Android world, android::GraphicBuffer provided two key features: serialization, and locking. As we mentioned, in our world, serialization is done by GrallocBufferActor and wrapped by SurfaceDescriptor in cross-platform code. If we walk one level of abstraction up, we're now going to see where we take care of locking. | ||
Locking is currently taken care of by a pair of classes, TextureClient and TextureHost. The producer sees the surface as a TextureClient, and the consumer receives it as a TextureHost | Locking is currently taken care of by a pair of classes, TextureClient and TextureHost. The producer sees the surface as a TextureClient, and the consumer receives it as a TextureHost. | ||
For example, here is the diagram for the B2G case: | For example, here is the diagram for the B2G case: | ||
*** Figure 2: TextureClient/TextureHost, our current best approximation *** | |||
*** of a sane surface concept *** | |||
paired / IPC | paired / IPC | ||
TextureClient ================== TextureHost | TextureClient ================== TextureHost | ||
| | | | | ||
implemented | implemented | | implemented | implemented | | ||
by V by V | by V by V | ||
GrallocTextureClientOGL GrallocTextureHostOGL | GrallocTextureClientOGL GrallocTextureHostOGL | ||
| | | | | ||
wraps | wraps | | wraps | wraps | | ||
V | V V | ||
paired / IPC | paired / IPC | ||
GrallocBufferActor ============== GrallocBufferActor | GrallocBufferActor ============== GrallocBufferActor | ||