Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
glslang
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
glslang
Commits
03a93ae1
Commit
03a93ae1
authored
Jul 28, 2019
by
Canon lee
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix Clang compiler warning.
parent
c24033af
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
iomapper.h
glslang/MachineIndependent/iomapper.h
+7
-7
No files found.
glslang/MachineIndependent/iomapper.h
View file @
03a93ae1
...
@@ -188,23 +188,23 @@ public:
...
@@ -188,23 +188,23 @@ public:
typedef
std
::
map
<
TString
,
int
>
TVarSlotMap
;
// <resourceName, location/binding>
typedef
std
::
map
<
TString
,
int
>
TVarSlotMap
;
// <resourceName, location/binding>
typedef
std
::
map
<
int
,
TVarSlotMap
>
TSlotMap
;
// <resourceKey, TVarSlotMap>
typedef
std
::
map
<
int
,
TVarSlotMap
>
TSlotMap
;
// <resourceKey, TVarSlotMap>
TDefaultGlslIoResolver
(
const
TIntermediate
&
intermediate
);
TDefaultGlslIoResolver
(
const
TIntermediate
&
intermediate
);
bool
validateBinding
(
EShLanguage
/*stage*/
,
TVarEntryInfo
&
/*ent*/
)
{
return
true
;
};
bool
validateBinding
(
EShLanguage
/*stage*/
,
TVarEntryInfo
&
/*ent*/
)
override
{
return
true
;
};
TResourceType
getResourceType
(
const
glslang
::
TType
&
type
)
override
;
TResourceType
getResourceType
(
const
glslang
::
TType
&
type
)
override
;
int
resolveInOutLocation
(
EShLanguage
stage
,
TVarEntryInfo
&
ent
)
override
;
int
resolveInOutLocation
(
EShLanguage
stage
,
TVarEntryInfo
&
ent
)
override
;
int
resolveUniformLocation
(
EShLanguage
/*stage*/
,
TVarEntryInfo
&
ent
)
override
;
int
resolveUniformLocation
(
EShLanguage
/*stage*/
,
TVarEntryInfo
&
ent
)
override
;
int
resolveBinding
(
EShLanguage
/*stage*/
,
TVarEntryInfo
&
ent
);
int
resolveBinding
(
EShLanguage
/*stage*/
,
TVarEntryInfo
&
ent
)
override
;
void
beginResolve
(
EShLanguage
/*stage*/
);
void
beginResolve
(
EShLanguage
/*stage*/
)
override
;
void
endResolve
(
EShLanguage
stage
);
void
endResolve
(
EShLanguage
stage
)
override
;
void
beginCollect
(
EShLanguage
)
override
;
void
beginCollect
(
EShLanguage
)
override
;
void
endCollect
(
EShLanguage
)
override
;
void
endCollect
(
EShLanguage
)
override
;
void
reserverStorageSlot
(
TVarEntryInfo
&
ent
,
TInfoSink
&
infoSink
);
void
reserverStorageSlot
(
TVarEntryInfo
&
ent
,
TInfoSink
&
infoSink
)
override
;
void
reserverResourceSlot
(
TVarEntryInfo
&
ent
,
TInfoSink
&
infoSink
);
void
reserverResourceSlot
(
TVarEntryInfo
&
ent
,
TInfoSink
&
infoSink
)
override
;
// in/out symbol and uniform symbol are stored in the same resourceSlotMap, the storage key is used to identify each type of symbol.
// in/out symbol and uniform symbol are stored in the same resourceSlotMap, the storage key is used to identify each type of symbol.
// We use stage and storage qualifier to construct a storage key. it can help us identify the same storage resource used in different stage.
// We use stage and storage qualifier to construct a storage key. it can help us identify the same storage resource used in different stage.
// if a resource is a program resource and we don't need know it usage stage, we can use same stage to build storage key.
// if a resource is a program resource and we don't need know it usage stage, we can use same stage to build storage key.
// Note: both stage and type must less then 0xffff.
// Note: both stage and type must less then 0xffff.
int
buildStorageKey
(
EShLanguage
stage
,
TStorageQualifier
type
)
{
int
buildStorageKey
(
EShLanguage
stage
,
TStorageQualifier
type
)
{
assert
(
sta
ge
<=
0xffff
&&
type
<=
0x
ffff
);
assert
(
sta
tic_cast
<
uint32_t
>
(
stage
)
<=
0x0000ffff
&&
static_cast
<
uint32_t
>
(
type
)
<=
0x0000
ffff
);
return
(
stage
<<
16
)
|
type
;
return
(
stage
<<
16
)
|
type
;
};
};
...
...
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