Loading...
Searching...
No Matches
BayerExternalOES.hpp File Reference

Demosaic a colour-filter-array frame sampled through GL_TEXTURE_EXTERNAL_OES. More...

Detailed Description

Demosaic a colour-filter-array frame sampled through GL_TEXTURE_EXTERNAL_OES.

Same reconstruction as BayerDecoder, over the one texture target Tegra will accept for an imported dma-buf: eglCreateImage accepts R16, R8 and ABGR8888, binding any of them to GL_TEXTURE_2D fails, and GL_TEXTURE_EXTERNAL_OES succeeds for all three. Without this decoder the zero-copy rung has no consumer and capture falls back to staging whole frames out of uncached pages.

Two constraints separate this from BayerDecoder, and both are the external sampler's:

  • texelFetch does not exist for samplerExternalOES, so the neighbourhood is gathered by normalised coordinate. mat.texSz supplies the geometry the integer form would have read from textureSize.
  • the sample arrives in .r: an R16 external image reads back (v, 0, 0, 1), so the mosaic value is the red channel and nothing else is populated.

NEAREST filtering is mandatory rather than preferred: LINEAR blends adjacent colour sites before the demosaic can separate them.

Go to the source code of this file.

Classes

struct  score::gfx::BayerExternalOESDecoder
 

Namespaces

namespace  score
 Base toolkit upon which the software is built.
 
namespace  score::gfx
 Graphics rendering pipeline for ossia score.