Bug 1962966 - Add offset handling to eglCreatePbufferFromClientBuffer() r=gfx-reviewers,lsalzman
Add the following attributes handling - EGL_TEXTURE_OFFSET_X_ANGLE - EGL_TEXTURE_OFFSET_Y_ANGLE Differential Revision: https://phabricator.services.mozilla.com/D247213
This commit is contained in:
@@ -6610,6 +6610,8 @@
|
||||
#define LOCAL_EGL_YUV_SUBSAMPLE_EXT 0x3312
|
||||
#define LOCAL_EGL_Y_AXIS_NV 0x3370
|
||||
#define LOCAL_EGL_Y_INVERTED_NOK 0x307F
|
||||
#define LOCAL_EGL_TEXTURE_OFFSET_X_ANGLE 0x3490
|
||||
#define LOCAL_EGL_TEXTURE_OFFSET_Y_ANGLE 0x3491
|
||||
|
||||
// GLX
|
||||
#define LOCAL_GLX_3DFX_FULLSCREEN_MODE_MESA 0x2
|
||||
|
||||
@@ -1650,8 +1650,15 @@ void DCLayerCompositionSurface::Bind() {
|
||||
const auto& gle = gl::GLContextEGL::Cast(gl);
|
||||
const auto& egl = gle->mEgl;
|
||||
|
||||
const EGLint pbuffer_attribs[]{LOCAL_EGL_WIDTH, mSize.width, LOCAL_EGL_HEIGHT,
|
||||
mSize.height, LOCAL_EGL_NONE};
|
||||
const EGLint pbuffer_attribs[]{LOCAL_EGL_WIDTH,
|
||||
mSize.width,
|
||||
LOCAL_EGL_HEIGHT,
|
||||
mSize.height,
|
||||
LOCAL_EGL_TEXTURE_OFFSET_X_ANGLE,
|
||||
offset.x,
|
||||
LOCAL_EGL_TEXTURE_OFFSET_Y_ANGLE,
|
||||
offset.y,
|
||||
LOCAL_EGL_NONE};
|
||||
const auto buffer = reinterpret_cast<EGLClientBuffer>(backBuffer.get());
|
||||
EGLConfig eglConfig = mDCLayerTree->GetEGLConfig();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user