Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
vkd3d
Manage
Activity
Members
Labels
Plan
Wiki
Bugzilla
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
wine
vkd3d
Commits
a064009d
Commit
a064009d
authored
1 year ago
by
Nikolay Sivov
Committed by
Alexandre Julliard
1 year ago
Browse files
Options
Downloads
Patches
Plain Diff
tests: Simplify conditional test.
parent
be4a71da
Branches
Branches containing commit
Tags
Tags containing commit
1 merge request
!201
vkd3d-shader/hlsl: Convert ternary operator true/false values to a common type.
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tests/conditional.shader_test
+7
-10
7 additions, 10 deletions
tests/conditional.shader_test
with
7 additions
and
10 deletions
tests/conditional.shader_test
+
7
−
10
View file @
a064009d
[vertex shader]
void main(out float tex : texcoord, inout float4 pos : sv_position)
{
tex = pos.x;
}
[pixel shader]
float4 main(
float tex : texcoord) : SV_TARGET
float4 main(
uniform float4 u) : sv_target
{
if (
te
x > 0.0)
if (
u.
x > 0.0)
return float4(0.1, 0.2, 0.3, 0.4);
else
return float4(0.9, 0.8, 0.7, 0.6);
}
[test]
uniform 0 float4 0.0 0.0 0.0 0.0
draw quad
probe all rgba (0.9, 0.8, 0.7, 0.6)
uniform 0 float4 0.1 0.0 0.0 0.0
draw quad
probe ( 0, 0, 319, 480) rgba (0.9, 0.8, 0.7, 0.6)
probe (321, 0, 640, 480) rgba (0.1, 0.2, 0.3, 0.4)
probe all rgba (0.1, 0.2, 0.3, 0.4)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment