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
dd7234c5
Commit
dd7234c5
authored
Oct 16, 2013
by
Geoff Lang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove un-referenced functions.
TRAC #23785 Signed-off-by: Jamie Madill Signed-off-by: Shannon Woods
parent
eef52cc6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
70 deletions
+0
-70
utilities.cpp
src/common/utilities.cpp
+0
-70
No files found.
src/common/utilities.cpp
View file @
dd7234c5
...
@@ -386,76 +386,6 @@ int AllocateFirstFreeBits(unsigned int *bits, unsigned int allocationSize, unsig
...
@@ -386,76 +386,6 @@ int AllocateFirstFreeBits(unsigned int *bits, unsigned int allocationSize, unsig
return
-
1
;
return
-
1
;
}
}
bool
IsStencilTexture
(
GLenum
format
)
{
if
(
format
==
GL_DEPTH_STENCIL_OES
||
format
==
GL_DEPTH24_STENCIL8_OES
)
{
return
true
;
}
return
false
;
}
void
MakeValidSize
(
bool
isImage
,
bool
isCompressed
,
GLsizei
*
requestWidth
,
GLsizei
*
requestHeight
,
int
*
levelOffset
)
{
int
upsampleCount
=
0
;
if
(
isCompressed
)
{
// Don't expand the size of full textures that are at least 4x4
// already.
if
(
isImage
||
*
requestWidth
<
4
||
*
requestHeight
<
4
)
{
while
(
*
requestWidth
%
4
!=
0
||
*
requestHeight
%
4
!=
0
)
{
*
requestWidth
<<=
1
;
*
requestHeight
<<=
1
;
upsampleCount
++
;
}
}
}
*
levelOffset
=
upsampleCount
;
}
// Returns the size, in bytes, of a single texel in an Image
int
ComputePixelSize
(
GLint
internalformat
)
{
switch
(
internalformat
)
{
case
GL_ALPHA8_EXT
:
return
sizeof
(
unsigned
char
);
case
GL_LUMINANCE8_EXT
:
return
sizeof
(
unsigned
char
);
case
GL_ALPHA32F_EXT
:
return
sizeof
(
float
);
case
GL_LUMINANCE32F_EXT
:
return
sizeof
(
float
);
case
GL_ALPHA16F_EXT
:
return
sizeof
(
unsigned
short
);
case
GL_LUMINANCE16F_EXT
:
return
sizeof
(
unsigned
short
);
case
GL_LUMINANCE8_ALPHA8_EXT
:
return
sizeof
(
unsigned
char
)
*
2
;
case
GL_LUMINANCE_ALPHA32F_EXT
:
return
sizeof
(
float
)
*
2
;
case
GL_LUMINANCE_ALPHA16F_EXT
:
return
sizeof
(
unsigned
short
)
*
2
;
case
GL_RGB8_OES
:
return
sizeof
(
unsigned
char
)
*
3
;
case
GL_RGB565
:
return
sizeof
(
unsigned
short
);
case
GL_RGB32F_EXT
:
return
sizeof
(
float
)
*
3
;
case
GL_RGB16F_EXT
:
return
sizeof
(
unsigned
short
)
*
3
;
case
GL_RGBA8_OES
:
return
sizeof
(
unsigned
char
)
*
4
;
case
GL_RGBA4
:
return
sizeof
(
unsigned
short
);
case
GL_RGB5_A1
:
return
sizeof
(
unsigned
short
);
case
GL_RGBA32F_EXT
:
return
sizeof
(
float
)
*
4
;
case
GL_RGBA16F_EXT
:
return
sizeof
(
unsigned
short
)
*
4
;
case
GL_BGRA8_EXT
:
return
sizeof
(
unsigned
char
)
*
4
;
case
GL_SRGB8_ALPHA8
:
return
sizeof
(
unsigned
char
)
*
4
;
case
GL_RGB10_A2
:
return
sizeof
(
unsigned
char
)
*
4
;
case
GL_RG8
:
return
sizeof
(
unsigned
char
)
*
2
;
case
GL_R8
:
return
sizeof
(
unsigned
char
);
case
GL_BGRA4_ANGLEX
:
return
sizeof
(
unsigned
short
);
case
GL_BGR5_A1_ANGLEX
:
return
sizeof
(
unsigned
short
);
default
:
UNIMPLEMENTED
();
// TODO: Remaining ES3 formats
UNREACHABLE
();
}
return
0
;
}
bool
IsCubemapTextureTarget
(
GLenum
target
)
bool
IsCubemapTextureTarget
(
GLenum
target
)
{
{
return
(
target
>=
GL_TEXTURE_CUBE_MAP_POSITIVE_X
&&
target
<=
GL_TEXTURE_CUBE_MAP_NEGATIVE_Z
);
return
(
target
>=
GL_TEXTURE_CUBE_MAP_POSITIVE_X
&&
target
<=
GL_TEXTURE_CUBE_MAP_NEGATIVE_Z
);
...
...
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