Commit Graph

34 Commits

Author SHA1 Message Date
baldurk 76e273cbd4 Fix another clang warning 2022-02-03 11:13:16 +00:00
baldurk e42b0ff2ca Refactor ShaderVariable use and non-32-bit precision. Closes #2466 2022-02-02 15:00:43 +00:00
baldurk 72af2abd7d Handle runtime/unbounded arrays in buffer viewer formatting 2021-11-01 13:53:28 +00:00
baldurk 3fb4e230de Handle single-basic-element buffers in GL/Vulkan properly. Closes #2378
* We still need to handle multiple elements in the root of a struct specially by
  commenting out the fixed members, but the final element needs to go through
  the normal DeclareStruct() path to handle things like per-column padding in
  matrices etc.
2021-10-04 12:02:09 +01:00
baldurk 15cbeef054 Fix offset calculation with declaring nested buffers in format string
* When calculating the size for a struct member we need to properly recurse
2021-02-08 14:05:04 +00:00
baldurk 026da176bb Update copyright years to 2021 2021-01-13 13:56:10 +00:00
baldurk 7ff7e0a71d Replace fixed C arrays with wrapper class in public interface
* These map more naturally to python tuples and are easier to wrap in and out.
* We also tidy up the FloatVecVal etc and standardise the members of
  ShaderValue.
2020-12-09 18:16:08 +00:00
baldurk 580f96c8a1 Rename ShaderVariableType/Descriptor to ShaderConstant
* These structs are no longer used with ShaderVariable so the name is misleading
  at best.
2020-12-09 15:18:27 +00:00
baldurk 8a58ba6843 Allow arrays of pointers in GPU buffers 2020-12-07 17:42:18 +00:00
baldurk fa24dc8872 Silence some PVS warnings 2020-08-20 16:11:05 +01:00
baldurk 0d026a43d6 Remove CompType::Double
* This is a leftover artifact from before we had general extended type support
  and double was the only non-32 bit type we handled. Now we support most type
  formats so doubles are just CompType::Float with 8 byte width
2020-07-12 10:52:10 +01:00
baldurk d1d84d22b0 Don't print error if struct stride is exactly matched 2020-07-12 10:52:10 +01:00
baldurk f40490c049 Avoid underflow when calculating padding bytes 2020-06-05 19:36:02 +01:00
baldurk 8ff6251d98 Handle hlsl/glsl matrix dimension order properly in buffer formatter 2020-06-05 14:19:39 +01:00
baldurk fe8a35b2f0 Fix calculation of matrix variable sizes. Closes #1927 2020-06-05 14:11:14 +01:00
baldurk 40183bff46 Fix typo in buffer formatter for padded column major matrices 2020-06-05 13:54:26 +01:00
baldurk 72d789e486 Add necessary padding in buffer formatted between members 2020-05-26 13:52:47 +01:00
baldurk 5eb80370fd Change formatted for RGBA4 to xshort instead of xbyte2 2020-05-18 10:57:33 +01:00
baldurk 49d6f205e9 Add padding for buffers where matrixByteStride needs it. Closes #1874 2020-05-11 18:04:22 +01:00
baldurk 7045e241e2 Specify row_major on struct members. Closes #1873 2020-05-11 18:04:22 +01:00
baldurk 1ad2cf0905 Handle opengl dvecX / dmatX types in buffer formatter 2020-05-08 20:43:25 +01:00
baldurk 90c10ea1fc Handle boolean inputs in vulkan shader parameters
* We change to use VarType instead of CompType for signature parameters which
  allows us to represent different types of variables beyond just
  unsigned/signed integer and float.
2020-05-07 22:46:41 +01:00
baldurk 417dc91925 Set the correct number of columns for packed formats in buffer view 2020-05-06 19:35:50 +01:00
baldurk 84a804f95d Set byte strides for error case of buffer formatter 2020-04-28 18:15:33 +01:00
baldurk 133b8a41b9 Fix handling of column-major matrices in buffer viewer. Closes #1848 2020-04-27 13:46:58 +01:00
baldurk 267798b240 Add boolean vartype 2020-04-24 20:14:48 +01:00
baldurk 4dc0d799db Add default child name for structs when generating buffer formatter 2020-04-24 20:14:47 +01:00
baldurk 86c5c70a13 Fix packed format (uintten/unormten) use in the buffer viewer 2020-04-21 17:09:32 +01:00
baldurk 73c05536e0 Make Pointer a full VarType instead of a ShaderVariable member 2020-04-09 18:36:12 +01:00
baldurk 410f9d86bd Remove register/HLSL handling from shader viewer, work agnostically
* The shader viewer shouldn't handle specifics of D3D bytecode, instead it now
  works generally with whatever the debug and source variables are.
* VarType::Unknown is used for D3D registers which are typeless.
2020-02-06 17:58:41 +00:00
baldurk 2916c0f9f7 Update copyright years to 2020 2020-01-06 16:20:45 +00:00
baldurk 5838a33d7e Don't add array stride until first child struct 2019-11-29 22:41:09 +00:00
baldurk e205054317 Add UI support for GPU typed pointers in buffers 2019-11-29 13:53:44 +00:00
baldurk b3979262a5 Replace FormatElement with ShaderConstant/ShaderVariableType
* FormatElement is now a static BufferFormatter class to help generate and parse
  buffer formatting strings
2019-11-29 13:53:44 +00:00