File: hlsl.cbuffer-offsets.comp

package info (click to toggle)
glslang 16.2.0-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 51,712 kB
  • sloc: cpp: 92,305; yacc: 4,320; sh: 603; python: 305; ansic: 94; javascript: 74; makefile: 17
file content (44 lines) | stat: -rw-r--r-- 687 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
// Correct offsets obtained from "HLSL Constant Buffer Visualizer"
// https://maraneshi.github.io/HLSL-ConstantBufferLayoutVisualizer/

cbuffer CB {
    float f1;
    float3 f3a3[3];
    float f2;
    float f3;

    float1x1 m11;
    float1x2 m12;
    float2x1 m21;
    float2x2 m22;

    float3x3 m33;
    float f4;

    float3x4 m34;
    float f5;

    float4x3 m43;
    float f6;

    row_major float1x1 rm11;
    row_major float1x2 rm12;
    row_major float2x1 rm21;
    row_major float2x2 rm22;

    row_major float3x3 rm33;
    float f7;

    row_major float3x4 rm34;
    float f8;

    row_major float4x3 rm43;
    float f9;

    float f1a3[3];
    float f10;
};

void main()
{
}