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
f986436a
Commit
f986436a
authored
Mar 30, 2020
by
alelenv
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Error assigns to objects of rayQueryEXT type.
parent
08c02ced
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
3 additions
and
254 deletions
+3
-254
rayQuery-decls.rgen.out
Test/baseResults/rayQuery-decls.rgen.out
+0
-200
rayQuery-decls.rgen
Test/rayQuery-decls.rgen
+0
-53
ParseContextBase.cpp
glslang/MachineIndependent/ParseContextBase.cpp
+3
-0
Spv.FromFile.cpp
gtests/Spv.FromFile.cpp
+0
-1
No files found.
Test/baseResults/rayQuery-decls.rgen.out
deleted
100644 → 0
View file @
08c02ced
This diff is collapsed.
Click to expand it.
Test/rayQuery-decls.rgen
deleted
100644 → 0
View file @
08c02ced
#version 460
#extension GL_NV_ray_tracing : enable
#extension GL_EXT_ray_query : enable
struct Ray
{
vec3 pos;
float tmin;
vec3 dir;
float tmax;
};
layout(binding = 0, set = 0) uniform accelerationStructureEXT rtas;
layout(std430, set = 0, binding = 2) buffer Rays { Ray rays[]; };
layout(shaderRecordNV) buffer block
{
uint idx;
};
uint launchIndex()
{
return gl_LaunchIDNV.z*gl_LaunchSizeNV.x*gl_LaunchSizeNV.y + gl_LaunchIDNV.y*gl_LaunchSizeNV.x + gl_LaunchIDNV.x;
}
rayQueryEXT g_rayQueryArray[4];
rayQueryEXT g_rayQueryUnused;
void main()
{
uint index = launchIndex();
Ray ray = rays[index];
rayQueryEXT rayQuery0a;
rayQueryEXT rayQuery0b;
g_rayQueryArray[idx] = rayQuery0b; // Stored here, then overwritten with rayQuery0a
g_rayQueryArray[idx] = rayQuery0a;
// No separate allocation, just a handle copy
// optimizations should have eliminated load from global array
rayQueryEXT rayQuery0c = g_rayQueryArray[idx];
// rayQuery0a is the one actually used here
rayQueryInitializeEXT(rayQuery0c, rtas, gl_RayFlagsOpaqueEXT, gl_RayFlagsCullBackFacingTrianglesEXT, ray.pos, ray.tmin, ray.dir, ray.tmax);
// AllocateRayQuery occurs here, rather than next to allocas
// Should not be extray allocate, since above should allocate and copy
rayQueryEXT rayQuery1c;
// update the rayFlags as RAY_FLAG_FORCE_OPAQUE
rayQueryInitializeEXT(rayQuery1c, rtas, gl_RayFlagsOpaqueEXT, gl_RayFlagsCullFrontFacingTrianglesEXT, ray.pos, ray.tmin, ray.dir, ray.tmax);
rayQueryInitializeEXT(rayQuery1c, rtas, gl_RayFlagsOpaqueEXT|gl_RayFlagsNoOpaqueEXT, gl_RayFlagsCullOpaqueEXT, ray.pos, ray.tmin, ray.dir, ray.tmax);
}
glslang/MachineIndependent/ParseContextBase.cpp
View file @
f986436a
...
...
@@ -184,6 +184,9 @@ bool TParseContextBase::lValueErrorCheck(const TSourceLoc& loc, const char* op,
case
EbtAccStruct
:
message
=
"can't modify accelerationStructureNV"
;
break
;
case
EbtRayQuery
:
message
=
"can't modify rayQueryEXT"
;
break
;
#endif
default
:
break
;
...
...
gtests/Spv.FromFile.cpp
View file @
f986436a
...
...
@@ -231,7 +231,6 @@ INSTANTIATE_TEST_CASE_P(
"spv.while-simple.vert"
,
// vulkan-specific tests
"rayQuery.rgen"
,
"rayQuery-decls.rgen"
,
"rayQuery-no-cse.rgen"
,
"rayQuery-initialize.rgen"
,
"rayQuery-allOps.rgen"
,
...
...
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