Lines Matching refs:plane
115 static rect_t get_afbc_sb_size(alloc_type_t alloc_type, const uint8_t plane) in get_afbc_sb_size() argument
117 if (plane > 0 && alloc_type.is_afbc() && alloc_type.is_multi_plane) in get_afbc_sb_size()
300 const uint8_t plane, in get_pixel_w_h() argument
303 const rect_t sb = get_afbc_sb_size(alloc_type, plane); in get_pixel_w_h()
310 if (plane == 0 || !format.planes_contiguous) in get_pixel_w_h()
319 if (plane > 0) in get_pixel_w_h()
330 if (has_cpu_usage && (plane == 0 || !format.planes_contiguous)) in get_pixel_w_h()
354 afbc_tile.width = format.bpp_afbc[plane] > 32 ? 4 * afbc_tile.width : 8 * afbc_tile.width; in get_pixel_w_h()
355 afbc_tile.height = format.bpp_afbc[plane] > 32 ? 4 * afbc_tile.height : 8 * afbc_tile.height; in get_pixel_w_h()
371 ALOGV("Plane[%hhu]: [SUB-SAMPLE] w:%d, h:%d\n", plane, *width, *height); in get_pixel_w_h()
372 ALOGV("Plane[%hhu]: [PIXEL_ALIGN] w:%d, h:%d\n", plane, pixel_align_w, pixel_align_h); in get_pixel_w_h()
373 ALOGV("Plane[%hhu]: [LINEAR_TILE] w:%" PRIu16 "\n", plane, format.tile_size); in get_pixel_w_h()
374 …ALOGV("Plane[%hhu]: [AFBC_TILE] w:%" PRIu16 ", h:%" PRIu16 "\n", plane, afbc_tile.width, afbc_tile… in get_pixel_w_h()
428 static void update_yv12_stride(int8_t plane, in update_yv12_stride() argument
433 if (plane == 0) in update_yv12_stride()
483 for (uint8_t plane = 0; plane < format.npln; plane++) in calc_allocation_size() local
485 plane_info[plane].alloc_width = width; in calc_allocation_size()
486 plane_info[plane].alloc_height = height; in calc_allocation_size()
487 get_pixel_w_h(&plane_info[plane].alloc_width, in calc_allocation_size()
488 &plane_info[plane].alloc_height, in calc_allocation_size()
491 plane, in calc_allocation_size()
494 plane_info[plane].alloc_width, plane_info[plane].alloc_height); in calc_allocation_size()
501 assert((plane_info[plane].alloc_width * format.bpp_afbc[plane]) % 8 == 0); in calc_allocation_size()
502 plane_info[plane].byte_stride = (plane_info[plane].alloc_width * format.bpp_afbc[plane]) / 8; in calc_allocation_size()
506 assert((plane_info[plane].alloc_width * format.bpp[plane]) % 8 == 0); in calc_allocation_size()
507 plane_info[plane].byte_stride = (plane_info[plane].alloc_width * format.bpp[plane]) / 8; in calc_allocation_size()
525 assert((format.bpp[plane] * format.align_w_cpu) % 8 == 0); in calc_allocation_size()
526 if (plane == 0 || !format.planes_contiguous) in calc_allocation_size()
527 cpu_align = (format.bpp[plane] * format.align_w_cpu) / 8; in calc_allocation_size()
532 plane_info[plane].byte_stride = GRALLOC_ALIGN(plane_info[plane].byte_stride, stride_align); in calc_allocation_size()
533 plane_info[plane].alloc_width = plane_info[plane].byte_stride * 8 / format.bpp[plane]; in calc_allocation_size()
555 ALOGV("Byte stride: %d", plane_info[plane].byte_stride); in calc_allocation_size()
561 if (plane == 0) in calc_allocation_size()
563 assert((plane_info[plane].byte_stride * 8) % format.bpp[plane] == 0); in calc_allocation_size()
564 ALOGV("Pixel stride: %d", (plane_info[plane].byte_stride * 8) / format.bpp[plane]); in calc_allocation_size()
567 const uint32_t sb_num = (plane_info[plane].alloc_width * plane_info[plane].alloc_height) in calc_allocation_size()
576 const rect_t sb = get_afbc_sb_size(alloc_type, plane); in calc_allocation_size()
577 const int sb_bytes = GRALLOC_ALIGN((format.bpp_afbc[plane] * sb.width * sb.height) / 8, 128); in calc_allocation_size()
582 if (format.npln > 1 && plane < 2) in calc_allocation_size()
596 body_size = (plane_info[plane].byte_stride) * plane_info[plane].alloc_height; in calc_allocation_size()
618 if (plane > 0) in calc_allocation_size()
620 plane_info[plane].offset = *size; in calc_allocation_size()