Home
last modified time | relevance | path

Searched refs:rect (Results 1 – 25 of 67) sorted by relevance

123

/packages/apps/Gallery2/jni/filters/
DredEyeMath.c34 short *rect) { in findPossible() argument
35 int recX = rect[0], recY = rect[1], recW = rect[2], recH = rect[3]; in findPossible()
55 short *rect) { in findReds() argument
56 int recX = rect[0], recY = rect[1], recW = rect[2], recH = rect[3]; in findReds()
72 unsigned char *out, short *rect) { in dialateMaskIfRed() argument
73 int recX = rect[0], recY = rect[1], recW = rect[2], recH = rect[3]; in dialateMaskIfRed()
110 void filterRedEye(unsigned char *src, unsigned char *dest, int iw, int ih, short *rect) { in filterRedEye() argument
111 int recX = rect[0], recY = rect[1], recW = rect[2], recH = rect[3]; in filterRedEye()
117 rect[0] = MAX(rect[0],0); in filterRedEye()
118 rect[1] = MAX(rect[1],0); in filterRedEye()
[all …]
/packages/services/Car/service/jni/
Dcom_android_car_CarCameraService.cpp153 android_native_rect_t rect; in com_android_car_CarCameraService_nativeGetCameraCrop() local
154 device->get_camera_crop(device, &rect); in com_android_car_CarCameraService_nativeGetCameraCrop()
161 retObj = env->NewObject(cls, midInit, rect.left, rect.top, rect.right, rect.bottom); in com_android_car_CarCameraService_nativeGetCameraCrop()
177 android_native_rect_t rect; in com_android_car_CarCameraService_nativeSetCameraCrop() local
185 rect.left = (uint32_t)env->GetIntField(jrect, fidLeft); in com_android_car_CarCameraService_nativeSetCameraCrop()
186 rect.top = (uint32_t)env->GetIntField(jrect, fidTop); in com_android_car_CarCameraService_nativeSetCameraCrop()
187 rect.right = (uint32_t)env->GetIntField(jrect, fidRight); in com_android_car_CarCameraService_nativeSetCameraCrop()
188 rect.bottom = (uint32_t)env->GetIntField(jrect, fidBottom); in com_android_car_CarCameraService_nativeSetCameraCrop()
190 device->set_camera_crop(device, &rect); in com_android_car_CarCameraService_nativeSetCameraCrop()
207 android_native_rect_t rect; in com_android_car_CarCameraService_nativeGetCameraPosition() local
[all …]
/packages/services/Car/service/src/com/android/car/
DCarCameraService.java125 Rect rect; in getCameraCrop() local
128 rect = nativeGetCameraCrop(device); in getCameraCrop()
130 if(DBG && (rect != null)) { in getCameraCrop()
131 Log.d(TAG, "getCameraCrop called: " + rect.toString()); in getCameraCrop()
133 return rect; in getCameraCrop()
137 public void setCameraCrop(int cameraType, Rect rect) { in setCameraCrop() argument
139 Log.d(TAG, "setCameraCrop called." + rect.toString()); in setCameraCrop()
143 nativeSetCameraCrop(device, rect); in setCameraCrop()
149 Rect rect; in getCameraPosition() local
152 rect = nativeGetCameraPosition(device); in getCameraPosition()
[all …]
/packages/services/Car/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/camera/
DCameraTestFragment.java81 Rect rect = mRvcCamera.getCameraCrop(); in onCreateView()
82 if(rect != null) { in onCreateView()
83 mTvRvcCrop.setText(rect.toString()); in onCreateView()
97 Rect rect = mRvcCamera.getCameraPosition(); in onCreateView()
98 if(rect != null) { in onCreateView()
99 mTvRvcPos.setText(String.valueOf(rect)); in onCreateView()
128 Rect rect = new Rect(160, 240, 560, 480); in onCreateView()
130 mRvcCamera.setCameraCrop(rect); in onCreateView()
140 Rect rect = new Rect(0, 0, 720, 480); in onCreateView()
142 mRvcCamera.setCameraCrop(rect); in onCreateView()
[all …]
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/util/
DTransitionImage.java108 public void setRect(Rect rect) { in setRect() argument
109 mRect.set(rect); in setRect()
140 public void setUnclippedRect(RectF rect) { in setUnclippedRect() argument
141 mUnclippedRect.set(rect); in setUnclippedRect()
148 public void setClippedRect(RectF rect) { in setClippedRect() argument
149 mClippedRect.set(rect); in setClippedRect()
220 Rect rect = null; in readFromBundle() local
223 rect = Rect.unflattenFromString(bitmapRectStr); in readFromBundle()
225 if (rect == null) { in readFromBundle()
226 rect = intentSourceBounds; in readFromBundle()
[all …]
DWindowLocationUtil.java95 public static void getLocationsInWindow(View view, RectF rect) { in getLocationsInWindow() argument
96 sTmpFloat4[0] = rect.left; in getLocationsInWindow()
97 sTmpFloat4[1] = rect.top; in getLocationsInWindow()
98 sTmpFloat4[2] = rect.right; in getLocationsInWindow()
99 sTmpFloat4[3] = rect.bottom; in getLocationsInWindow()
101 rect.left = sTmpFloat4[0]; in getLocationsInWindow()
102 rect.top = sTmpFloat4[1]; in getLocationsInWindow()
103 rect.right = sTmpFloat4[2]; in getLocationsInWindow()
104 rect.bottom = sTmpFloat4[3]; in getLocationsInWindow()
/packages/apps/Camera2/src/com/android/camera/util/
DDebugBoundsRenderer.java32 public static void drawBounds(Canvas canvas, Paint paint, float size, Rect rect) { in drawBounds() argument
33 drawBounds(canvas, paint, size, rect.left, rect.top, rect.right, rect.bottom); in drawBounds()
40 public static void drawBounds(Canvas canvas, Paint paint, float size, RectF rect) { in drawBounds() argument
41 drawBounds(canvas, paint, size, rect.left, rect.top, rect.right, rect.bottom); in drawBounds()
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/imageshow/
DEclipseControl.java231 RectF rect = new RectF(cx - rx, cy - ry, cx + rx, cy + ry); in paintRadius() local
236 paintOvallines(canvas, rect, paint, cx, cy, rx, ry); in paintRadius()
240 paintOvallines(canvas, rect, paint, cx, cy, rx, ry); in paintRadius()
244 Canvas canvas, RectF rect, Paint paint, float cx, float cy, float rx, float ry) { in paintOvallines() argument
245 canvas.drawOval(rect, paint); in paintOvallines()
254 rect.left = cx - dx; in paintOvallines()
255 rect.top = cy - dy; in paintOvallines()
256 rect.right = cx + dx; in paintOvallines()
257 rect.bottom = cy + dy; in paintOvallines()
258 canvas.drawArc(rect, i - da, arclen, false, paint); in paintOvallines()
[all …]
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/widget/
DFrameLayoutWithShadows.java133 private final Rect rect = new Rect(); field in FrameLayoutWithShadows
247 rect.set(drawable.getBounds()); in layoutShadows()
248 rectf.set(rect); in layoutShadows()
258 rect.left = (int) (rectf.left + 0.5f); in layoutShadows()
259 rect.top = (int) (rectf.top + 0.5f); in layoutShadows()
260 rect.right = (int) (rectf.right + 0.5f); in layoutShadows()
261 rect.bottom = (int) (rectf.bottom + 0.5f); in layoutShadows()
265 rect.left = view.getPaddingLeft() - shadow.getPaddingLeft(); in layoutShadows()
266 rect.top = view.getPaddingTop() - shadow.getPaddingTop(); in layoutShadows()
267 rect.right = view.getWidth() + view.getPaddingRight() in layoutShadows()
[all …]
/packages/apps/Gallery/src/com/android/camera/
DImageViewTouchBase.java193 RectF rect = new RectF(0, 0, in center() local
197 m.mapRect(rect); in center()
199 float height = rect.height(); in center()
200 float width = rect.width(); in center()
207 deltaY = (viewHeight - height) / 2 - rect.top; in center()
208 } else if (rect.top > 0) { in center()
209 deltaY = -rect.top; in center()
210 } else if (rect.bottom < viewHeight) { in center()
211 deltaY = getHeight() - rect.bottom; in center()
218 deltaX = (viewWidth - width) / 2 - rect.left; in center()
[all …]
/packages/apps/Gallery2/src/com/android/gallery3d/ui/
DSlotView.java111 Rect rect = mLayout.getSlotRect(index, mTempRect); in setCenterIndex() local
113 ? (rect.left + rect.right - getWidth()) / 2 in setCenterIndex()
114 : (rect.top + rect.bottom - getHeight()) / 2; in setCenterIndex()
119 Rect rect = mLayout.getSlotRect(index, mTempRect); in makeSlotVisible() local
123 int slotBegin = WIDE ? rect.left : rect.top; in makeSlotVisible()
124 int slotEnd = WIDE ? rect.right : rect.bottom; in makeSlotVisible()
316 Rect rect = mLayout.getSlotRect(index, mTempRect); in renderItem() local
318 canvas.multiplyMatrix(mPaper.getTransform(rect, mScrollX), 0); in renderItem()
320 canvas.translate(rect.left, rect.top, 0); in renderItem()
323 mAnimation.apply(canvas, index, rect); in renderItem()
[all …]
DPaper.java68 public float[] getTransform(Rect rect, float scrollX) { in getTransform() argument
71 float screenX = rect.centerX() - scrollX; in getTransform()
84 Matrix.translateM(mMatrix, 0, mMatrix, 0, rect.centerX(), rect.centerY(), 0); in getTransform()
86 Matrix.translateM(mMatrix, 0, mMatrix, 0, -rect.width() / 2, -rect.height() / 2, 0); in getTransform()
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/filters/
DImageFilterRedEye.java62 short[] rect = new short[4]; in apply() local
70 rect[0] = (short) r.left; in apply()
71 rect[1] = (short) r.top; in apply()
72 rect[2] = (short) r.width(); in apply()
73 rect[3] = (short) r.height(); in apply()
74 nativeApplyFilter(bitmap, w, h, rect); in apply()
DRedEyeCandidate.java30 public RedEyeCandidate(RectF rect, RectF bounds) { in RedEyeCandidate() argument
31 mRect.set(rect); in RedEyeCandidate()
43 public boolean intersect(RectF rect) { in intersect() argument
44 return mRect.intersect(rect); in intersect()
DFilterRedEyeRepresentation.java50 public void addRect(RectF rect, RectF bounds) { in addRect() argument
54 if (r.intersect(rect)) { in addRect()
60 rect.union(r.mRect); in addRect()
64 addCandidate(new RedEyeCandidate(rect, bounds)); in addRect()
/packages/apps/TV/src/com/android/tv/util/
DBitmapUtils.java54 Rect rect = calculateNewSize(bm, maxWidth, maxHeight); in scaleBitmap() local
55 return Bitmap.createScaledBitmap(bm, rect.right, rect.bottom, false); in scaleBitmap()
61 Rect rect = new Rect(); in calculateNewSize() local
63 rect.right = maxWidth; in calculateNewSize()
64 rect.bottom = Math.round((float) bm.getHeight() * maxWidth / bm.getWidth()); in calculateNewSize()
66 rect.right = Math.round((float) bm.getWidth() * maxHeight / bm.getHeight()); in calculateNewSize()
67 rect.bottom = maxHeight; in calculateNewSize()
69 return rect; in calculateNewSize()
/packages/apps/TV/src/com/android/tv/recommendation/
DNotificationService.java471 Rect rect = new Rect();
476 rect.bottom = result.getHeight() - mLogoPaddingBottom;
477 rect.top = rect.bottom - scaledLogo.getHeight();
480 rect.bottom = result.getHeight() - mLogoPaddingBottom;
481 rect.top = rect.bottom - scaledLogo.getHeight();
485 rect.bottom = result.getHeight() - mLogoPaddingBottom;
486 rect.top = rect.bottom - scaledLogo.getHeight();
489 rect.left = startPadding;
490 rect.right = startPadding + scaledLogo.getWidth();
492 rect.right = result.getWidth() - startPadding;
[all …]
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/
DInputView.java70 final Rect rect = mInputViewRect; in onInterceptTouchEvent() local
71 getGlobalVisibleRect(rect); in onInterceptTouchEvent()
73 final int x = (int)me.getX(index) + rect.left; in onInterceptTouchEvent()
74 final int y = (int)me.getY(index) + rect.top; in onInterceptTouchEvent()
100 final Rect rect = mInputViewRect; in onTouchEvent() local
101 getGlobalVisibleRect(rect); in onTouchEvent()
103 final int x = (int)me.getX(index) + rect.left; in onTouchEvent()
104 final int y = (int)me.getY(index) + rect.top; in onTouchEvent()
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/colorpicker/
DColorRectView.java163 RectF rect = new RectF(); in onDraw() local
164 rect.left = mBorder; in onDraw()
165 rect.right = mWidth - mBorder; in onDraw()
166 rect.top = mBorder; in onDraw()
167 rect.bottom = mHeight - mBorder; in onDraw()
169 canvas.drawRect(rect, mWheelPaint1); in onDraw()
170 canvas.drawRect(rect, mWheelPaint3); in onDraw()
171 canvas.drawRect(rect, mWheelPaint2); in onDraw()
/packages/apps/ContactsCommon/src/com/android/contacts/common/
DMoreContactUtils.java185 final Rect rect = new Rect(); in getTargetRectFromView() local
186 rect.left = pos[0]; in getTargetRectFromView()
187 rect.top = pos[1]; in getTargetRectFromView()
188 rect.right = pos[0] + view.getWidth(); in getTargetRectFromView()
189 rect.bottom = pos[1] + view.getHeight(); in getTargetRectFromView()
190 return rect; in getTargetRectFromView()
/packages/apps/Messaging/src/com/android/messaging/ui/mediapicker/camerafocus/
DFocusOverlayManager.java314 ((Area) mFocusArea.get(0)).rect); in initializeFocusAreas()
328 ((Area) mMeteringArea.get(0)).rect); in initializeMeteringAreas()
492 int x, int y, int previewWidth, int previewHeight, Rect rect) { in calculateTapArea() argument
500 rectFToRect(rectF, rect); in calculateTapArea()
583 public static void rectFToRect(RectF rectF, Rect rect) { in rectFToRect() argument
584 rect.left = Math.round(rectF.left); in rectFToRect()
585 rect.top = Math.round(rectF.top); in rectFToRect()
586 rect.right = Math.round(rectF.right); in rectFToRect()
587 rect.bottom = Math.round(rectF.bottom); in rectFToRect()
/packages/apps/Launcher3/src/com/android/launcher3/widget/
DWidgetHostViewLoader.java155 Rect rect = new Rect(); in getDefaultOptionsForWidget() local
157 AppWidgetResizeFrame.getWidgetSizeRanges(launcher, info.spanX, info.spanY, rect); in getDefaultOptionsForWidget()
167 rect.left - xPaddingDips); in getDefaultOptionsForWidget()
169 rect.top - yPaddingDips); in getDefaultOptionsForWidget()
171 rect.right - xPaddingDips); in getDefaultOptionsForWidget()
173 rect.bottom - yPaddingDips); in getDefaultOptionsForWidget()
/packages/apps/Launcher2/src/com/android/launcher2/
DSearchDropTargetBar.java227 final Rect rect = new Rect(); in getSearchBarBounds() local
228 rect.left = pos[0]; in getSearchBarBounds()
229 rect.top = pos[1]; in getSearchBarBounds()
230 rect.right = pos[0] + mQSBSearchBar.getWidth(); in getSearchBarBounds()
231 rect.bottom = pos[1] + mQSBSearchBar.getHeight(); in getSearchBarBounds()
232 return rect; in getSearchBarBounds()
/packages/apps/Camera2/src/com/android/camera/
DCaptureLayoutHelper.java369 public static void round(RectF rect) { in round() argument
370 if (rect == null) { in round()
373 float left = Math.round(rect.left); in round()
374 float top = Math.round(rect.top); in round()
375 float right = Math.round(rect.right); in round()
376 float bottom = Math.round(rect.bottom); in round()
377 rect.set(left, top, right, bottom); in round()
/packages/apps/TV/src/com/android/tv/menu/
DMenuLayoutManager.java143 Rect rect = layouts.get(i); in layout() local
144 if (rect != null) { in layout()
146 currentView.layout(rect.left, rect.top, rect.right, rect.bottom); in layout()
555 Rect rect = layouts.get(i); in setSelectedPositionSmooth() local
556 animators.add(createTranslationYAnimator(view, 0, rect.top - view.getTop())); in setSelectedPositionSmooth()
705 Rect rect = layouts.get(position); in onMenuRowUpdated() local
708 view.layout(rect.left, rect.top, rect.right, rect.bottom); in onMenuRowUpdated()
713 rect.right - rect.left - view.getPaddingRight() - params.rightMargin, in onMenuRowUpdated()
714 rect.bottom - rect.top - view.getPaddingBottom() - params.bottomMargin); in onMenuRowUpdated()

123