I have a few questions regarding integration of an accelerated capability into Android. I understand that Android must draw to surfaces in Software. In our environment we can create a buffer that can be drawn to both by Hardware and software, but it is one of our components that must allocate the memory in order to do this. I've been looking at some various components in SurfaceFlinger that may be of help (or possibly red-herrings) and have a few questions: - Do *all* surfaces which can be drawn to instances of one particular class and if so which one? (I'd like to hook in our own memory surface class at this point rather than a raw memory allocation). Is there a single point for which this allocation is done? - Does a layer have a 1:1 correspondence with a drawable Surface? Or are multiple Surfaces placed into a Layer? - Presumably multiple layers are just composited to the final buffer in their Z order? - What's the GPUHardware class for? - is it there just for chip access arbitration or debugging (It looked for example like the allocator was only used if the debug.egl.hw property were set). Is this needed if arbitration is handled through EGL/GL? - Is it true that for surfaces only one allocator will be used either GPU, /dev/pmem or heap in that order? Under what circumstances is /dev/pmem needed? - Is the 8Mb SurfaceFlinger allocation per process or a one-off for the system? - Presumably there is only one compositor (running in a system thread)? When a surface is allocated is it done through the applications thread or the thread that looks after the composition? (Is there an accompanying call somewhere to map memory from one process into another?) - When the compositor is refreshing the display what mechanisms is it using to access buffers that are in a different address space? - On the off-chance is there any porting documentation related to surface flinger and how it works?
Many Thanks. --~--~---------~--~----~------------~-------~--~----~ unsubscribe: [email protected] website: http://groups.google.com/group/android-porting -~----------~----~----~----~------~----~------~--~---
