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
1a4bbc4a
Commit
1a4bbc4a
authored
Oct 16, 2017
by
John Kessenich
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
HLSL: More clip fix: It is more involved than previous commit. Complete.
parent
4ce5b562
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
4 deletions
+11
-4
hlsl.intrinsics.frag.out
Test/baseResults/hlsl.intrinsics.frag.out
+2
-2
hlslParseHelper.cpp
hlsl/hlslParseHelper.cpp
+9
-2
No files found.
Test/baseResults/hlsl.intrinsics.frag.out
View file @
1a4bbc4a
...
...
@@ -88,7 +88,7 @@ gl_FragCoord origin is upper left
0:34 Compare Less Than ( temp bool)
0:34 'r005' ( temp int)
0:34 Constant:
0:34 0
.000000
0:34 0
(const int)
0:34 true case
0:34 Branch: Kill
0:35 Sequence
...
...
@@ -2906,7 +2906,7 @@ gl_FragCoord origin is upper left
0:34 Compare Less Than ( temp bool)
0:34 'r005' ( temp int)
0:34 Constant:
0:34 0
.000000
0:34 0
(const int)
0:34 true case
0:34 Branch: Kill
0:35 Sequence
...
...
hlsl/hlslParseHelper.cpp
View file @
1a4bbc4a
...
...
@@ -4503,14 +4503,21 @@ void HlslParseContext::decomposeIntrinsic(const TSourceLoc& loc, TIntermTyped*&
std
::
max
(
arg0
->
getType
().
getMatrixRows
(),
1
);
TConstUnion
zero
;
zero
.
setDConst
(
0.0
);
if
(
arg0
->
getType
().
isIntegerDomain
())
zero
.
setDConst
(
0
);
else
zero
.
setDConst
(
0.0
);
TConstUnionArray
zeros
(
constComponentCount
,
zero
);
less
->
getSequence
().
push_back
(
intermediate
.
addConstantUnion
(
zeros
,
arg0
->
getType
(),
loc
,
true
));
compareNode
=
intermediate
.
addBuiltInFunctionCall
(
loc
,
EOpAny
,
true
,
less
,
TType
(
EbtBool
));
}
else
{
TIntermTyped
*
zero
=
intermediate
.
addConstantUnion
(
0
,
type0
,
loc
,
true
);
TIntermTyped
*
zero
;
if
(
arg0
->
getType
().
isIntegerDomain
())
zero
=
intermediate
.
addConstantUnion
(
0
,
loc
,
true
);
else
zero
=
intermediate
.
addConstantUnion
(
0.0
,
type0
,
loc
,
true
);
compareNode
=
handleBinaryMath
(
loc
,
"clip"
,
EOpLessThan
,
arg0
,
zero
);
}
...
...
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