pipe_get_tile_raw(pt, src, x, y, w, h, packed, 0);
- /* softpipe's S8_UINT texture cache fetch needs to take the rgba_format
- * path, not ui (since there's no ui unpack for s8, but it's technically
- * pure integer).
- */
- if (util_format_is_pure_uint(format) &&
- !util_format_is_depth_or_stencil(format)) {
- util_format_read_4ui(format,
- dst, dst_stride * sizeof(float),
- packed, util_format_get_stride(format, w),
- 0, 0, w, h);
- } else if (util_format_is_pure_sint(format)) {
- util_format_read_4i(format,
- dst, dst_stride * sizeof(float),
- packed, util_format_get_stride(format, w),
- 0, 0, w, h);
- } else {
- switch (format) {
- case PIPE_FORMAT_Z16_UNORM:
- z16_get_tile_rgba((ushort *) packed, w, h, dst, dst_stride);
- break;
- case PIPE_FORMAT_Z32_UNORM:
- z32_get_tile_rgba((unsigned *) packed, w, h, dst, dst_stride);
- break;
- case PIPE_FORMAT_Z24_UNORM_S8_UINT:
- case PIPE_FORMAT_Z24X8_UNORM:
- s8z24_get_tile_rgba((unsigned *) packed, w, h, dst, dst_stride);
- break;
- case PIPE_FORMAT_S8_UINT:
- s8_get_tile_rgba((unsigned char *) packed, w, h, dst, dst_stride);
- break;
- case PIPE_FORMAT_X24S8_UINT:
- s8x24_get_tile_rgba((unsigned *) packed, w, h, dst, dst_stride);
- break;
- case PIPE_FORMAT_S8_UINT_Z24_UNORM:
- case PIPE_FORMAT_X8Z24_UNORM:
- z24s8_get_tile_rgba((unsigned *) packed, w, h, dst, dst_stride);
- break;
- case PIPE_FORMAT_S8X24_UINT:
- x24s8_get_tile_rgba((unsigned *) packed, w, h, dst, dst_stride);
- break;
- case PIPE_FORMAT_Z32_FLOAT:
- z32f_get_tile_rgba((float *) packed, w, h, dst, dst_stride);
- break;
- case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
- z32f_x24s8_get_tile_rgba((float *) packed, w, h, dst, dst_stride);
- break;
- case PIPE_FORMAT_X32_S8X24_UINT:
- x32_s8_get_tile_rgba((unsigned *) packed, w, h, dst, dst_stride);
- break;
- default:
- util_format_read_4f(format,
+ switch (format) {
+ case PIPE_FORMAT_Z16_UNORM:
+ z16_get_tile_rgba((ushort *) packed, w, h, dst, dst_stride);
+ break;
+ case PIPE_FORMAT_Z32_UNORM:
+ z32_get_tile_rgba((unsigned *) packed, w, h, dst, dst_stride);
+ break;
+ case PIPE_FORMAT_Z24_UNORM_S8_UINT:
+ case PIPE_FORMAT_Z24X8_UNORM:
+ s8z24_get_tile_rgba((unsigned *) packed, w, h, dst, dst_stride);
+ break;
+ case PIPE_FORMAT_S8_UINT:
+ s8_get_tile_rgba((unsigned char *) packed, w, h, dst, dst_stride);
+ break;
+ case PIPE_FORMAT_X24S8_UINT:
+ s8x24_get_tile_rgba((unsigned *) packed, w, h, dst, dst_stride);
+ break;
+ case PIPE_FORMAT_S8_UINT_Z24_UNORM:
+ case PIPE_FORMAT_X8Z24_UNORM:
+ z24s8_get_tile_rgba((unsigned *) packed, w, h, dst, dst_stride);
+ break;
+ case PIPE_FORMAT_S8X24_UINT:
+ x24s8_get_tile_rgba((unsigned *) packed, w, h, dst, dst_stride);
+ break;
+ case PIPE_FORMAT_Z32_FLOAT:
+ z32f_get_tile_rgba((float *) packed, w, h, dst, dst_stride);
+ break;
+ case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
+ z32f_x24s8_get_tile_rgba((float *) packed, w, h, dst, dst_stride);
+ break;
+ case PIPE_FORMAT_X32_S8X24_UINT:
+ x32_s8_get_tile_rgba((unsigned *) packed, w, h, dst, dst_stride);
+ break;
+ default:
+ if (util_format_is_pure_uint(format)) {
+ util_format_read_4ui(format,
+ dst, dst_stride * sizeof(float),
+ packed, util_format_get_stride(format, w),
+ 0, 0, w, h);
+ } else if (util_format_is_pure_sint(format)) {
+ util_format_read_4i(format,
dst, dst_stride * sizeof(float),
packed, util_format_get_stride(format, w),
0, 0, w, h);
+ } else {
+ util_format_read_4f(format,
+ dst, dst_stride * sizeof(float),
+ packed, util_format_get_stride(format, w),
+ 0, 0, w, h);
}
}