Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
angle
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
angle
Commits
ba4f10a3
Commit
ba4f10a3
authored
Oct 10, 2013
by
Jamie Madill
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Support pixel unpack buffers in TexSubImage3D.
TRAC #23847 Signed-off-by: Geoff Lang Signed-off-by: Shannon Woods
parent
53683053
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
6 deletions
+18
-6
Texture.cpp
src/libGLESv2/Texture.cpp
+18
-1
libGLESv2.cpp
src/libGLESv2/libGLESv2.cpp
+0
-5
No files found.
src/libGLESv2/Texture.cpp
View file @
ba4f10a3
...
...
@@ -1757,7 +1757,24 @@ void Texture3D::setCompressedImage(GLint level, GLenum format, GLsizei width, GL
void
Texture3D
::
subImage
(
GLint
level
,
GLint
xoffset
,
GLint
yoffset
,
GLint
zoffset
,
GLsizei
width
,
GLsizei
height
,
GLsizei
depth
,
GLenum
format
,
GLenum
type
,
const
PixelUnpackState
&
unpack
,
const
void
*
pixels
)
{
if
(
Texture
::
subImage
(
xoffset
,
yoffset
,
zoffset
,
width
,
height
,
depth
,
format
,
type
,
unpack
,
pixels
,
mImageArray
[
level
]))
bool
fastUnpacked
=
false
;
// Attempt a fast gpu copy of the pixel data to the surface if the app bound an unpack buffer
if
(
isFastUnpackable
(
unpack
,
getInternalFormat
(
level
)))
{
rx
::
RenderTarget
*
destRenderTarget
=
getRenderTarget
(
level
);
Box
destArea
(
xoffset
,
yoffset
,
zoffset
,
width
,
height
,
depth
);
if
(
destRenderTarget
&&
fastUnpackPixels
(
unpack
,
pixels
,
destArea
,
getInternalFormat
(
level
),
type
,
destRenderTarget
))
{
// Ensure we don't overwrite our newly initialized data
mImageArray
[
level
]
->
markClean
();
fastUnpacked
=
true
;
}
}
if
(
!
fastUnpacked
&&
Texture
::
subImage
(
xoffset
,
yoffset
,
zoffset
,
width
,
height
,
depth
,
format
,
type
,
unpack
,
pixels
,
mImageArray
[
level
]))
{
commitRect
(
level
,
xoffset
,
yoffset
,
zoffset
,
width
,
height
,
depth
);
}
...
...
src/libGLESv2/libGLESv2.cpp
View file @
ba4f10a3
...
...
@@ -6386,11 +6386,6 @@ void __stdcall glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint
return
gl
::
error
(
GL_INVALID_OPERATION
);
}
if
(
!
pixels
)
{
return
gl
::
error
(
GL_INVALID_VALUE
);
}
// validateES3TexImageFormat sets the error code if there is an error
if
(
!
ValidateES3TexImageParameters
(
context
,
target
,
level
,
GL_NONE
,
false
,
true
,
xoffset
,
yoffset
,
zoffset
,
width
,
height
,
depth
,
0
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment