/packages/apps/Car/libs/car-apps-common/src/com/android/car/apps/common/ |
D | BitmapUtils.java | 51 if (bm == null || (bm.getHeight() == height && bm.getWidth() == width)) { in scaleBitmap() 56 if (bm.getHeight() > height) { in scaleBitmap() 57 heightScale = (float) height / bm.getHeight(); in scaleBitmap() 65 int scaleHeight = (int) Math.ceil(bm.getHeight() * scale); in scaleBitmap() 98 if (bm.getHeight() < height || bm.getWidth() < width) { in cropBitmap() 102 bm.getWidth(), bm.getHeight(), width, height)); in cropBitmap() 107 int y =(bm.getHeight() - height) / 2; in cropBitmap() 115 Bitmap clone = Bitmap.createBitmap(image.getWidth(), image.getHeight(), ARGB_8888); in createTintedBitmap() 149 drawable.setBounds(0, 0, bitmapSize.getWidth(), bitmapSize.getHeight()); in fromDrawable() 157 RectF dstR = new RectF(0f, 0f, bitmapSize.getWidth(), bitmapSize.getHeight()); in fromDrawable() [all …]
|
D | ImageUtils.java | 69 || image.getHeight() > bitmapTargetSize.getHeight()) { in maybeResize() 73 int height = Math.round(scale * image.getHeight()); in maybeResize() 81 return (size.getWidth() + size.getHeight()) / 2; in getAverage() 85 return (image.getWidth() + image.getHeight()) / 2; in getBitmapDimension()
|
/packages/apps/WallpaperPicker2/src/com/android/wallpaper/util/ |
D | BitmapTransformer.java | 44 int verticalOffset = (bitmap.getHeight() - resultBitmap.getHeight()) / 2; in applyFillTransformation() 51 * Math.min(resultBitmap.getHeight(), bitmap.getHeight()); in applyFillTransformation() 62 Math.min(resultBitmap.getHeight(), bitmap.getHeight()) /* height */); in applyFillTransformation() 72 Math.min(resultBitmap.getHeight(), bitmap.getHeight()) /* height */); in applyFillTransformation()
|
/packages/apps/Dialer/java/com/android/dialer/contactsfragment/ |
D | FastScroller.java | 106 } else if (scrollBar.getY() + scrollBar.getHeight() >= getHeight()) { in getScrolledPercentage() 109 return y / (float) getHeight(); in getScrolledPercentage() 122 float proportion = (float) verticalScrollOffset / ((float) verticalScrollRange - getHeight()); in updateContainerAndScrollBarPosition() 123 setContainerAndScrollBarPosition(getHeight() * proportion); in updateContainerAndScrollBarPosition() 128 int scrollBarHeight = scrollBar.getHeight(); in setContainerAndScrollBarPosition() 129 int containerHeight = container.getHeight(); in setContainerAndScrollBarPosition() 131 getValueInRange(0, getHeight() - scrollBarHeight, (int) (y - scrollBarHeight / 2))); in setContainerAndScrollBarPosition() 134 0, getHeight() - containerHeight - scrollBarHeight / 2, (int) (y - containerHeight))); in setContainerAndScrollBarPosition()
|
/packages/apps/TV/tuner/tests/unittests/javatests/com/android/tv/tuner/layout/tests/ |
D | ScaledLayoutTest.java | 68 assertEquals((int) (300 * 0.2), view1.getHeight()); in testScaledLayout_layoutInXml() 72 assertEquals(300, view2.getHeight()); in testScaledLayout_layoutInXml() 76 assertEquals((int) (300 * 0.1), view3.getHeight()); in testScaledLayout_layoutInXml() 80 assertEquals((int) (300 * 0.8), view4.getHeight()); in testScaledLayout_layoutInXml() 102 assertEquals(50, view1.getHeight()); in testScaledLayout_layoutThroughCode() 106 assertEquals(50, view2.getHeight()); in testScaledLayout_layoutThroughCode() 110 assertEquals(50, view3.getHeight()); in testScaledLayout_layoutThroughCode() 114 assertEquals(50, view4.getHeight()); in testScaledLayout_layoutThroughCode() 132 assertEquals(20, view1.getHeight()); in testScaledLayout_bounceY() 136 assertEquals(20, view2.getHeight()); in testScaledLayout_bounceY()
|
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/imageshow/ |
D | ImageShow.java | 126 Bitmap a = Bitmap.createBitmap(b.getWidth(), b.getHeight(), Bitmap.Config.ALPHA_8); in convertToAlphaMask() 230 primary.getOriginalBounds(), getWidth(), getHeight()); in getImageToScreenMatrix() 234 m.postScale(scaleFactor, scaleFactor, getWidth() / 2.0f, getHeight() / 2.0f); in getImageToScreenMatrix() 262 getHeight() - 2*mShadowMargin); in onDraw() 299 float dx = (getHeight() - getWidth()) / 2f; in onDraw() 300 if (getWidth() > getHeight()) { in onDraw() 301 dx = - (getWidth() - getHeight()) / 2f; in onDraw() 304 canvas.rotate(180, getWidth()/2, getHeight()/2); in onDraw() 306 canvas.rotate(90, getWidth()/2, getHeight()/2); in onDraw() 309 canvas.rotate(270, getWidth()/2, getHeight()/2); in onDraw() [all …]
|
D | ImageCrop.java | 234 int height = image.getHeight(); in forceStateConsistency() 265 mImageBounds.set(0, 0, bitmap.getWidth(), bitmap.getHeight()); in onDraw() 270 bitmap.getWidth(), bitmap.getHeight(), canvas.getWidth(), canvas.getHeight()); in onDraw() 274 bitmap.getWidth(), bitmap.getHeight(), canvas.getWidth(), canvas.getHeight()); in onDraw() 291 int delta = Math.min(canvas.getWidth(), canvas.getHeight()) / 4; in onDraw() 313 bitmap.getHeight()); in onDraw()
|
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/category/ |
D | IconView.java | 111 int y = canvas.getHeight() - 2*mMargin; in drawText() 182 getHeight() - mTextSize - 2*mMargin); in computeBitmapBounds() 185 mBitmapBounds = new Rect(mMargin/2, mMargin, getWidth()/2, getHeight()); in computeBitmapBounds() 187 mBitmapBounds = new Rect(mMargin/2, mMargin, getWidth() - mMargin/2, getHeight()); in computeBitmapBounds() 206 m.setRectToRect(new RectF(0, 0, mBitmap.getWidth(), mBitmap.getHeight()), in onDraw() 210 float scaleHeight = mBitmapBounds.height() / (float) mBitmap.getHeight(); in onDraw() 213 float dy = (mBitmapBounds.height() - (mBitmap.getHeight() * scale)) / 2f; in onDraw() 227 float start = getHeight() - 2 * mMargin - 2 * mTextSize; in onDraw() 228 float end = getHeight(); in onDraw()
|
D | Action.java | 162 int minSide = Math.min(destination.getWidth(), destination.getHeight()); in drawCenteredImage() 164 float scaleFactor = minSide / (float) Math.min(source.getWidth(), source.getHeight()); in drawCenteredImage() 167 float dy = (destination.getHeight() - source.getHeight() * scaleFactor) / 2.0f; in drawCenteredImage() 195 new Rect(0, 0, mOverlayBitmap.getWidth(), mOverlayBitmap.getHeight()), in available() 196 new Rect(0, 0, mImage.getWidth(), mImage.getHeight()), new Paint()); in available()
|
/packages/apps/Gallery/src/com/android/camera/ |
D | ImageViewTouchBase.java | 195 mBitmapDisplayed.getBitmap().getHeight()); in center() 205 int viewHeight = getHeight(); in center() 211 deltaY = getHeight() - rect.bottom; in center() 261 float viewHeight = getHeight(); in getProperBaseMatrix() 264 float h = bitmap.getHeight(); in getProperBaseMatrix() 302 float fh = (float) mBitmapDisplayed.getHeight() / (float) mThisHeight; in maxZoom() 342 float cy = getHeight() / 2F; in zoomTo() 349 float cy = getHeight() / 2F; in zoomToPoint() 372 float cy = getHeight() / 2F; in zoomIn() 384 float cy = getHeight() / 2F; in zoomOut()
|
D | RotateBitmap.java | 61 int cy = mBitmap.getHeight() / 2; in getRotateMatrix() 64 matrix.postTranslate(getWidth() / 2, getHeight() / 2); in getRotateMatrix() 73 public int getHeight() { in getHeight() method in RotateBitmap 77 return mBitmap.getHeight(); in getHeight() 83 return mBitmap.getHeight(); in getWidth()
|
/packages/apps/ManagedProvisioning/tests/instrumentation/src/com/android/managedprovisioning/common/ |
D | LogoUtilsTest.java | 43 assertEquals(15, newBitmap.getHeight()); in testPartiallyResizedBitmap() 57 assertEquals(8, newBitmap.getHeight()); in testPartiallyResizedElongatedBitmap() 69 assertEquals(8, newBitmap.getHeight()); in testResizeBitmapKeepRatio() 79 assertEquals(32, newBitmap.getHeight()); in testResizeBitmapNoScalingNeeded() 87 assertEquals(10, newBitmap.getHeight()); in testResizeBitmapNoIntegerRatio() 129 assertEquals(b1.getHeight(), b2.getHeight()); in assertBitmapEquals() 131 for (int y = 0; y < b1.getHeight(); y++) { in assertBitmapEquals()
|
/packages/services/BuiltInPrintService/src/com/android/bips/ |
D | ImageToPdfTask.java | 78 if (mAttributes.getMediaSize().isPortrait() == mBitmap.getWidth() < mBitmap.getHeight()) { in writeBitmapToDocument() 93 scale = Math.max(extent.height() / POINTS_PER_INCH * mDpi / mBitmap.getHeight(), in writeBitmapToPage() 99 extent.width() / POINTS_PER_INCH * mDpi / mBitmap.getHeight()); in writeBitmapToPage() 118 scale = Math.max(extent.height() / mBitmap.getHeight(), in drawDirect() 122 extent.width() / mBitmap.getHeight()); in drawDirect() 126 float offsetY = (extent.height() - mBitmap.getHeight() * scale) / 2; in drawDirect() 130 matrix.postRotate(90, mBitmap.getWidth() / 2, mBitmap.getHeight() / 2); in drawDirect() 145 float offsetY = ((targetHeight / scale) - mBitmap.getHeight()) / 2; in drawOptimized()
|
/packages/apps/Camera2/src/com/android/camera/one/v2/camera2proxy/ |
D | ForwardingImageProxy.java | 68 public int getHeight() { in getHeight() method in ForwardingImageProxy 69 return mImpl.getHeight(); in getHeight() 109 .add("height", getHeight()) in toString() 124 otherImage.getHeight() == getHeight() && in equals() 130 return Objects.hashCode(getFormat(), getWidth(), getHeight(), getTimestamp()); in hashCode()
|
D | AndroidImageProxy.java | 108 mHeight = mImage.getHeight(); in AndroidImageProxy() 167 public int getHeight() { in getHeight() method in AndroidImageProxy 211 .add("height", getHeight()) in toString() 226 otherImage.getHeight() == getHeight() && in equals() 232 return Objects.hashCode(getFormat(), getWidth(), getHeight(), getTimestamp()); in hashCode()
|
/packages/apps/Contacts/src/com/android/contacts/widget/ |
D | MultiShrinkScroller.java | 349 mMaximumPortraitHeaderHeight = mIsTwoPanel ? getHeight() in initialize() 353 mMaximumHeaderTextSize = mTitleAndPhoneticNameView.getHeight(); in initialize() 354 mMaximumFullNameViewHeight = mFullNameView.getHeight(); in initialize() 367 mMaximumHeaderHeight = getHeight(); in initialize() 538 EdgeEffectCompat.onPull(mEdgeGlowBottom, delta / getHeight(), in onTouchEvent() 691 final float heightRatio = (float) transparentHeight / getHeight(); in getTransparentHeightRatio() 722 - (getHeight() - getTransparentViewHeight()) + 1; in scrollUpForEntranceAnimation() 854 return getHeight() + getScroll_ignoreOversizedHeaderForSnapping() in getScrollUntilOffBottom() 893 final int height = getHeight(); in draw() 951 if (velocity < 0 && mTransparentView.getHeight() <= 0) { in fling() [all …]
|
/packages/apps/DevCamera/src/com/android/devcamera/ |
D | Api2Camera.java | 203 mCameraInfoCache.getYuvStream1Size().getHeight(), in InitializeAllTheThings() 211 mCameraInfoCache.getYuvStream1Size().getHeight(), in InitializeAllTheThings() 219 mCameraInfoCache.getDepthCloudSize().getHeight(), in InitializeAllTheThings() 228 mCameraInfoCache.getYuvStream2Size().getHeight(), in InitializeAllTheThings() 262 mCameraInfoCache.getRawStreamSize().getHeight(), in InitializeAllTheThings() 409 " x " + mCameraInfoCache.getPreviewSize().getHeight()); in startCaptureSession() 413 " x " + mCameraInfoCache.getYuvStream1Size().getHeight()); in startCaptureSession() 423 " x " + mCameraInfoCache.getYuvStream2Size().getHeight()); in startCaptureSession() 434 " x " + mCameraInfoCache.getRawStreamSize().getHeight()); in startCaptureSession() 440 " x " + mCameraInfoCache.getJpegStreamSize().getHeight()); in startCaptureSession() [all …]
|
/packages/apps/WallpaperPicker/src/com/android/photos/ |
D | BitmapRegionTileSource.java | 46 int getHeight(); in getHeight() method 72 public int getHeight() { in getHeight() method in SimpleBitmapRegionDecoderWrapper 73 return mDecoder.getHeight(); in getHeight() 97 public int getHeight() { in getHeight() method in DumbBitmapRegionDecoder 98 return mBuffer.getHeight(); in getHeight() 151 int height = mDecoder.getHeight(); in loadInBackground() 308 mHeight = mDecoder.getHeight(); in BitmapRegionTileSource() 316 preview.getWidth() <= GL_SIZE_LIMIT && preview.getHeight() <= GL_SIZE_LIMIT) { in BitmapRegionTileSource() 324 preview == null ? -1 : preview.getHeight())); in BitmapRegionTileSource()
|
/packages/apps/TV/src/com/android/tv/util/images/ |
D | BitmapUtils.java | 74 final double bmRatio = bm.getHeight() / (double) bm.getWidth(); in calculateNewSize() 78 rect.bottom = Math.round((float) bm.getHeight() * maxWidth / bm.getWidth()); in calculateNewSize() 80 rect.right = Math.round((float) bm.getWidth() * maxHeight / bm.getHeight()); in calculateNewSize() 91 calculateInSampleSize(bm.getWidth(), bm.getHeight(), maxWidth, maxHeight)); in createScaledBitmapInfo() 102 drawable.setBounds(0, 0, canvas.getWidth(), canvas.getHeight()); in drawableToBitmap() 259 (size.right >= bitmap.getWidth() * 2 || size.bottom >= bitmap.getHeight() * 2); in needToReload() 279 return needToReload(other.bitmap.getWidth(), other.bitmap.getHeight()); in needToReload() 291 + bitmap.getHeight() in toString()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/wifi/qrcode/ |
D | QrCameraTest.java | 119 final int[] intArray = new int[bmp.getWidth() * bmp.getHeight()]; in testDecode_PictureCaptured_QrCodeCorrectValue() 120 bmp.getPixels(intArray, 0, bmp.getWidth(), 0, 0, bmp.getWidth(), bmp.getHeight()); in testDecode_PictureCaptured_QrCodeCorrectValue() 121 LuminanceSource source = new RGBLuminanceSource(bmp.getWidth(), bmp.getHeight(), in testDecode_PictureCaptured_QrCodeCorrectValue() 138 final int[] intArray = new int[bmp.getWidth() * bmp.getHeight()]; in testDecode_unicodePictureCaptured_QrCodeCorrectValue() 139 bmp.getPixels(intArray, 0, bmp.getWidth(), 0, 0, bmp.getWidth(), bmp.getHeight()); in testDecode_unicodePictureCaptured_QrCodeCorrectValue() 140 LuminanceSource source = new RGBLuminanceSource(bmp.getWidth(), bmp.getHeight(), in testDecode_unicodePictureCaptured_QrCodeCorrectValue()
|
/packages/apps/WallpaperPicker2/src/com/android/wallpaper/asset/ |
D | Asset.java | 61 int height = view.getHeight() > 0 ? view.getHeight() in getViewDimensions() 149 int height = imageView.getHeight() > 0 in loadDrawable() 150 ? imageView.getHeight() in loadDrawable() 301 int bitmapHeight = mBitmap.getHeight(); in doInBackground() 312 int verticalGutterPx = Math.max(0, (scaledBitmap.getHeight() - measuredHeight) / 2); in doInBackground() 319 scaledBitmap.getHeight() - (2 * verticalGutterPx)); in doInBackground()
|
/packages/apps/Settings/src/com/android/settings/wifi/qrcode/ |
D | QrCamera.java | 177 mParameters.setPreviewSize(mPreviewSize.getWidth(), mPreviewSize.getHeight()); in setCameraParameter() 179 mParameters.setPreviewSize(pictureSize.getWidth(), pictureSize.getHeight()); in setCameraParameter() 325 final int viewRatio = (int)getRatio(viewSize.getWidth(), viewSize.getHeight()); in setTransformationMatrix() 330 final int previewWidth = isPortrait ? mPreviewSize.getWidth() : mPreviewSize.getHeight(); in setTransformationMatrix() 331 final int previewHeight = isPortrait ? mPreviewSize.getHeight() : mPreviewSize.getWidth(); in setTransformationMatrix() 352 mPreviewSize.getWidth(), mPreviewSize.getHeight()); in getFrameImage() 377 final double winRatio = getRatio(windowSize.getWidth(), windowSize.getHeight()); in getBestPreviewSize() 382 if (size.height * size.width > bestChoice.getWidth() * bestChoice.getHeight() in getBestPreviewSize() 425 int areaDifference = Math.abs(size.getWidth() * size.getHeight() - previewArea); in getBestPictureSize()
|
/packages/apps/Gallery2/src/com/android/gallery3d/ui/ |
D | ProgressSpinner.java | 42 mHeight = Math.max(mOuter.getHeight(), mInner.getHeight()); in ProgressSpinner() 49 public int getHeight() { in getHeight() method in ProgressSpinner 75 mOuter.draw(canvas, -mOuter.getWidth() / 2, -mOuter.getHeight() / 2); in draw() 77 mInner.draw(canvas, -mInner.getWidth() / 2, -mInner.getHeight() / 2); in draw()
|
/packages/apps/Camera2/src/com/android/camera/ |
D | CaptureModuleUtil.java | 73 if (s.getHeight() <= MAX_ASPECT_HEIGHT) { in getOptimalPreviewSize() 81 if (s.getHeight() <= MAX_ASPECT_HEIGHT) { in getOptimalPreviewSize() 82 camera1Sizes.add(new Size(s.getWidth(), s.getHeight())); in getOptimalPreviewSize() 96 if (s.getWidth() == optimal.getWidth() && s.getHeight() == optimal.getHeight()) { in getOptimalPreviewSize()
|
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/crop/ |
D | CropActivity.java | 206 if (bitmap != null && bitmap.getWidth() != 0 && bitmap.getHeight() != 0) { in doneLoadBitmap() 207 RectF imgBounds = new RectF(0, 0, bitmap.getWidth(), bitmap.getHeight()); in doneLoadBitmap() 309 RectF photo = new RectF(0, 0, mOriginalBitmap.getWidth(), mOriginalBitmap.getHeight()); in startFinishOutput() 325 || currentBitmap.getWidth() == 0 || currentBitmap.getHeight() == 0 in startBitmapIO() 453 ret.getHeight(), m, true); in doInBackground() 518 RectF cropRect = new RectF(0, 0, crop.getWidth(), crop.getHeight()); in doInBackground() 537 crop.getHeight(), m, true); in doInBackground() 618 RectF imageBounds = new RectF(0, 0, image.getWidth(), image.getHeight()); in getCroppedImage() 630 if (image == null || image.getWidth() == 0 || image.getHeight() == 0 || max_size < 16) { in getDownsampledBitmap() 640 image.getHeight() >> shifts, true); in getDownsampledBitmap() [all …]
|