Lines Matching refs:desc

399    const struct util_format_description *desc = util_format_description(format);
401 assert(desc);
402 if (!desc) {
406 return desc->name;
412 const struct util_format_description *desc = util_format_description(format);
414 assert(desc);
415 if (!desc) {
419 return desc->short_name;
428 const struct util_format_description *desc = util_format_description(format);
434 return desc->layout == UTIL_FORMAT_LAYOUT_PLAIN ? TRUE : FALSE;
440 const struct util_format_description *desc = util_format_description(format);
442 assert(desc);
443 if (!desc) {
447 switch (desc->layout) {
460 const struct util_format_description *desc = util_format_description(format);
462 assert(desc);
463 if (!desc) {
467 return desc->layout == UTIL_FORMAT_LAYOUT_S3TC ? TRUE : FALSE;
473 const struct util_format_description *desc = util_format_description(format);
474 return desc->colorspace == UTIL_FORMAT_COLORSPACE_SRGB;
478 util_format_has_depth(const struct util_format_description *desc)
480 return desc->colorspace == UTIL_FORMAT_COLORSPACE_ZS &&
481 desc->swizzle[0] != UTIL_FORMAT_SWIZZLE_NONE;
485 util_format_has_stencil(const struct util_format_description *desc)
487 return desc->colorspace == UTIL_FORMAT_COLORSPACE_ZS &&
488 desc->swizzle[1] != UTIL_FORMAT_SWIZZLE_NONE;
494 const struct util_format_description *desc = util_format_description(format);
496 assert(desc);
497 if (!desc) {
501 return util_format_has_depth(desc) ||
502 util_format_has_stencil(desc);
508 const struct util_format_description *desc = util_format_description(format);
510 assert(desc);
511 if (!desc) {
515 return util_format_has_depth(desc) &&
516 util_format_has_stencil(desc);
527 util_format_colormask(const struct util_format_description *desc)
532 switch (desc->colorspace) {
538 if (desc->swizzle[chan] < 4) {
555 * @param desc a format description to check colormask with
559 util_format_colormask_full(const struct util_format_description *desc, unsigned colormask)
561 return (~colormask & util_format_colormask(desc)) == 0;
598 util_format_is_array(const struct util_format_description *desc);
624 util_format_is_rgba8_variant(const struct util_format_description *desc)
628 if(desc->block.width != 1 ||
629 desc->block.height != 1 ||
630 desc->block.bits != 32)
634 if(desc->channel[chan].type != UTIL_FORMAT_TYPE_UNSIGNED &&
635 desc->channel[chan].type != UTIL_FORMAT_TYPE_VOID)
637 if(desc->channel[chan].size != 8)
651 const struct util_format_description *desc = util_format_description(format);
653 assert(desc);
654 if (!desc) {
658 return desc->block.bits;
677 const struct util_format_description *desc = util_format_description(format);
679 assert(desc);
680 if (!desc) {
684 return desc->block.width;
690 const struct util_format_description *desc = util_format_description(format);
692 assert(desc);
693 if (!desc) {
697 return desc->block.height;
744 const struct util_format_description *desc = util_format_description(format);
758 if (desc->colorspace == UTIL_FORMAT_COLORSPACE_SRGB) {
761 desc_colorspace = desc->colorspace;
768 switch (desc->swizzle[component]) {
770 return desc->channel[0].size;
772 return desc->channel[1].size;
774 return desc->channel[2].size;
776 return desc->channel[3].size;
785 const struct util_format_description *desc = util_format_description(format);
792 switch (desc->colorspace) {
795 return desc->swizzle[3] != UTIL_FORMAT_SWIZZLE_1;
920 const struct util_format_description *desc = util_format_description(format);
921 return desc->nr_channels;
931 const struct util_format_description *desc = util_format_description(format);
935 if (desc->channel[i].type != UTIL_FORMAT_TYPE_VOID)