@@ -72,22 +72,40 @@ class zeImageDescriptorTest
7272 }
7373 uint64_t width = 1 ;
7474 uint32_t height = 1 , depth = 1 ;
75- if (image_size == ImageSize::min) {
76- width = lzt::image_widths[0 ];
77- height = lzt::image_heights[0 ];
78- depth = lzt::image_depths[0 ];
79- } else if (image_size == ImageSize::large) {
80- switch (image_type) {
81- case ZE_IMAGE_TYPE_3D:
75+ switch (image_type) {
76+ case ZE_IMAGE_TYPE_3D:
77+ if (image_size == ImageSize::min) {
78+ width = lzt::image_widths[0 ];
79+ height = lzt::image_heights[0 ];
80+ depth = lzt::image_depths[0 ];
81+ } else if (image_size == ImageSize::large) {
82+ width = lzt::image_widths[1 ];
83+ height = lzt::image_heights[1 ];
8284 depth = lzt::image_depths[1 ];
83- case ZE_IMAGE_TYPE_2D:
84- case ZE_IMAGE_TYPE_2DARRAY:
85+ }
86+ break ;
87+ case ZE_IMAGE_TYPE_2D:
88+ [[fallthrough]];
89+ case ZE_IMAGE_TYPE_2DARRAY:
90+ if (image_size == ImageSize::min) {
91+ width = lzt::image_widths[0 ];
92+ height = lzt::image_heights[0 ];
93+ } else if (image_size == ImageSize::large) {
94+ width = lzt::image_widths[1 ];
8595 height = lzt::image_heights[1 ];
86- case ZE_IMAGE_TYPE_1D:
87- case ZE_IMAGE_TYPE_1DARRAY:
96+ }
97+ break ;
98+ case ZE_IMAGE_TYPE_1D:
99+ [[fallthrough]];
100+ case ZE_IMAGE_TYPE_1DARRAY:
101+ if (image_size == ImageSize::min) {
102+ width = lzt::image_widths[0 ];
103+ } else if (image_size == ImageSize::large) {
88104 width = lzt::image_widths[1 ];
89- break ;
90105 }
106+ break ;
107+ default :
108+ break ;
91109 }
92110
93111 image_descriptor.stype = ZE_STRUCTURE_TYPE_IMAGE_DESC;
0 commit comments