File tree 8 files changed +17
-24
lines changed
8 files changed +17
-24
lines changed Original file line number Diff line number Diff line change @@ -26,17 +26,20 @@ vulkan = ["wgn/vulkan-portability"]
26
26
[dependencies .wgn ]
27
27
package = " wgpu-native"
28
28
version = " 0.5"
29
- # git = "https://github.com/gfx-rs/wgpu"
29
+ git = " https://github.com/gfx-rs/wgpu"
30
+ rev = " 49dbe08f37f8396cff0d6672667a48116ec487f5"
30
31
31
32
[dependencies .wgc ]
32
33
package = " wgpu-core"
33
34
version = " 0.5"
34
- # git = "https://github.com/gfx-rs/wgpu"
35
+ git = " https://github.com/gfx-rs/wgpu"
36
+ rev = " 49dbe08f37f8396cff0d6672667a48116ec487f5"
35
37
36
38
[dependencies .wgt ]
37
39
package = " wgpu-types"
38
40
version = " 0.5"
39
- # git = "https://github.com/gfx-rs/wgpu"
41
+ git = " https://github.com/gfx-rs/wgpu"
42
+ rev = " 49dbe08f37f8396cff0d6672667a48116ec487f5"
40
43
41
44
[dependencies ]
42
45
arrayvec = " 0.5"
Original file line number Diff line number Diff line change @@ -43,7 +43,6 @@ async fn run() {
43
43
// The render pipeline renders data into this texture
44
44
let texture = device. create_texture ( & wgpu:: TextureDescriptor {
45
45
size : texture_extent,
46
- array_layer_count : 1 ,
47
46
mip_level_count : 1 ,
48
47
sample_count : 1 ,
49
48
dimension : wgpu:: TextureDimension :: D2 ,
Original file line number Diff line number Diff line change @@ -167,7 +167,6 @@ impl framework::Example for Example {
167
167
} ;
168
168
let texture = device. create_texture ( & wgpu:: TextureDescriptor {
169
169
size : texture_extent,
170
- array_layer_count : 1 ,
171
170
mip_level_count : 1 ,
172
171
sample_count : 1 ,
173
172
dimension : wgpu:: TextureDimension :: D2 ,
Original file line number Diff line number Diff line change @@ -258,7 +258,6 @@ impl framework::Example for Example {
258
258
} ;
259
259
let texture = device. create_texture ( & wgpu:: TextureDescriptor {
260
260
size : texture_extent,
261
- array_layer_count : 1 ,
262
261
mip_level_count,
263
262
sample_count : 1 ,
264
263
dimension : wgpu:: TextureDimension :: D2 ,
Original file line number Diff line number Diff line change @@ -95,7 +95,6 @@ impl Example {
95
95
} ;
96
96
let multisampled_frame_descriptor = & wgpu:: TextureDescriptor {
97
97
size : multisampled_texture_extent,
98
- array_layer_count : 1 ,
99
98
mip_level_count : 1 ,
100
99
sample_count : sample_count,
101
100
dimension : wgpu:: TextureDimension :: D2 ,
Original file line number Diff line number Diff line change @@ -176,7 +176,7 @@ impl Example {
176
176
const SHADOW_SIZE : wgpu:: Extent3d = wgpu:: Extent3d {
177
177
width : 512 ,
178
178
height : 512 ,
179
- depth : 1 ,
179
+ depth : Self :: MAX_LIGHTS as u32 ,
180
180
} ;
181
181
const DEPTH_FORMAT : wgpu:: TextureFormat = wgpu:: TextureFormat :: Depth32Float ;
182
182
@@ -341,7 +341,6 @@ impl framework::Example for Example {
341
341
342
342
let shadow_texture = device. create_texture ( & wgpu:: TextureDescriptor {
343
343
size : Self :: SHADOW_SIZE ,
344
- array_layer_count : Self :: MAX_LIGHTS as u32 ,
345
344
mip_level_count : 1 ,
346
345
sample_count : 1 ,
347
346
dimension : wgpu:: TextureDimension :: D2 ,
@@ -635,7 +634,6 @@ impl framework::Example for Example {
635
634
height : sc_desc. height ,
636
635
depth : 1 ,
637
636
} ,
638
- array_layer_count : 1 ,
639
637
mip_level_count : 1 ,
640
638
sample_count : 1 ,
641
639
dimension : wgpu:: TextureDimension :: D2 ,
@@ -683,7 +681,6 @@ impl framework::Example for Example {
683
681
height : sc_desc. height ,
684
682
depth : 1 ,
685
683
} ,
686
- array_layer_count : 1 ,
687
684
mip_level_count : 1 ,
688
685
sample_count : 1 ,
689
686
dimension : wgpu:: TextureDimension :: D2 ,
Original file line number Diff line number Diff line change @@ -180,15 +180,12 @@ impl framework::Example for Skybox {
180
180
} )
181
181
. collect :: < Vec < _ > > ( ) ;
182
182
183
- let texture_extent = wgpu:: Extent3d {
184
- width : image_width,
185
- height : image_height,
186
- depth : 1 ,
187
- } ;
188
-
189
183
let texture = device. create_texture ( & wgpu:: TextureDescriptor {
190
- size : texture_extent,
191
- array_layer_count : 6 ,
184
+ size : wgpu:: Extent3d {
185
+ width : image_width,
186
+ height : image_height,
187
+ depth : 6 ,
188
+ } ,
192
189
mip_level_count : 1 ,
193
190
sample_count : 1 ,
194
191
dimension : wgpu:: TextureDimension :: D2 ,
@@ -219,7 +216,11 @@ impl framework::Example for Skybox {
219
216
array_layer : i as u32 ,
220
217
origin : wgpu:: Origin3d :: ZERO ,
221
218
} ,
222
- texture_extent,
219
+ wgpu:: Extent3d {
220
+ width : image_width,
221
+ height : image_height,
222
+ depth : 1 ,
223
+ } ,
223
224
) ;
224
225
}
225
226
Original file line number Diff line number Diff line change @@ -442,9 +442,6 @@ pub struct TextureDescriptor<'a> {
442
442
/// The size of the texture.
443
443
pub size : Extent3d ,
444
444
445
- /// The array layer count.
446
- pub array_layer_count : u32 ,
447
-
448
445
/// The mip level count.
449
446
pub mip_level_count : u32 ,
450
447
@@ -942,7 +939,6 @@ impl Device {
942
939
& wgt:: TextureDescriptor {
943
940
label : owned_label. as_ptr ( ) ,
944
941
size : desc. size ,
945
- array_layer_count : desc. array_layer_count ,
946
942
mip_level_count : desc. mip_level_count ,
947
943
sample_count : desc. sample_count ,
948
944
dimension : desc. dimension ,
You can’t perform that action at this time.
0 commit comments