Are there any transformation/conversation if I allocate texture from OpenGL application user space to some GPU internal format?
And is it possible to disable this transformation?
16 or 24 or 32bit texture
Are there any disadvantages ?
For example if I allocate with
some application memory block to OpenGL API ,
some application memory block to EGL API,
DMBBUF to EGL,
UMP to EGL ?
Anything allocated via OpenGL ES (i.e. textures, framebuffer objects) will use internal memory layout. Anything which can be memory mapped, or shared across processes (pixmaps, EGL external images) tends to be in a standard format as the recipient of that data isn't always the Mali hardware.
No.
Pretty much everything that is a texture or a renderbuffer.
The main transform applied is a texture address swizzle, via a space filling curve algorithm.
Space-filling curve - Wikipedia, the free encyclopedia
This technique is very common across GPU vendors (although the precise curve pattern used varies) as it provides much better cache locality (it effectively provides 2D texture coordinate locality in a 1D address space), and is much less sensitive to the orientation of primitives relative to the rendering sequence or display. Less cache misses = lower power and faster performance.
The downside is a slightly more complex upload path - you can't just memcpy from the source texture into the memory - but the upload paths are generally heavily optimized in the drivers so the performance drop is normally negligible.
DMBBUF to EGL, UMP to EGL ?
DMABUF and UMP are only really used for allocation of window surfaces, and as such fall into the platform level format negotiation (i.e. we have to support whatever the display controller and display technology requires). This is normally linear memory, although there are various platform specific issues here (do your rows increment or decrement in address, and that type of thing).
HTH, Pete
I am curios for situation, when we use DMABUF/UMP for video decoder OUTPUT (big changing textures 60fps)
As DMA and UMP buffers are already in kernel space, but I still want to use shaders on this buffers(textures)
And all at 60fps ?
Do you have some spacial case for this kind of textures ?
EGL external images can be mapped directly on into the GPU memory view, so it's all zero copy, although format negotiation is implementation-specific for video surfaces (as they are commonly YUV and so not really a native OpenGL ES texture type).