Lines Matching refs:width
103 static void get_rgb_stride_and_size(int width, int height, int pixel_size, int *pixel_stride, int *… in get_rgb_stride_and_size() argument
108 stride = width * pixel_size; in get_rgb_stride_and_size()
138 w_aligned = GRALLOC_ALIGN(width, AFBC_TILED_HEADERS_BASIC_WIDTH_ALIGN); in get_rgb_stride_and_size()
144 w_aligned = GRALLOC_ALIGN(width, AFBC_TILED_HEADERS_WIDEBLK_WIDTH_ALIGN); in get_rgb_stride_and_size()
150 w_aligned = GRALLOC_ALIGN(width, 64); in get_rgb_stride_and_size()
154 w_aligned = GRALLOC_ALIGN(width, AFBC_WIDEBLK_WIDTH_ALIGN); in get_rgb_stride_and_size()
159 w_aligned = GRALLOC_ALIGN(width, AFBC_NORMAL_WIDTH_ALIGN); in get_rgb_stride_and_size()
197 static bool get_afbc_yuv420_8bit_stride_and_size(int width, int height, int *pixel_stride, int *byt… in get_afbc_yuv420_8bit_stride_and_size() argument
226 width = GRALLOC_ALIGN(width, AFBC_TILED_HEADERS_BASIC_WIDTH_ALIGN); in get_afbc_yuv420_8bit_stride_and_size()
232 width = GRALLOC_ALIGN(width, AFBC_TILED_HEADERS_WIDEBLK_WIDTH_ALIGN); in get_afbc_yuv420_8bit_stride_and_size()
243 width = GRALLOC_ALIGN(width, AFBC_WIDEBLK_WIDTH_ALIGN); in get_afbc_yuv420_8bit_stride_and_size()
248 width = GRALLOC_ALIGN(width, AFBC_NORMAL_WIDTH_ALIGN); in get_afbc_yuv420_8bit_stride_and_size()
252 yuv420_afbc_luma_stride = width; in get_afbc_yuv420_8bit_stride_and_size()
257 int nblocks = width / AFBC_PIXELS_PER_BLOCK * height / AFBC_PIXELS_PER_BLOCK; in get_afbc_yuv420_8bit_stride_and_size()
289 static bool get_yv12_stride_and_size(int width, int height, int *pixel_stride, int *byte_stride, si… in get_yv12_stride_and_size() argument
296 return get_afbc_yuv420_8bit_stride_and_size(width, height, pixel_stride, byte_stride, size, type, in get_yv12_stride_and_size()
304 luma_stride = GRALLOC_ALIGN(width, stride_alignment); in get_yv12_stride_and_size()
336 static bool get_yuv422_8bit_stride_and_size(int width, int height, int *pixel_stride, int *byte_str… in get_yuv422_8bit_stride_and_size() argument
343 local_pixel_stride = GRALLOC_ALIGN(width, YUV_MALI_PLANE_ALIGN); in get_yuv422_8bit_stride_and_size()
344 local_byte_stride = GRALLOC_ALIGN(width * 2, YUV_MALI_PLANE_ALIGN); /* 4 bytes per 2 pixels */ in get_yuv422_8bit_stride_and_size()
375 static bool get_afbc_yuv422_8bit_stride_and_size(int width, int height, int *pixel_stride, int *byt… in get_afbc_yuv422_8bit_stride_and_size() argument
388 width = GRALLOC_ALIGN(width, AFBC_TILED_HEADERS_BASIC_WIDTH_ALIGN); in get_afbc_yuv422_8bit_stride_and_size()
394 width = GRALLOC_ALIGN(width, AFBC_TILED_HEADERS_WIDEBLK_WIDTH_ALIGN); in get_afbc_yuv422_8bit_stride_and_size()
405 width = GRALLOC_ALIGN(width, AFBC_WIDEBLK_WIDTH_ALIGN); in get_afbc_yuv422_8bit_stride_and_size()
410 width = GRALLOC_ALIGN(width, AFBC_NORMAL_WIDTH_ALIGN); in get_afbc_yuv422_8bit_stride_and_size()
414 yuv422_afbc_luma_stride = width; in get_afbc_yuv422_8bit_stride_and_size()
418 int nblocks = width / AFBC_PIXELS_PER_BLOCK * height / AFBC_PIXELS_PER_BLOCK; in get_afbc_yuv422_8bit_stride_and_size()
454 static bool get_yuv_pX10_stride_and_size(int width, int height, int vss, int *pixel_stride, int *by… in get_yuv_pX10_stride_and_size() argument
473 luma_pixel_stride = GRALLOC_ALIGN(width, YUV_MALI_PLANE_ALIGN); in get_yuv_pX10_stride_and_size()
474 luma_byte_stride = GRALLOC_ALIGN(width * 2, YUV_MALI_PLANE_ALIGN); in get_yuv_pX10_stride_and_size()
478 int chroma_size = GRALLOC_ALIGN(width * 2, YUV_MALI_PLANE_ALIGN) * (height / vss); in get_yuv_pX10_stride_and_size()
510 static bool get_yuv_y210_stride_and_size(int width, int height, int *pixel_stride, int *byte_stride… in get_yuv_y210_stride_and_size() argument
517 y210_pixel_stride = GRALLOC_ALIGN(width, YUV_MALI_PLANE_ALIGN); in get_yuv_y210_stride_and_size()
519 y210_byte_stride = GRALLOC_ALIGN(width * 4, YUV_MALI_PLANE_ALIGN); in get_yuv_y210_stride_and_size()
557 static bool get_yuv_y0l2_stride_and_size(int width, int height, int *pixel_stride, int *byte_stride… in get_yuv_y0l2_stride_and_size() argument
565 y0l2_pixel_stride = GRALLOC_ALIGN(width, YUV_MALI_PLANE_ALIGN); in get_yuv_y0l2_stride_and_size()
566 …y0l2_byte_stride = GRALLOC_ALIGN(width * 4, YUV_MALI_PLANE_ALIGN); /* 2 horiz pixels per 8 byte cl… in get_yuv_y0l2_stride_and_size()
601 static bool get_yuv_y410_stride_and_size(int width, int height, int *pixel_stride, int *byte_stride… in get_yuv_y410_stride_and_size() argument
605 y410_pixel_stride = GRALLOC_ALIGN(width, YUV_MALI_PLANE_ALIGN); in get_yuv_y410_stride_and_size()
606 y410_byte_stride = GRALLOC_ALIGN(width * 4, YUV_MALI_PLANE_ALIGN); in get_yuv_y410_stride_and_size()
645 static bool get_yuv420_10bit_afbc_stride_and_size(int width, int height, int *pixel_stride, int *by… in get_yuv420_10bit_afbc_stride_and_size() argument
651 if (width & 3) in get_yuv420_10bit_afbc_stride_and_size()
673 width = GRALLOC_ALIGN(width, AFBC_TILED_HEADERS_BASIC_WIDTH_ALIGN); in get_yuv420_10bit_afbc_stride_and_size()
679 width = GRALLOC_ALIGN(width, AFBC_TILED_HEADERS_WIDEBLK_WIDTH_ALIGN); in get_yuv420_10bit_afbc_stride_and_size()
690 width = GRALLOC_ALIGN(width, AFBC_WIDEBLK_WIDTH_ALIGN); in get_yuv420_10bit_afbc_stride_and_size()
695 width = GRALLOC_ALIGN(width, AFBC_NORMAL_WIDTH_ALIGN); in get_yuv420_10bit_afbc_stride_and_size()
699 yuv420_afbc_pixel_stride = GRALLOC_ALIGN(width, 16); in get_yuv420_10bit_afbc_stride_and_size()
700 …yuv420_afbc_byte_stride = GRALLOC_ALIGN(width * 4, 16); /* 64-bit packed and horizontally downsamp… in get_yuv420_10bit_afbc_stride_and_size()
704 int nblocks = width / AFBC_PIXELS_PER_BLOCK * (*internalHeight) / AFBC_PIXELS_PER_BLOCK; in get_yuv420_10bit_afbc_stride_and_size()
738 static bool get_yuv422_10bit_afbc_stride_and_size(int width, int height, int *pixel_stride, int *by… in get_yuv422_10bit_afbc_stride_and_size() argument
744 if (width & 3) in get_yuv422_10bit_afbc_stride_and_size()
756 width = GRALLOC_ALIGN(width, AFBC_TILED_HEADERS_BASIC_WIDTH_ALIGN); in get_yuv422_10bit_afbc_stride_and_size()
762 width = GRALLOC_ALIGN(width, AFBC_TILED_HEADERS_WIDEBLK_WIDTH_ALIGN); in get_yuv422_10bit_afbc_stride_and_size()
773 width = GRALLOC_ALIGN(width, AFBC_WIDEBLK_WIDTH_ALIGN); in get_yuv422_10bit_afbc_stride_and_size()
778 width = GRALLOC_ALIGN(width, AFBC_NORMAL_WIDTH_ALIGN); in get_yuv422_10bit_afbc_stride_and_size()
782 yuv422_afbc_pixel_stride = GRALLOC_ALIGN(width, 16); in get_yuv422_10bit_afbc_stride_and_size()
783 yuv422_afbc_byte_stride = GRALLOC_ALIGN(width * 2, 16); in get_yuv422_10bit_afbc_stride_and_size()
787 int nblocks = width / AFBC_PIXELS_PER_BLOCK * height / AFBC_PIXELS_PER_BLOCK; in get_yuv422_10bit_afbc_stride_and_size()
900 bufDescriptor->internalWidth = bufDescriptor->width; in mali_gralloc_buffer_allocate()
905 …bufDescriptor->hal_format, bufDescriptor->format_type, usage, bufDescriptor->width * bufDescriptor… in mali_gralloc_buffer_allocate()
954 …get_rgb_stride_and_size(bufDescriptor->width, bufDescriptor->height, 4, &bufDescriptor->pixel_stri… in mali_gralloc_buffer_allocate()
959 …get_rgb_stride_and_size(bufDescriptor->width, bufDescriptor->height, 3, &bufDescriptor->pixel_stri… in mali_gralloc_buffer_allocate()
964 …get_rgb_stride_and_size(bufDescriptor->width, bufDescriptor->height, 2, &bufDescriptor->pixel_stri… in mali_gralloc_buffer_allocate()
983 …if (!get_yv12_stride_and_size(bufDescriptor->width, bufDescriptor->height, &bufDescriptor->pixel_s… in mali_gralloc_buffer_allocate()
997 !get_yuv422_8bit_stride_and_size(bufDescriptor->width, bufDescriptor->height, in mali_gralloc_buffer_allocate()
1016 get_camera_formats_stride_and_size(bufDescriptor->width, bufDescriptor->height, base_format, in mali_gralloc_buffer_allocate()
1028 bufDescriptor->width, bufDescriptor->height, &bufDescriptor->pixel_stride, in mali_gralloc_buffer_allocate()
1036 if (!get_yuv_y0l2_stride_and_size(bufDescriptor->width, bufDescriptor->height, in mali_gralloc_buffer_allocate()
1050 !get_yuv_pX10_stride_and_size(bufDescriptor->width, bufDescriptor->height, 2, in mali_gralloc_buffer_allocate()
1063 !get_yuv_pX10_stride_and_size(bufDescriptor->width, bufDescriptor->height, 1, in mali_gralloc_buffer_allocate()
1077 if (!get_yuv422_10bit_afbc_stride_and_size(bufDescriptor->width, bufDescriptor->height, in mali_gralloc_buffer_allocate()
1086 if (!get_yuv_y210_stride_and_size(bufDescriptor->width, bufDescriptor->height, in mali_gralloc_buffer_allocate()
1100 …!get_yuv_y410_stride_and_size(bufDescriptor->width, bufDescriptor->height, &bufDescriptor->pixel_s… in mali_gralloc_buffer_allocate()
1115 if (!get_afbc_yuv422_8bit_stride_and_size(bufDescriptor->width, bufDescriptor->height, in mali_gralloc_buffer_allocate()