Lines Matching refs:width
176 aligned_w = hnd->width;
216 void AdrenoMemInfo::getAlignedWidthAndHeight(int width, int height, int format,
224 getGpuAlignedWidthHeight(width, height, format, tileEnabled, aligned_w, aligned_h);
226 getYuvUBwcWidthHeight(width, height, format, aligned_w, aligned_h);
228 aligned_w = width;
238 aligned_w = ALIGN(width, alignment);
241 aligned_w = ALIGN(width, alignment);
244 aligned_w = ALIGN(width, 16);
247 aligned_w = ALIGN(width * 10 / 8, 8);
250 aligned_w = ALIGN(width, 128);
257 aligned_w = ALIGN(width, 16);
261 aligned_w = VENUS_Y_STRIDE(COLOR_FMT_NV12, width);
265 aligned_w = VENUS_Y_STRIDE(COLOR_FMT_NV21, width);
272 aligned_w = ALIGN(width, 64);
310 width, height, format, 0,raster_mode, padding_threshold,
323 void AdrenoMemInfo::getGpuAlignedWidthHeight(int width, int height, int format,
326 aligned_w = ALIGN(width, 32);
356 // the function below computes aligned width and aligned height
359 LINK_adreno_compute_aligned_width_and_height(width,
366 aligned_w = LINK_adreno_compute_padding(width, bpp,
549 unsigned int getSize(int format, int width, int height, int usage,
553 return getUBwcSize(width, height, format, alignedw, alignedh);
588 size += ALIGN(2 * ALIGN(width/2, 32) * ALIGN(height/2, 32), 4096);
598 if ((format == HAL_PIXEL_FORMAT_YV12) && ((width&1) || (height&1))) {
614 if(width & 1) {
615 ALOGE("width is odd for the YUV422_SP format");
622 size = VENUS_BUFFER_SIZE(COLOR_FMT_NV12, width, height);
625 size = VENUS_BUFFER_SIZE(COLOR_FMT_NV21, width, height);
634 size = width;
676 unsigned int getBufferSizeAndDimensions(int width, int height, int format,
681 AdrenoMemInfo::getInstance().getAlignedWidthAndHeight(width,
688 size = getSize(format, width, height, 0 /* usage */, alignedw, alignedh);
694 unsigned int getBufferSizeAndDimensions(int width, int height, int format,
699 AdrenoMemInfo::getInstance().getAlignedWidthAndHeight(width,
706 size = getSize(format, width, height, usage, alignedw, alignedh);
712 void getBufferAttributes(int width, int height, int format, int usage,
717 AdrenoMemInfo::getInstance().getAlignedWidthAndHeight(width,
723 size = getSize(format, width, height, usage, alignedw, alignedh);
726 void getYuvUbwcSPPlaneInfo(uint64_t base, int width, int height,
736 y_meta_stride = VENUS_Y_META_STRIDE(color_format, width);
740 y_stride = VENUS_Y_STRIDE(color_format, width);
744 c_meta_stride = VENUS_UV_META_STRIDE(color_format, width);
753 ycbcr->cstride = VENUS_UV_STRIDE(color_format, width);
756 void getYuvSPPlaneInfo(uint64_t base, int width, int height, int bpp,
761 ystride = cstride = width * bpp;
773 int width = hnd->width;
796 metadata->bufferDim.sliceHeight, format, usage, width, height);
799 // Get the chroma offsets from the handle width/height. We take advantage
800 // of the fact the width _is_ the stride
807 getYuvSPPlaneInfo(hnd->base, width, height, 1, ycbcr);
811 getYuvSPPlaneInfo(hnd->base, width, height, 2, ycbcr);
815 getYuvUbwcSPPlaneInfo(hnd->base, width, height,
821 getYuvUbwcSPPlaneInfo(hnd->base, width, height,
833 getYuvSPPlaneInfo(hnd->base, width, height, 1, ycbcr);
839 ystride = width;
840 cstride = ALIGN(width/2, 16);
863 // Allocate buffer from width, height and format into a
984 static void getYuvUBwcWidthHeight(int width, int height, int format,
992 aligned_w = VENUS_Y_STRIDE(COLOR_FMT_NV12_UBWC, width);
996 aligned_w = VENUS_Y_STRIDE(COLOR_FMT_NV12_BPP10_UBWC, width);
1033 static unsigned int getRgbUBwcMetaBufferSize(int width, int height, int bpp)
1049 // Align meta buffer width to 64 blocks
1050 meta_width = ALIGN(((width + block_width - 1) / block_width), 64);
1057 static unsigned int getUBwcSize(int width, int height, int format,
1064 size += getRgbUBwcMetaBufferSize(width, height, 2);
1071 size += getRgbUBwcMetaBufferSize(width, height, 4);
1076 size = VENUS_BUFFER_SIZE(COLOR_FMT_NV12_UBWC, width, height);
1079 size = VENUS_BUFFER_SIZE(COLOR_FMT_NV12_BPP10_UBWC, width, height);
1106 meta_size = getRgbUBwcMetaBufferSize(hnd->width, hnd->height, 2);
1110 meta_size = getRgbUBwcMetaBufferSize(hnd->width, hnd->height, 4);