Lines Matching refs:format
28 #include "util/format/u_format.h"
123 static uint32_t r300_depth_clear_cb_value(enum pipe_format format,
127 util_pack_color(rgba, format, &uc);
129 if (util_format_get_blocksizebits(format) == 32)
165 static uint32_t r300_depth_clear_value(enum pipe_format format,
168 switch (format) {
171 return util_pack_z(format, depth);
174 return util_pack_z_stencil(format, depth, stencil);
197 util_pack_color(color->f, fb->cbufs[0]->format, &uc);
199 if (fb->cbufs[0]->format == PIPE_FORMAT_R16G16B16A16_FLOAT ||
200 fb->cbufs[0]->format == PIPE_FORMAT_R16G16B16X16_FLOAT) {
278 if (fb->zsbuf->texture->format == PIPE_FORMAT_S8_UINT_Z24_UNORM &&
306 r300_depth_clear_value(fb->zsbuf->format, depth, stencil);
365 r300_depth_clear_cb_value(surf->base.format, color->f);
531 bool r300_is_blit_supported(enum pipe_format format)
534 util_format_description(format);
565 !r300_is_blit_supported(dst->format)) {
576 /* The code below changes the texture format so that the copy can be done
583 layout = util_format_description(dst_templ.format)->layout;
587 (!screen->is_format_supported(screen, src_templ.format, src->target,
590 !screen->is_format_supported(screen, dst_templ.format, dst->target,
593 switch (util_format_get_blocksize(dst_templ.format)) {
595 dst_templ.format = PIPE_FORMAT_I8_UNORM;
598 dst_templ.format = PIPE_FORMAT_B4G4R4A4_UNORM;
601 dst_templ.format = PIPE_FORMAT_B8G8R8A8_UNORM;
604 dst_templ.format = PIPE_FORMAT_R16G16B16A16_UNORM;
607 debug_printf("r300: copy_region: Unhandled format: %s. Falling back to software.\n"
609 util_format_short_name(dst_templ.format));
611 src_templ.format = dst_templ.format;
617 assert(src_templ.format == dst_templ.format);
629 switch (util_format_get_blocksize(dst_templ.format)) {
633 dst_templ.format = PIPE_FORMAT_R8G8B8A8_UNORM;
643 dst_templ.format = PIPE_FORMAT_R8G8B8A8_UNORM;
646 src_templ.format = dst_templ.format;
656 if (!screen->is_format_supported(screen, dst_templ.format,
660 !screen->is_format_supported(screen, src_templ.format,
702 info->dst.resource->format == info->src.resource->format &&
703 info->dst.resource->format == info->dst.format &&
704 info->src.resource->format == info->src.format &&
726 enum pipe_format format)
734 surf_tmpl.format = format;
737 surf_tmpl.format = format;
783 info->src.format);
790 templ.format = info->src.resource->format;
802 info->src.format);
828 if (util_format_is_srgb(info.src.format)) {
829 info.src.format = util_format_linear(info.src.format);
830 info.dst.format = util_format_linear(info.dst.format);
835 !util_format_is_depth_or_stencil(info.src.resource->format)) {
846 * S8Z24 is the only supported stencil format. */
848 info.src.format == PIPE_FORMAT_S8_UINT_Z24_UNORM &&
849 info.dst.format == PIPE_FORMAT_S8_UINT_Z24_UNORM) {
858 info.src.format = PIPE_FORMAT_B8G8R8A8_UNORM;
859 info.dst.format = PIPE_FORMAT_B8G8R8A8_UNORM;