Przeglądaj źródła

Merged PR 50: Fix attributes for ray intrinsics that can change during traversal

Fix attributes for ray intrinsics that can change during traversal
Tex Riddell 7 lat temu
rodzic
commit
e237f8a57e
2 zmienionych plików z 2 dodań i 2 usunięć
  1. 1 1
      lib/HLSL/DxilOperations.cpp
  2. 1 1
      utils/hct/hctdb.py

+ 1 - 1
lib/HLSL/DxilOperations.cpp

@@ -287,7 +287,7 @@ const OP::OpCodeProperty OP::m_OpCodeProps[(unsigned)OP::OpCode::NumOpCodes] = {
 
   // RayT                                                                                                                   void,     h,     f,     d,    i1,    i8,   i16,   i32,   i64,   udt,  obj,  function attribute
   {  OC::RayTMin,                 "RayTMin",                  OCC::RayTMin,                  "rayTMin",                    false, false,  true, false, false, false, false, false, false, false, false, Attribute::ReadNone, },
-  {  OC::RayTCurrent,             "RayTCurrent",              OCC::RayTCurrent,              "rayTCurrent",                false, false,  true, false, false, false, false, false, false, false, false, Attribute::ReadNone, },
+  {  OC::RayTCurrent,             "RayTCurrent",              OCC::RayTCurrent,              "rayTCurrent",                false, false,  true, false, false, false, false, false, false, false, false, Attribute::ReadOnly, },
 
   // AnyHit Terminals                                                                                                       void,     h,     f,     d,    i1,    i8,   i16,   i32,   i64,   udt,  obj,  function attribute
   {  OC::IgnoreHit,               "IgnoreHit",                OCC::IgnoreHit,                "ignoreHit",                   true, false, false, false, false, false, false, false, false, false, false, Attribute::NoReturn, },

+ 1 - 1
utils/hct/hctdb.py

@@ -1194,7 +1194,7 @@ class db_dxil(object):
             db_dxil_param(0, "f", "", "result")])
         next_op_idx += 1
 
-        self.add_dxil_op("RayTCurrent", next_op_idx, "RayTCurrent", "float representing the current parametric ending point for the ray", "f", "rn", [
+        self.add_dxil_op("RayTCurrent", next_op_idx, "RayTCurrent", "float representing the current parametric ending point for the ray", "f", "ro", [
             db_dxil_param(0, "f", "", "result")])
         next_op_idx += 1