Searched defs:ratio (Results 1 - 19 of 19) sorted by relevance

/packages/apps/LegacyCamera/src/com/android/camera/
H A DPreviewFrameLayout.java28 * A layout which handles the preview aspect ratio.
43 public void setAspectRatio(double ratio) { argument
44 if (ratio <= 0.0) throw new IllegalArgumentException();
48 ratio = 1 / ratio;
51 if (mAspectRatio != ratio) {
52 mAspectRatio = ratio;
71 // Resize the preview frame with correct aspect ratio.
/packages/apps/Camera2/src/com/android/camera/
H A DVideoController.java31 public void onZoomChanged(float ratio); argument
H A DVideoUI.java171 public void setAspectRatio(float ratio) { argument
172 if (ratio <= 0) {
175 float aspectRatio = ratio > 1 ? ratio : 1 / ratio;
278 public void onZoomValueChanged(float ratio) { argument
279 mController.onZoomChanged(ratio);
313 // recalculate aspect ratio when restarting.
H A DPhotoUI.java291 Log.e(TAG, "Invalid aspect ratio: " + aspectRatio);
300 // Update transform matrix with the new aspect ratio.
378 // If we don't want to show the aspect ratio dialog,
424 Log.e(TAG, "Dialog for aspect ratio is null.");
452 * @return Whether this is a device that we should show the aspect ratio
517 public void onZoomValueChanged(float ratio) { argument
518 mController.onZoomChanged(ratio);
541 // recalculate aspect ratio when restarting.
H A DVideoModule.java184 private float mZoomValue; // The current zoom ratio.
903 public void onZoomChanged(float ratio) { argument
908 mZoomValue = ratio;
H A DPhotoModule.java149 private float mZoomValue; // The current zoom ratio.
294 * This callback defines the text that is shown in the aspect ratio selection
295 * dialog, provides the current aspect ratio, and gets notified when user changes
296 * aspect ratio selection in the dialog.
300 * Returns current aspect ratio that is being used to set as default.
305 * Gets notified when user has made the aspect ratio selection.
307 * @param newAspectRatio aspect ratio that user has selected
432 // Switch to back camera to set aspect ratio.
488 * Prompt the user to pick to record location and choose aspect ratio for the
514 // Show both location and aspect ratio selectio
2356 onZoomChanged(float ratio) argument
[all...]
/packages/apps/DeskClock/src/com/android/alarmclock/
H A DDigitalAppWidgetProvider.java96 float ratio = WidgetUtils.getScaleRatio(context, null, appWidgetId);
98 WidgetUtils.setClockSize(context, widget, ratio);
140 float ratio = WidgetUtils.getScaleRatio(context, null, appWidgetId);
141 updateClock(context, appWidgetManager, appWidgetId, ratio);
151 float ratio = WidgetUtils.getScaleRatio(context, newOptions, appWidgetId);
153 updateClock(context, widgetManager, appWidgetId, ratio);
157 Context context, AppWidgetManager appWidgetManager, int appWidgetId, float ratio) {
172 WidgetUtils.setClockSize(context, widget, ratio);
156 updateClock( Context context, AppWidgetManager appWidgetManager, int appWidgetId, float ratio) argument
/packages/apps/Camera/src/com/android/camera/
H A DPreviewFrameLayout.java31 * A layout which handles the preview aspect ratio.
67 public void setAspectRatio(double ratio) { argument
68 if (ratio <= 0.0) throw new IllegalArgumentException();
70 if (mAspectRatio != ratio) {
71 mAspectRatio = ratio;
94 // Resize the preview frame with correct aspect ratio.
/packages/apps/ContactsCommon/src/com/android/contacts/common/widget/
H A DProportionalLayout.java143 public void setRatio(float ratio) { argument
144 mRatio = ratio;
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/keyboard/internal/
H A DKeyDrawParams.java131 final int dimens, final float ratio, final int defaultDimens) {
135 if (ResourceUtils.isValidFraction(ratio)) {
136 return (int)(keyHeight * ratio);
141 private static int selectTextSize(final int keyHeight, final float ratio, argument
143 if (ResourceUtils.isValidFraction(ratio)) {
144 return (int)(keyHeight * ratio);
130 selectTextSizeFromDimensionOrRatio(final int keyHeight, final int dimens, final float ratio, final int defaultDimens) argument
/packages/apps/Camera2/src/com/android/camera/ui/
H A DPreviewOverlay.java82 * @param ratio zoom ratio, [1.0f,maximum]
84 void onZoomValueChanged(float ratio); // only for immediate zoom argument
103 * @param zoomMaxRatio max zoom ratio, [1.0f,+Inf)
104 * @param zoom current zoom ratio, [1.0f,zoomMaxRatio]
251 // Set maximum zoom ratio from Module.
256 // Set current zoom ratio from Module.
257 public void setZoom(float ratio) { argument
258 mCurrentRatio = ratio;
/packages/apps/Gallery2/src/com/android/gallery3d/glrenderer/
H A DGLCanvas.java109 // from * (1 - ratio) + to * ratio
112 float ratio, int x, int y, int w, int h);
115 // rectangle. The actual color used is from * (1 - ratio) + to * ratio.
119 float ratio, RectF src, RectF target);
111 drawMixed(BasicTexture from, int toColor, float ratio, int x, int y, int w, int h) argument
118 drawMixed(BasicTexture from, int toColor, float ratio, RectF src, RectF target) argument
H A DTiledTexture.java275 // a rectangle. The used color is: from * (1 - ratio) + to * ratio.
276 public void drawMixed(GLCanvas canvas, int color, float ratio, argument
289 canvas.drawMixed(t, color, ratio, mSrcRect, mDestRect);
H A DGLES11Canvas.java451 int toColor, float ratio, int x, int y, int w, int h) {
452 drawMixed(from, toColor, ratio, x, y, w, h, mAlpha);
471 private void setMixedColor(int toColor, float ratio, float alpha) { argument
474 // alpha * ((1 - ratio) * from + ratio * to)
479 // So, we have combo = alpha * (1 - ratio)
480 // and scale = alpha * ratio / (1 - combo)
482 float combo = alpha * (1 - ratio);
483 float scale = alpha * ratio / (1 - combo);
513 public void drawMixed(BasicTexture from, int toColor, float ratio, argument
450 drawMixed(BasicTexture from, int toColor, float ratio, int x, int y, int w, int h) argument
547 drawMixed(BasicTexture from, int toColor, float ratio, int x, int y, int width, int height, float alpha) argument
[all...]
H A DGLES20Canvas.java758 public void drawMixed(BasicTexture texture, int toColor, float ratio, int x, int y, int w, int h) { argument
761 drawMixed(texture, toColor, ratio, mTempSourceRect, mTempTargetRect);
765 public void drawMixed(BasicTexture texture, int toColor, float ratio, RectF source, RectF target) { argument
772 float cappedRatio = Math.min(1f, Math.max(0f, ratio));
/packages/apps/Launcher3/WallpaperPicker/src/com/android/gallery3d/glrenderer/
H A DGLCanvas.java107 // from * (1 - ratio) + to * ratio
110 float ratio, int x, int y, int w, int h);
113 // rectangle. The actual color used is from * (1 - ratio) + to * ratio.
117 float ratio, RectF src, RectF target);
109 drawMixed(BasicTexture from, int toColor, float ratio, int x, int y, int w, int h) argument
116 drawMixed(BasicTexture from, int toColor, float ratio, RectF src, RectF target) argument
H A DGLES20Canvas.java758 public void drawMixed(BasicTexture texture, int toColor, float ratio, int x, int y, int w, int h) { argument
761 drawMixed(texture, toColor, ratio, mTempSourceRect, mTempTargetRect);
765 public void drawMixed(BasicTexture texture, int toColor, float ratio, RectF source, RectF target) { argument
772 float cappedRatio = Math.min(1f, Math.max(0f, ratio));
/packages/apps/Contacts/src/com/android/contacts/widget/
H A DMultiShrinkScroller.java78 * In portrait mode, the height:width ratio of the photo's starting height.
84 * to this ratio of its full height.
193 void onTransparentViewHeightChange(float ratio); argument
620 * Return ratio of non-transparent:viewgroup-height for this viewgroup at the starting position.
1013 final float ratio = (toolbarHeight - mMinimumHeaderHeight)
1016 float bezierOutput = mTextSizePathInterpolator.getInterpolation(ratio);
1112 // 3) The function should have a derivative of 0 at ratio = 1 to avoid discontinuities.
1114 final float ratio = calculateHeightRatioToBlendingStartHeight(toolbarHeight);
1115 final float alpha = 1.0f - (float) Math.min(Math.pow(ratio, 1.5f) * 2f, 1f);
1116 final float tint = (float) Math.min(Math.pow(ratio, 1.
[all...]
/packages/apps/Gallery2/src/com/android/gallery3d/ui/
H A DPhotoView.java1791 // When ratio = 0, the result is from.
1792 // When ratio = 1, the result is to.
1793 private static float interpolate(float ratio, float from, float to) { argument
1794 return from + (to - from) * ratio * ratio;

Completed in 1509 milliseconds