Skip to content

Commit

Permalink
Set GL_UNPACK_ALIGNMENT
Browse files Browse the repository at this point in the history
  • Loading branch information
littleGnAl committed Jun 5, 2024
1 parent 0a561dc commit 3a80970
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions android/src/main/cpp/iris_rtc_rendering_android.cc
Original file line number Diff line number Diff line change
Expand Up @@ -117,9 +117,6 @@ class GLContext {
== EGL_TRUE;
if (!result) { CHECK_GL_ERROR() }

glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
CHECK_GL_ERROR()

return result;
}

Expand Down Expand Up @@ -538,6 +535,10 @@ class YUVRendering final : public RenderingOp {
glViewport(0, 0, width, height);
CHECK_GL_ERROR()

// Ensure that the unpack alignment is set to 1 byte to avoid any alignment issues with YUV data.
glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
CHECK_GL_ERROR()

glEnableVertexAttribArray(aPositionLoc_);
CHECK_GL_ERROR()

Expand Down

0 comments on commit 3a80970

Please sign in to comment.