/packages/apps/WallpaperPicker2/src/com/android/wallpaper/util/ |
D | BitmapTransformer.java | 43 int horizontalOffset = (bitmap.getWidth() - resultBitmap.getWidth()) / 2; in applyFillTransformation() 50 int pixelArraySize = Math.min(resultBitmap.getWidth(), bitmap.getWidth()) in applyFillTransformation() 58 bitmap.getWidth() /* stride */, in applyFillTransformation() 61 Math.min(resultBitmap.getWidth(), bitmap.getWidth()) /* width */, in applyFillTransformation() 68 bitmap.getWidth() /* stride */, in applyFillTransformation() 71 Math.min(resultBitmap.getWidth(), bitmap.getWidth()) /* width */, in applyFillTransformation()
|
/packages/apps/Gallery2/src/com/android/gallery3d/app/ |
D | TrimTimeBar.java | 80 return mTrimStartScrubber.getWidth() * 3 / 4; in trimStartScrubberTipOffset() 84 return mTrimEndScrubber.getWidth() / 4; in trimEndScrubberTipOffset() 97 mScrubberLeft = mPlayedBar.right - mScrubber.getWidth() / 2; in updatePlayedBarAndScrubberFromTime() 106 mScrubberLeft = mProgressBar.left - mScrubber.getWidth() / 2; in updatePlayedBarAndScrubberFromTime() 150 int scrubberRight = startX + scrubber.getWidth(); in inScrubber() 173 int margin = mScrubber.getWidth() / 3; in onLayout() 203 getWidth() - getPaddingRight() - mTimeBounds.width() / 2, in onDraw() 219 mCurrentTime = getScrubberTime(mScrubberLeft, mScrubber.getWidth() / 2); in updateTimeFromPos() 264 mScrubber.getWidth() / 2, in onTouchEvent() 267 mScrubber.getWidth() / 2); in onTouchEvent() [all …]
|
D | TimeBar.java | 124 mScrubberLeft = mPlayedBar.right - mScrubber.getWidth() / 2; in update() 154 int scrubberRight = mScrubberLeft + mScrubber.getWidth(); in inScrubber() 161 int half = mScrubber.getWidth() / 2; in clampScrubber() 168 return (int) ((long) (mScrubberLeft + mScrubber.getWidth() / 2 - mProgressBar.left) in getScrubberTime() 179 int margin = mScrubber.getWidth() / 3; in onLayout() 210 getWidth() - getPaddingRight() - mTimeBounds.width() / 2, in onDraw() 226 : mScrubber.getWidth() / 2; in onTouchEvent()
|
/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() 229 reflectRotation, master.getOriginalBounds(), getWidth(), getHeight()); in getImageToScreenMatrix() 233 m.postScale(scaleFactor, scaleFactor, getWidth() / 2.0f, getHeight() / 2.0f); in getImageToScreenMatrix() 260 getWidth() - 2*mShadowMargin, in onDraw() 298 float dx = (getHeight() - getWidth()) / 2f; in onDraw() 299 if (getWidth() > getHeight()) { in onDraw() 300 dx = - (getWidth() - getHeight()) / 2f; in onDraw() 303 canvas.rotate(180, getWidth()/2, getHeight()/2); in onDraw() 305 canvas.rotate(90, getWidth()/2, getHeight()/2); in onDraw() 308 canvas.rotate(270, getWidth()/2, getHeight()/2); in onDraw() [all …]
|
D | ImageCrop.java | 233 int width = image.getWidth(); 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() 312 FilterCropRepresentation.findScaledCrop(mScreenCropBounds, bitmap.getWidth(), in onDraw()
|
/packages/apps/TV/tuner/tests/unittests/javatests/com/android/tv/tuner/layout/tests/ |
D | ScaledLayoutTest.java | 67 assertEquals((int) (400 * 0.1), view1.getWidth()); in testScaledLayout_layoutInXml() 71 assertEquals((int) (400 * 0.1), view2.getWidth()); in testScaledLayout_layoutInXml() 75 assertEquals((int) (400 * 0.2), view3.getWidth()); in testScaledLayout_layoutInXml() 79 assertEquals((int) (400 * 0.1), view4.getWidth()); in testScaledLayout_layoutInXml() 101 assertEquals(50, view1.getWidth()); in testScaledLayout_layoutThroughCode() 105 assertEquals(50, view2.getWidth()); in testScaledLayout_layoutThroughCode() 109 assertEquals(50, view3.getWidth()); in testScaledLayout_layoutThroughCode() 113 assertEquals(50, view4.getWidth()); in testScaledLayout_layoutThroughCode() 131 assertEquals(100, view1.getWidth()); in testScaledLayout_bounceY() 135 assertEquals(100, view2.getWidth()); in testScaledLayout_bounceY()
|
/packages/apps/UnifiedEmail/src/com/android/mail/browse/ |
D | ConversationItemViewCoordinates.java | 100 public int getWidth() { in getWidth() method in ConversationItemViewCoordinates.Config 288 final int widthSpec = MeasureSpec.makeMeasureSpec(config.getWidth(), MeasureSpec.EXACTLY); in ConversationItemViewCoordinates() 295 folderLayoutWidth = (int) (view.getWidth() * in ConversationItemViewCoordinates() 297 folderCellWidth = (int) (view.getWidth() * in ConversationItemViewCoordinates() 306 contactImagesWidth = contactImagesView.getWidth(); in ConversationItemViewCoordinates() 320 starWidth = star.getWidth(); in ConversationItemViewCoordinates() 326 sendersWidth = senders.getWidth(); in ConversationItemViewCoordinates() 335 subjectWidth = subject.getWidth(); in ConversationItemViewCoordinates() 343 maxSnippetWidth = snippet.getWidth(); in ConversationItemViewCoordinates() 349 foldersRight = foldersLeft + folders.getWidth(); in ConversationItemViewCoordinates() [all …]
|
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/category/ |
D | IconView.java | 102 int x = (int) (canvas.getWidth() - textWidth - 2*mMargin); in drawText() 104 x = (int) ((canvas.getWidth() - textWidth) / 2.0f); in drawText() 181 mBitmapBounds = new Rect(mMargin/2, mMargin, getWidth() - mMargin/2, 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() 209 float scaleWidth = mBitmapBounds.width() / (float) mBitmap.getWidth(); in onDraw() 212 float dx = (mBitmapBounds.width() - (mBitmap.getWidth() * scale)) / 2f; in onDraw() 234 startGradient = getWidth()/2; in onDraw() 236 canvas.drawRect(new RectF(startGradient, start, getWidth(), end), mPaint); in onDraw()
|
/packages/apps/Car/libs/car-apps-common/src/com/android/car/apps/common/ |
D | BitmapUtils.java | 37 if (bm == null || (bm.getHeight() == height && bm.getWidth() == width)) { in scaleBitmap() 46 if (bm.getWidth() > width) { in scaleBitmap() 47 widthScale = (float) width / bm.getWidth(); in scaleBitmap() 50 int scaleWidth = (int) Math.ceil(bm.getWidth() * scale); in scaleBitmap() 84 if (bm.getHeight() < height || bm.getWidth() < width) { in cropBitmap() 88 bm.getWidth(), bm.getHeight(), width, height)); in cropBitmap() 92 int x = (bm.getWidth() - width) / 2; in cropBitmap()
|
/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/Gallery/src/com/android/camera/ |
D | ImageViewTouchBase.java | 155 final int viewWidth = getWidth(); in setImageRotateBitmapResetBase() 194 mBitmapDisplayed.getBitmap().getWidth(), in center() 216 int viewWidth = getWidth(); in center() 260 float viewWidth = getWidth(); in getProperBaseMatrix() 263 float w = bitmap.getWidth(); in getProperBaseMatrix() 301 float fw = (float) mBitmapDisplayed.getWidth() / (float) mThisWidth; in maxZoom() 341 float cx = getWidth() / 2F; in zoomTo() 348 float cx = getWidth() / 2F; in zoomToPoint() 371 float cx = getWidth() / 2F; in zoomIn() 383 float cx = getWidth() / 2F; in zoomOut()
|
D | RotateBitmap.java | 60 int cx = mBitmap.getWidth() / 2; in getRotateMatrix() 64 matrix.postTranslate(getWidth() / 2, getHeight() / 2); in getRotateMatrix() 75 return mBitmap.getWidth(); in getHeight() 81 public int getWidth() { in getWidth() method in RotateBitmap 85 return mBitmap.getWidth(); in getWidth()
|
/packages/apps/ManagedProvisioning/tests/instrumentation/src/com/android/managedprovisioning/common/ |
D | LogoUtilsTest.java | 42 assertEquals(10, newBitmap.getWidth()); in testPartiallyResizedBitmap() 56 assertEquals(2, newBitmap.getWidth()); in testPartiallyResizedElongatedBitmap() 68 assertEquals(4, newBitmap.getWidth()); in testResizeBitmapKeepRatio() 78 assertEquals(16, newBitmap.getWidth()); in testResizeBitmapNoScalingNeeded() 86 assertEquals(10, newBitmap.getWidth()); in testResizeBitmapNoIntegerRatio() 128 assertEquals(b1.getWidth(), b2.getWidth()); in assertBitmapEquals() 130 for (int x = 0; x < b1.getWidth(); x++) { in assertBitmapEquals()
|
/packages/apps/Camera2/src/com/android/camera/one/v2/camera2proxy/ |
D | ForwardingImageProxy.java | 91 public int getWidth() { in getWidth() method in ForwardingImageProxy 92 return mImpl.getWidth(); in getWidth() 107 .add("width", getWidth()) in toString() 122 otherImage.getWidth() == getWidth() && in equals() 129 return Objects.hashCode(getFormat(), getWidth(), getHeight(), getTimestamp()); in hashCode()
|
D | AndroidImageProxy.java | 106 mWidth = mImage.getWidth(); in AndroidImageProxy() 190 public int getWidth() { in getWidth() method in AndroidImageProxy 209 .add("width", getWidth()) in toString() 224 otherImage.getWidth() == getWidth() && in equals() 231 return Objects.hashCode(getFormat(), getWidth(), getHeight(), getTimestamp()); in hashCode()
|
/packages/apps/DevCamera/src/com/android/devcamera/ |
D | Api2Camera.java | 202 mCameraInfoCache.getYuvStream1Size().getWidth(), in InitializeAllTheThings() 210 mCameraInfoCache.getYuvStream1Size().getWidth(), in InitializeAllTheThings() 218 mCameraInfoCache.getDepthCloudSize().getWidth(), in InitializeAllTheThings() 227 mCameraInfoCache.getYuvStream2Size().getWidth(), in InitializeAllTheThings() 261 mCameraInfoCache.getRawStreamSize().getWidth(), in InitializeAllTheThings() 408 Log.v(TAG, " .. added SurfaceView " + mCameraInfoCache.getPreviewSize().getWidth() + in startCaptureSession() 412 Log.v(TAG, " .. added YUV ImageReader " + mCameraInfoCache.getYuvStream1Size().getWidth() + in startCaptureSession() 422 … Log.v(TAG, " .. added YUV ImageReader " + mCameraInfoCache.getYuvStream2Size().getWidth() + in startCaptureSession() 433 … Log.v(TAG, " .. added Raw ImageReader " + mCameraInfoCache.getRawStreamSize().getWidth() + in startCaptureSession() 439 … Log.v(TAG, " .. added JPEG ImageReader " + mCameraInfoCache.getJpegStreamSize().getWidth() + in startCaptureSession() [all …]
|
/packages/apps/WallpaperPicker/src/com/android/photos/ |
D | BitmapRegionTileSource.java | 45 int getWidth(); in getWidth() method 69 public int getWidth() { in getWidth() method in SimpleBitmapRegionDecoderWrapper 70 return mDecoder.getWidth(); in getWidth() 94 public int getWidth() { in getWidth() method in DumbBitmapRegionDecoder 95 return mBuffer.getWidth(); in getWidth() 150 int width = mDecoder.getWidth(); in loadInBackground() 307 mWidth = mDecoder.getWidth(); in BitmapRegionTileSource() 316 preview.getWidth() <= GL_SIZE_LIMIT && preview.getHeight() <= GL_SIZE_LIMIT) { in BitmapRegionTileSource() 323 preview == null ? -1 : preview.getWidth(), in BitmapRegionTileSource()
|
/packages/apps/Launcher3/src/com/android/launcher3/widget/ |
D | PendingItemDragHelper.java | 108 scale = previewBounds.width() / (float) preview.getWidth(); in startDrag() 119 scale = ((float) launcher.getDeviceProfile().iconSizePx) / preview.getWidth(); in startDrag() 146 + (int) ((scale * preview.getWidth() - preview.getWidth()) / 2); in startDrag() 164 Rect src = new Rect(0, 0, preview.getWidth(), preview.getHeight()); in convertPreviewToAlphaBitmap() 166 float scaleFactor = Math.min((w - blurSizeOutline) / (float) preview.getWidth(), in convertPreviewToAlphaBitmap() 168 int scaledWidth = (int) (scaleFactor * preview.getWidth()); in convertPreviewToAlphaBitmap()
|
/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() 289 + bitmap.getWidth() in toString()
|
/packages/apps/Launcher3/src/com/android/launcher3/notification/ |
D | NotificationMainView.java | 184 ? displacement : OverScroll.dampedScroll(displacement, getWidth())); in onDrag() 200 endTranslation = velocity < 0 ? - getWidth() : getWidth(); in onDragEnd() 201 } else if (Math.abs(startTranslation) > getWidth() / 2) { in onDragEnd() 203 endTranslation = (startTranslation < 0 ? -getWidth() : getWidth()); in onDragEnd() 210 (endTranslation - startTranslation) / getWidth()); in onDragEnd()
|
/packages/apps/WallpaperPicker2/src/com/android/wallpaper/asset/ |
D | Asset.java | 59 int width = imageView.getWidth() > 0 in getImageViewDimensions() 60 ? imageView.getWidth() in getImageViewDimensions() 148 int width = imageView.getWidth() > 0 in loadDrawable() 149 ? imageView.getWidth() in loadDrawable() 302 int bitmapWidth = mBitmap.getWidth(); in doInBackground() 312 int horizontalGutterPx = Math.max(0, (scaledBitmap.getWidth() - measuredWidth) / 2); in doInBackground() 319 scaledBitmap.getWidth() - (2 * horizontalGutterPx), in doInBackground()
|
/packages/apps/Dialer/java/com/android/incallui/answer/impl/ |
D | SelfManagedAnswerVideoCallScreen.java | 130 float outputAspect = (float) previewSize.getWidth() / previewSize.getHeight(); in openCamera() 132 surfaceView.getHolder().setFixedSize(previewSize.getWidth(), previewSize.getHeight()); in openCamera() 194 (float) bestCandidateSize.getWidth() / bestCandidateSize.getHeight(); in getOptimalSize() 197 if (candidateSize.getWidth() < MAX_WIDTH) { in getOptimalSize() 198 float candidateAspect = (float) candidateSize.getWidth() / candidateSize.getHeight(); in getOptimalSize() 205 || candidateSize.getWidth() > bestCandidateSize.getWidth()) { in getOptimalSize()
|
/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() 323 final int viewRatio = (int)getRatio(viewSize.getWidth(), viewSize.getHeight()); in setTransformationMatrix() 328 final int previewWidth = isPortrait ? mPreviewSize.getWidth() : mPreviewSize.getHeight(); in setTransformationMatrix() 329 final int previewHeight = isPortrait ? mPreviewSize.getHeight() : mPreviewSize.getWidth(); in setTransformationMatrix() 350 mPreviewSize.getWidth(), mPreviewSize.getHeight()); in getFrameImage() 375 final double winRatio = getRatio(windowSize.getWidth(), windowSize.getHeight()); in getBestPreviewSize() 380 if (size.height * size.width > bestChoice.getWidth() * bestChoice.getHeight() in getBestPreviewSize() 423 int areaDifference = Math.abs(size.getWidth() * size.getHeight() - previewArea); in getBestPictureSize()
|
/packages/services/Telephony/src/com/android/phone/ |
D | EmergencyActionGroup.java | 188 int centerX = v.getLeft() + v.getWidth() / 2; in revealTheButton() 195 Math.max(centerX, mSelectedContainer.getWidth() - centerX) in revealTheButton() 250 (v.getLeft() + v.getWidth() / 2 - mSelectedContainer.getWidth() / 2) / 5); in animateHintText() 269 int centerX = v.getLeft() + v.getWidth() / 2; in hideTheButton() 275 Math.max(centerX, mSelectedContainer.getWidth() - centerX) in hideTheButton() 300 ripple.getLeft() + ripple.getWidth() / 2, in startRipple() 303 ripple.getWidth() / 2); in startRipple()
|
/packages/apps/Gallery2/src/com/android/gallery3d/ui/ |
D | ProgressSpinner.java | 41 mWidth = Math.max(mOuter.getWidth(), mInner.getWidth()); in ProgressSpinner() 45 public int getWidth() { in getWidth() 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()
|