Commit 331581e9 by Shahbaz Youssefi Committed by Commit Bot

Make copy*Texture parameters consistent for level indices

They were passed as size_t, while GL level indices are GLint throughout ANGLE. Bug: angleproject:4880 Change-Id: I43bc9f01a607e457b55a061f473450d3360db808 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2380230 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: 's avatarJonah Ryan-Davis <jonahr@google.com>
parent fbafb46c
......@@ -20,7 +20,7 @@ angle::Result TextureImpl::copyTexture(const gl::Context *context,
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -33,7 +33,7 @@ angle::Result TextureImpl::copyTexture(const gl::Context *context,
angle::Result TextureImpl::copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -55,8 +55,8 @@ angle::Result TextureImpl::copy3DTexture(const gl::Context *context,
gl::TextureTarget target,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
size_t destLevel,
GLint sourceLevel,
GLint destLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -69,8 +69,8 @@ angle::Result TextureImpl::copy3DTexture(const gl::Context *context,
angle::Result TextureImpl::copy3DSubTexture(const gl::Context *context,
const gl::TextureTarget target,
const gl::Offset &destOffset,
size_t sourceLevel,
size_t destLevel,
GLint sourceLevel,
GLint destLevel,
const gl::Box &srcBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......
......@@ -97,7 +97,7 @@ class TextureImpl : public FramebufferAttachmentObjectImpl
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -105,7 +105,7 @@ class TextureImpl : public FramebufferAttachmentObjectImpl
virtual angle::Result copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -119,8 +119,8 @@ class TextureImpl : public FramebufferAttachmentObjectImpl
gl::TextureTarget target,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
size_t destLevel,
GLint sourceLevel,
GLint destLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -128,8 +128,8 @@ class TextureImpl : public FramebufferAttachmentObjectImpl
virtual angle::Result copy3DSubTexture(const gl::Context *context,
const gl::TextureTarget target,
const gl::Offset &destOffset,
size_t sourceLevel,
size_t destLevel,
GLint sourceLevel,
GLint destLevel,
const gl::Box &srcBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......
......@@ -73,7 +73,7 @@ class MockTextureImpl : public TextureImpl
const gl::ImageIndex &,
GLenum,
GLenum,
size_t,
GLint,
bool,
bool,
bool,
......@@ -82,7 +82,7 @@ class MockTextureImpl : public TextureImpl
angle::Result(const gl::Context *,
const gl::ImageIndex &,
const gl::Offset &,
size_t,
GLint,
const gl::Box &,
bool,
bool,
......
......@@ -1137,7 +1137,7 @@ angle::Result TextureD3D_2D::copyTexture(const gl::Context *context,
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -1164,15 +1164,15 @@ angle::Result TextureD3D_2D::copyTexture(const gl::Context *context,
ASSERT(isValidLevel(index.getLevelIndex()));
ANGLE_TRY(updateStorageLevel(context, index.getLevelIndex()));
ANGLE_TRY(mRenderer->copyTexture(
context, source, static_cast<GLint>(sourceLevel), gl::TextureTarget::_2D, sourceBox,
internalFormatInfo.format, internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY, unpackPremultiplyAlpha,
unpackUnmultiplyAlpha));
ANGLE_TRY(mRenderer->copyTexture(context, source, sourceLevel, gl::TextureTarget::_2D,
sourceBox, internalFormatInfo.format,
internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY,
unpackPremultiplyAlpha, unpackUnmultiplyAlpha));
}
else
{
gl::ImageIndex sourceImageIndex = gl::ImageIndex::Make2D(static_cast<GLint>(sourceLevel));
gl::ImageIndex sourceImageIndex = gl::ImageIndex::Make2D(sourceLevel);
TextureD3D *sourceD3D = GetImplAs<TextureD3D>(source);
ImageD3D *sourceImage = nullptr;
ANGLE_TRY(sourceD3D->getImageAndSyncFromStorage(context, sourceImageIndex, &sourceImage));
......@@ -1195,7 +1195,7 @@ angle::Result TextureD3D_2D::copyTexture(const gl::Context *context,
angle::Result TextureD3D_2D::copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -1212,15 +1212,15 @@ angle::Result TextureD3D_2D::copySubTexture(const gl::Context *context,
const gl::InternalFormat &internalFormatInfo =
gl::GetSizedInternalFormatInfo(getInternalFormat(index.getLevelIndex()));
ANGLE_TRY(mRenderer->copyTexture(
context, source, static_cast<GLint>(sourceLevel), gl::TextureTarget::_2D, sourceBox,
internalFormatInfo.format, internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY, unpackPremultiplyAlpha,
unpackUnmultiplyAlpha));
ANGLE_TRY(mRenderer->copyTexture(context, source, sourceLevel, gl::TextureTarget::_2D,
sourceBox, internalFormatInfo.format,
internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY,
unpackPremultiplyAlpha, unpackUnmultiplyAlpha));
}
else
{
gl::ImageIndex sourceImageIndex = gl::ImageIndex::Make2D(static_cast<GLint>(sourceLevel));
gl::ImageIndex sourceImageIndex = gl::ImageIndex::Make2D(sourceLevel);
TextureD3D *sourceD3D = GetImplAs<TextureD3D>(source);
ImageD3D *sourceImage = nullptr;
ANGLE_TRY(sourceD3D->getImageAndSyncFromStorage(context, sourceImageIndex, &sourceImage));
......@@ -1887,7 +1887,7 @@ angle::Result TextureD3D_Cube::copyTexture(const gl::Context *context,
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -1915,15 +1915,15 @@ angle::Result TextureD3D_Cube::copyTexture(const gl::Context *context,
ASSERT(isValidFaceLevel(faceIndex, index.getLevelIndex()));
ANGLE_TRY(updateStorageFaceLevel(context, faceIndex, index.getLevelIndex()));
ANGLE_TRY(mRenderer->copyTexture(
context, source, static_cast<GLint>(sourceLevel), gl::TextureTarget::_2D, sourceBox,
internalFormatInfo.format, internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY, unpackPremultiplyAlpha,
unpackUnmultiplyAlpha));
ANGLE_TRY(mRenderer->copyTexture(context, source, sourceLevel, gl::TextureTarget::_2D,
sourceBox, internalFormatInfo.format,
internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY,
unpackPremultiplyAlpha, unpackUnmultiplyAlpha));
}
else
{
gl::ImageIndex sourceImageIndex = gl::ImageIndex::Make2D(static_cast<GLint>(sourceLevel));
gl::ImageIndex sourceImageIndex = gl::ImageIndex::Make2D(sourceLevel);
TextureD3D *sourceD3D = GetImplAs<TextureD3D>(source);
ImageD3D *sourceImage = nullptr;
ANGLE_TRY(sourceD3D->getImageAndSyncFromStorage(context, sourceImageIndex, &sourceImage));
......@@ -1946,7 +1946,7 @@ angle::Result TextureD3D_Cube::copyTexture(const gl::Context *context,
angle::Result TextureD3D_Cube::copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -1965,15 +1965,15 @@ angle::Result TextureD3D_Cube::copySubTexture(const gl::Context *context,
const gl::InternalFormat &internalFormatInfo =
gl::GetSizedInternalFormatInfo(getInternalFormat(index.getLevelIndex(), faceIndex));
ANGLE_TRY(mRenderer->copyTexture(
context, source, static_cast<GLint>(sourceLevel), gl::TextureTarget::_2D, sourceBox,
internalFormatInfo.format, internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY, unpackPremultiplyAlpha,
unpackUnmultiplyAlpha));
ANGLE_TRY(mRenderer->copyTexture(context, source, sourceLevel, gl::TextureTarget::_2D,
sourceBox, internalFormatInfo.format,
internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY,
unpackPremultiplyAlpha, unpackUnmultiplyAlpha));
}
else
{
gl::ImageIndex sourceImageIndex = gl::ImageIndex::Make2D(static_cast<GLint>(sourceLevel));
gl::ImageIndex sourceImageIndex = gl::ImageIndex::Make2D(sourceLevel);
TextureD3D *sourceD3D = GetImplAs<TextureD3D>(source);
ImageD3D *sourceImage = nullptr;
ANGLE_TRY(sourceD3D->getImageAndSyncFromStorage(context, sourceImageIndex, &sourceImage));
......@@ -2607,7 +2607,7 @@ angle::Result TextureD3D_3D::copyTexture(const gl::Context *context,
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -2636,15 +2636,15 @@ angle::Result TextureD3D_3D::copyTexture(const gl::Context *context,
ASSERT(isValidLevel(index.getLevelIndex()));
ANGLE_TRY(updateStorageLevel(context, index.getLevelIndex()));
ANGLE_TRY(mRenderer->copyTexture(
context, source, static_cast<GLint>(sourceLevel), gl::TextureTarget::_3D, sourceBox,
internalFormatInfo.format, internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY, unpackPremultiplyAlpha,
unpackUnmultiplyAlpha));
ANGLE_TRY(mRenderer->copyTexture(context, source, sourceLevel, gl::TextureTarget::_3D,
sourceBox, internalFormatInfo.format,
internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY,
unpackPremultiplyAlpha, unpackUnmultiplyAlpha));
}
else
{
gl::ImageIndex sourceIndex = gl::ImageIndex::Make3D(static_cast<GLint>(sourceLevel));
gl::ImageIndex sourceIndex = gl::ImageIndex::Make3D(sourceLevel);
ImageD3D *sourceImage = nullptr;
ImageD3D *destImage = nullptr;
TextureD3D *sourceD3D = GetImplAs<TextureD3D>(source);
......@@ -2666,7 +2666,7 @@ angle::Result TextureD3D_3D::copyTexture(const gl::Context *context,
angle::Result TextureD3D_3D::copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -2685,15 +2685,15 @@ angle::Result TextureD3D_3D::copySubTexture(const gl::Context *context,
const gl::InternalFormat &internalFormatInfo =
gl::GetSizedInternalFormatInfo(getInternalFormat(index.getLevelIndex()));
ANGLE_TRY(mRenderer->copyTexture(
context, source, static_cast<GLint>(sourceLevel), gl::TextureTarget::_3D, sourceBox,
internalFormatInfo.format, internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY, unpackPremultiplyAlpha,
unpackUnmultiplyAlpha));
ANGLE_TRY(mRenderer->copyTexture(context, source, sourceLevel, gl::TextureTarget::_3D,
sourceBox, internalFormatInfo.format,
internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY,
unpackPremultiplyAlpha, unpackUnmultiplyAlpha));
}
else
{
gl::ImageIndex sourceImageIndex = gl::ImageIndex::Make3D(static_cast<GLint>(sourceLevel));
gl::ImageIndex sourceImageIndex = gl::ImageIndex::Make3D(sourceLevel);
TextureD3D *sourceD3D = GetImplAs<TextureD3D>(source);
ImageD3D *sourceImage = nullptr;
ANGLE_TRY(sourceD3D->getImageAndSyncFromStorage(context, sourceImageIndex, &sourceImage));
......@@ -3303,7 +3303,7 @@ angle::Result TextureD3D_2DArray::copyTexture(const gl::Context *context,
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -3335,20 +3335,19 @@ angle::Result TextureD3D_2DArray::copyTexture(const gl::Context *context,
ANGLE_TRY(ensureRenderTarget(context));
ASSERT(isValidLevel(index.getLevelIndex()));
ANGLE_TRY(updateStorageLevel(context, index.getLevelIndex()));
ANGLE_TRY(mRenderer->copyTexture(
context, source, static_cast<GLint>(sourceLevel), gl::TextureTarget::_2DArray,
sourceBox, internalFormatInfo.format, internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY, unpackPremultiplyAlpha,
unpackUnmultiplyAlpha));
ANGLE_TRY(mRenderer->copyTexture(context, source, sourceLevel, gl::TextureTarget::_2DArray,
sourceBox, internalFormatInfo.format,
internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY,
unpackPremultiplyAlpha, unpackUnmultiplyAlpha));
}
else
{
for (int i = 0; i < size.depth; i++)
{
gl::ImageIndex currentSourceDepthIndex =
gl::ImageIndex::Make2DArray(static_cast<GLint>(sourceLevel), i);
gl::ImageIndex currentSourceDepthIndex = gl::ImageIndex::Make2DArray(sourceLevel, i);
gl::ImageIndex currentDestDepthIndex =
gl::ImageIndex::Make2DArray(static_cast<GLint>(index.getLevelIndex()), i);
gl::ImageIndex::Make2DArray(index.getLevelIndex(), i);
ImageD3D *sourceImage = nullptr;
ImageD3D *destImage = nullptr;
TextureD3D *sourceD3D = GetImplAs<TextureD3D>(source);
......@@ -3375,7 +3374,7 @@ angle::Result TextureD3D_2DArray::copyTexture(const gl::Context *context,
angle::Result TextureD3D_2DArray::copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -3395,20 +3394,20 @@ angle::Result TextureD3D_2DArray::copySubTexture(const gl::Context *context,
const gl::InternalFormat &internalFormatInfo =
gl::GetSizedInternalFormatInfo(getInternalFormat(destIndex.getLevelIndex()));
ANGLE_TRY(mRenderer->copyTexture(
context, source, static_cast<GLint>(sourceLevel), gl::TextureTarget::_2DArray,
sourceBox, internalFormatInfo.format, internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY, unpackPremultiplyAlpha,
unpackUnmultiplyAlpha));
ANGLE_TRY(mRenderer->copyTexture(context, source, sourceLevel, gl::TextureTarget::_2DArray,
sourceBox, internalFormatInfo.format,
internalFormatInfo.type, destOffset, mTexStorage,
index.getTarget(), index.getLevelIndex(), unpackFlipY,
unpackPremultiplyAlpha, unpackUnmultiplyAlpha));
}
else
{
for (int i = 0; i < sourceBox.depth; i++)
{
gl::ImageIndex currentSourceIndex =
gl::ImageIndex::Make2DArray(static_cast<GLint>(sourceLevel), i + sourceBox.z);
gl::ImageIndex currentDestIndex = gl::ImageIndex::Make2DArray(
static_cast<GLint>(index.getLevelIndex()), i + destOffset.z);
gl::ImageIndex::Make2DArray(sourceLevel, i + sourceBox.z);
gl::ImageIndex currentDestIndex =
gl::ImageIndex::Make2DArray(index.getLevelIndex(), i + destOffset.z);
gl::Box currentLayerBox(sourceBox.x, sourceBox.y, 0, sourceBox.width, sourceBox.height,
1);
......
......@@ -273,7 +273,7 @@ class TextureD3D_2D : public TextureD3D
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -281,7 +281,7 @@ class TextureD3D_2D : public TextureD3D
angle::Result copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -405,7 +405,7 @@ class TextureD3D_Cube : public TextureD3D
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -413,7 +413,7 @@ class TextureD3D_Cube : public TextureD3D
angle::Result copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -538,7 +538,7 @@ class TextureD3D_3D : public TextureD3D
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -546,7 +546,7 @@ class TextureD3D_3D : public TextureD3D
angle::Result copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -668,7 +668,7 @@ class TextureD3D_2DArray : public TextureD3D
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -676,7 +676,7 @@ class TextureD3D_2DArray : public TextureD3D
angle::Result copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......
......@@ -833,7 +833,7 @@ angle::Result TextureGL::copyTexture(const gl::Context *context,
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -859,7 +859,7 @@ angle::Result TextureGL::copyTexture(const gl::Context *context,
angle::Result TextureGL::copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -878,7 +878,7 @@ angle::Result TextureGL::copySubTextureHelper(const gl::Context *context,
gl::TextureTarget target,
size_t level,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Rectangle &sourceArea,
const gl::InternalFormat &destFormat,
bool unpackFlipY,
......
......@@ -115,7 +115,7 @@ class TextureGL : public TextureImpl
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -123,7 +123,7 @@ class TextureGL : public TextureImpl
angle::Result copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -133,7 +133,7 @@ class TextureGL : public TextureImpl
gl::TextureTarget target,
size_t level,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Rectangle &sourceArea,
const gl::InternalFormat &destFormat,
bool unpackFlipY,
......
......@@ -83,7 +83,7 @@ class TextureMtl : public TextureImpl
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -91,7 +91,7 @@ class TextureMtl : public TextureImpl
angle::Result copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -243,7 +243,7 @@ class TextureMtl : public TextureImpl
const gl::ImageIndex &index,
const gl::Offset &destOffset,
const gl::InternalFormat &internalFormat,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......
......@@ -845,7 +845,7 @@ angle::Result TextureMtl::copyTexture(const gl::Context *context,
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -874,7 +874,7 @@ angle::Result TextureMtl::copyTexture(const gl::Context *context,
angle::Result TextureMtl::copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -1673,7 +1673,7 @@ angle::Result TextureMtl::copySubTextureImpl(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
const gl::InternalFormat &internalFormat,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -1683,7 +1683,7 @@ angle::Result TextureMtl::copySubTextureImpl(const gl::Context *context,
// Only 2D textures are supported.
ASSERT(sourceBox.depth == 1);
ASSERT(source->getType() == gl::TextureType::_2D);
gl::ImageIndex sourceIndex = gl::ImageIndex::Make2D(static_cast<GLint>(sourceLevel));
gl::ImageIndex sourceIndex = gl::ImageIndex::Make2D(sourceLevel);
ContextMtl *contextMtl = mtl::GetImpl(context);
TextureMtl *sourceMtl = mtl::GetImpl(source);
......
......@@ -89,7 +89,7 @@ angle::Result TextureNULL::copyTexture(const gl::Context *context,
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -101,7 +101,7 @@ angle::Result TextureNULL::copyTexture(const gl::Context *context,
angle::Result TextureNULL::copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......
......@@ -69,7 +69,7 @@ class TextureNULL : public TextureImpl
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevel,
GLint sourceLevel,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -77,7 +77,7 @@ class TextureNULL : public TextureImpl
angle::Result copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevel,
GLint sourceLevel,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......
......@@ -484,7 +484,7 @@ angle::Result TextureVk::copyTexture(const gl::Context *context,
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevelGL,
GLint sourceLevelGL,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -510,7 +510,7 @@ angle::Result TextureVk::copyTexture(const gl::Context *context,
angle::Result TextureVk::copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevelGL,
GLint sourceLevelGL,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -650,7 +650,7 @@ angle::Result TextureVk::copySubTextureImpl(ContextVk *contextVk,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
const gl::InternalFormat &destFormat,
size_t sourceLevelGL,
GLint sourceLevelGL,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -783,7 +783,7 @@ angle::Result TextureVk::copySubImageImplWithTransfer(ContextVk *contextVk,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
const vk::Format &destFormat,
size_t sourceLevelGL,
GLint sourceLevelGL,
size_t sourceLayer,
const gl::Box &sourceBox,
vk::ImageHelper *srcImage)
......@@ -905,7 +905,7 @@ angle::Result TextureVk::copySubImageImplWithDraw(ContextVk *contextVk,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
const vk::Format &destFormat,
size_t sourceLevelGL,
GLint sourceLevelGL,
const gl::Box &sourceBox,
bool isSrcFlipY,
bool unpackFlipY,
......@@ -1385,7 +1385,7 @@ angle::Result TextureVk::redefineLevel(const gl::Context *context,
}
angle::Result TextureVk::copyImageDataToBufferAndGetData(ContextVk *contextVk,
size_t sourceLevelGL,
GLint sourceLevelGL,
uint32_t layerCount,
const gl::Box &sourceArea,
uint8_t **outDataPtr)
......
......@@ -85,7 +85,7 @@ class TextureVk : public TextureImpl, public angle::ObserverInterface
const gl::ImageIndex &index,
GLenum internalFormat,
GLenum type,
size_t sourceLevelGL,
GLint sourceLevelGL,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
bool unpackUnmultiplyAlpha,
......@@ -93,7 +93,7 @@ class TextureVk : public TextureImpl, public angle::ObserverInterface
angle::Result copySubTexture(const gl::Context *context,
const gl::ImageIndex &index,
const gl::Offset &destOffset,
size_t sourceLevelGL,
GLint sourceLevelGL,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -272,7 +272,7 @@ class TextureVk : public TextureImpl, public angle::ObserverInterface
const vk::Format &vkFormat);
angle::Result copyImageDataToBufferAndGetData(ContextVk *contextVk,
size_t sourceLevelGL,
GLint sourceLevelGL,
uint32_t layerCount,
const gl::Box &sourceArea,
uint8_t **outDataPtr);
......@@ -317,7 +317,7 @@ class TextureVk : public TextureImpl, public angle::ObserverInterface
const gl::ImageIndex &index,
const gl::Offset &destOffset,
const gl::InternalFormat &destFormat,
size_t sourceLevelGL,
GLint sourceLevelGL,
const gl::Box &sourceBox,
bool unpackFlipY,
bool unpackPremultiplyAlpha,
......@@ -328,7 +328,7 @@ class TextureVk : public TextureImpl, public angle::ObserverInterface
const gl::ImageIndex &index,
const gl::Offset &destOffset,
const vk::Format &destFormat,
size_t sourceLevelGL,
GLint sourceLevelGL,
size_t sourceLayer,
const gl::Box &sourceBox,
vk::ImageHelper *srcImage);
......@@ -337,7 +337,7 @@ class TextureVk : public TextureImpl, public angle::ObserverInterface
const gl::ImageIndex &index,
const gl::Offset &destOffset,
const vk::Format &destFormat,
size_t sourceLevelGL,
GLint sourceLevelGL,
const gl::Box &sourceBox,
bool isSrcFlipY,
bool unpackFlipY,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment