Debian Codegraph @

debian/missing-sources/glam-0.16.0/src/cast.rs

raw symbols SCIP
1 use crate::{DMat2, DMat3, DMat4, DQuat, DVec2, DVec3, DVec4};
2 use crate::{IVec2, IVec3, IVec4};
3 use crate::{Mat2, Mat3, Mat3A, Mat4, Quat, Vec2, Vec3, Vec3A, Vec4};
4 use crate::{UVec2, UVec3, UVec4};
5 #[cfg(target_arch = "x86")]
6 use core::arch::x86::*;
7 #[cfg(target_arch = "x86_64")]
8 use core::arch::x86_64::*;
9
10 #[repr(C)]
11 pub union Vec4Cast {
12 #[cfg(any(target_arch = "x86", target_arch = "x86_64"))]
13 pub m128: __m128,
14 pub fx4: [f32; 4],
15 pub fx2x2: [[f32; 2]; 2],
16 pub v4: Vec4,
17 pub v3a: Vec3A,
18 pub q: Quat,
19 }
20
21 #[repr(C)]
22 pub union Vec3Cast {
23 pub fx3: [f32; 3],
24 pub v3: Vec3,
25 }
26
27 #[repr(C)]
28 pub union Vec2Cast {
29 pub fx2: [f32; 2],
30 pub v2: Vec2,
31 }
32
33 #[repr(C)]
34 pub union F32x9Cast {
35 pub fx3x3: [[f32; 3]; 3],
36 pub fx9: [f32; 9],
37 }
38
39 #[repr(C)]
40 pub union F32x16Cast {
41 pub fx4x4: [[f32; 4]; 4],
42 pub fx16: [f32; 16],
43 }
44
45 #[repr(C)]
46 pub union Mat4Cast {
47 pub v4x4: [Vec4; 4],
48 pub m4: Mat4,
49 }
50
51 #[repr(C)]
52 pub union Mat3Cast {
53 pub v3x3: [Vec3; 3],
54 pub m3: Mat3,
55 }
56
57 #[repr(C)]
58 pub union Mat3ACast {
59 pub v3x3: [Vec3A; 3],
60 pub m3: Mat3A,
61 }
62
63 #[repr(C)]
64 pub union Mat2Cast {
65 pub v2x2: [Vec2; 2],
66 pub m2: Mat2,
67 }
68
69 #[repr(C)]
70 pub union DVec4Cast {
71 pub fx4: [f64; 4],
72 pub fx2x2: [[f64; 2]; 2],
73 pub v4: DVec4,
74 pub q: DQuat,
75 }
76
77 #[repr(C)]
78 pub union DVec3Cast {
79 pub fx3: [f64; 3],
80 pub v3: DVec3,
81 }
82
83 #[repr(C)]
84 pub union DVec2Cast {
85 pub fx2: [f64; 2],
86 pub v2: DVec2,
87 }
88
89 #[repr(C)]
90 pub union F64x9Cast {
91 pub fx3x3: [[f64; 3]; 3],
92 pub fx9: [f64; 9],
93 }
94
95 #[repr(C)]
96 pub union F64x16Cast {
97 pub fx4x4: [[f64; 4]; 4],
98 pub fx16: [f64; 16],
99 }
100
101 #[repr(C)]
102 pub union DMat4Cast {
103 pub v4x4: [DVec4; 4],
104 pub m4: DMat4,
105 }
106
107 #[repr(C)]
108 pub union DMat3Cast {
109 pub v3x3: [DVec3; 3],
110 pub m3: DMat3,
111 }
112
113 #[repr(C)]
114 pub union DMat2Cast {
115 pub v2x2: [DVec2; 2],
116 pub m2: DMat2,
117 }
118
119 #[repr(C)]
120 pub union IVec4Cast {
121 #[cfg(any(target_arch = "x86", target_arch = "x86_64"))]
122 pub m128: __m128i,
123 pub ix4: [i32; 4],
124 pub ix2x2: [[i32; 2]; 2],
125 pub v4: IVec4,
126 }
127
128 #[repr(C)]
129 pub union IVec3Cast {
130 pub ix3: [i32; 3],
131 pub v3: IVec3,
132 }
133
134 #[repr(C)]
135 pub union IVec2Cast {
136 pub ix2: [i32; 2],
137 pub v2: IVec2,
138 }
139
140 #[repr(C)]
141 pub union UVec4Cast {
142 #[cfg(any(target_arch = "x86", target_arch = "x86_64"))]
143 pub m128: __m128i,
144 pub ux4: [u32; 4],
145 pub ux2x2: [[u32; 2]; 2],
146 pub v4: UVec4,
147 }
148
149 #[repr(C)]
150 pub union UVec3Cast {
151 pub ux3: [u32; 3],
152 pub v3: UVec3,
153 }
154
155 #[repr(C)]
156 pub union UVec2Cast {
157 pub ux2: [u32; 2],
158 pub v2: UVec2,
159 }