Home
last modified time | relevance | path

Searched refs:center (Results 1 – 25 of 75) sorted by relevance

123

/frameworks/base/media/mca/filterfw/java/android/filterfw/geometry/
DRectangle.java45 public static Rectangle fromRotatedRect(Point center, Point size, float rotation) { in fromRotatedRect() argument
46 Point p0 = new Point(center.x - size.x/2f, center.y - size.y/2f); in fromRotatedRect()
47 Point p1 = new Point(center.x + size.x/2f, center.y - size.y/2f); in fromRotatedRect()
48 Point p2 = new Point(center.x - size.x/2f, center.y + size.y/2f); in fromRotatedRect()
49 Point p3 = new Point(center.x + size.x/2f, center.y + size.y/2f); in fromRotatedRect()
50 return new Rectangle(p0.rotatedAround(center, rotation), in fromRotatedRect()
51 p1.rotatedAround(center, rotation), in fromRotatedRect()
52 p2.rotatedAround(center, rotation), in fromRotatedRect()
53 p3.rotatedAround(center, rotation)); in fromRotatedRect()
60 public static Rectangle fromCenterVerticalAxis(Point center, Point vAxis, Point size) { in fromCenterVerticalAxis() argument
[all …]
DPoint.java109 public Point rotatedAround(Point center, float radians) { in rotatedAround() argument
110 return this.minus(center).rotated(radians).plus(center); in rotatedAround()
/frameworks/base/core/java/android/gesture/
DInstance.java93 float[] center = GestureUtils.computeCentroid(pts); in temporalSampler() local
94 float orientation = (float)Math.atan2(pts[1] - center[1], pts[0] - center[0]); in temporalSampler()
107 GestureUtils.translate(pts, -center[0], -center[1]); in temporalSampler()
/frameworks/base/core/tests/coretests/src/android/widget/
DAbsSeekBarTest.java75 center(offset(mBar.getThumb().getBounds(), PADDING - thumbOffset, PADDING)), in testExclusionForThumb_limitedTo48dp()
76 center(exclusions.get(0))); in testExclusionForThumb_limitedTo48dp()
96 center(offset(mBar.getThumb().getBounds(), PADDING - thumbOffset, PADDING)), in testExclusionForThumb_limitedToHeight()
97 center(exclusions.get(0))); in testExclusionForThumb_limitedToHeight()
141 assertEquals("grown rect center point", center(expected), center(result)); in doGrowRectTest()
144 private Point center(Rect rect) { in center() method in AbsSeekBarTest
/frameworks/av/media/libstagefright/renderfright/gl/
DGLSkiaShadowPort.cpp244 vec2 center = vec2(bounds.getWidth() / 2.0f, bounds.getHeight() / 2.0f); in fillInCircleVerts() local
249 position[vertexCount] = center + vec2(-octOffset * halfWidth, -halfWidth); in fillInCircleVerts()
254 position[vertexCount] = center + vec2(octOffset * halfWidth, -halfWidth); in fillInCircleVerts()
259 position[vertexCount] = center + vec2(halfWidth, -octOffset * halfWidth); in fillInCircleVerts()
264 position[vertexCount] = center + vec2(halfWidth, octOffset * halfWidth); in fillInCircleVerts()
269 position[vertexCount] = center + vec2(octOffset * halfWidth, halfWidth); in fillInCircleVerts()
274 position[vertexCount] = center + vec2(-octOffset * halfWidth, halfWidth); in fillInCircleVerts()
279 position[vertexCount] = center + vec2(-halfWidth, octOffset * halfWidth); in fillInCircleVerts()
284 position[vertexCount] = center + vec2(-halfWidth, -octOffset * halfWidth); in fillInCircleVerts()
297 position[vertexCount] = center + vec2(-s * r, -c * r); in fillInCircleVerts()
[all …]
/frameworks/native/libs/renderengine/gl/
DGLSkiaShadowPort.cpp244 vec2 center = vec2(bounds.getWidth() / 2.0f, bounds.getHeight() / 2.0f); in fillInCircleVerts() local
249 position[vertexCount] = center + vec2(-octOffset * halfWidth, -halfWidth); in fillInCircleVerts()
254 position[vertexCount] = center + vec2(octOffset * halfWidth, -halfWidth); in fillInCircleVerts()
259 position[vertexCount] = center + vec2(halfWidth, -octOffset * halfWidth); in fillInCircleVerts()
264 position[vertexCount] = center + vec2(halfWidth, octOffset * halfWidth); in fillInCircleVerts()
269 position[vertexCount] = center + vec2(octOffset * halfWidth, halfWidth); in fillInCircleVerts()
274 position[vertexCount] = center + vec2(-octOffset * halfWidth, halfWidth); in fillInCircleVerts()
279 position[vertexCount] = center + vec2(-halfWidth, octOffset * halfWidth); in fillInCircleVerts()
284 position[vertexCount] = center + vec2(-halfWidth, -octOffset * halfWidth); in fillInCircleVerts()
297 position[vertexCount] = center + vec2(-s * r, -c * r); in fillInCircleVerts()
[all …]
/frameworks/rs/tests/java_api/ImageProcessing/src/com/android/rs/image/
Dfisheye_approx.rsh20 static float2 center, neg_center, inv_dimensions, axis_scale;
24 center.x = center_x;
25 center.y = center_y;
26 neg_center = -center;
46 // Convert x and y to floating point coordinates with center as origin
54 const float2 new_coord = mad(coord, scalar, center);
Dfisheye.rsh20 static float2 center, neg_center, inv_dimensions, axis_scale;
24 center.x = center_x;
25 center.y = center_y;
26 neg_center = -center;
46 // Convert x and y to floating point coordinates with center as origin
54 const float2 new_coord = mad(coord, scalar, center);
/frameworks/rs/tests/java_api/ImageProcessing2/src/com/android/rs/image/
Dfisheye_approx.rsh20 static float2 center, neg_center, inv_dimensions, axis_scale;
24 center.x = center_x;
25 center.y = center_y;
26 neg_center = -center;
46 // Convert x and y to floating point coordinates with center as origin
54 const float2 new_coord = mad(coord, scalar, center);
Dfisheye.rsh20 static float2 center, neg_center, inv_dimensions, axis_scale;
24 center.x = center_x;
25 center.y = center_y;
26 neg_center = -center;
46 // Convert x and y to floating point coordinates with center as origin
54 const float2 new_coord = mad(coord, scalar, center);
/frameworks/rs/tests/java_api/ImageProcessing_jb/src/com/android/rs/image/
Dfisheye_approx.rsh20 static float2 center, neg_center, inv_dimensions, axis_scale;
24 center.x = center_x;
25 center.y = center_y;
26 neg_center = -center;
46 // Convert x and y to floating point coordinates with center as origin
54 const float2 new_coord = mad(coord, scalar, center);
Dfisheye.rsh20 static float2 center, neg_center, inv_dimensions, axis_scale;
24 center.x = center_x;
25 center.y = center_y;
26 neg_center = -center;
46 // Convert x and y to floating point coordinates with center as origin
54 const float2 new_coord = mad(coord, scalar, center);
/frameworks/rs/tests/java_api/ScriptGroupTest/src/com/android/rs/sgtest/
Dfisheye_approx_f.rsh20 static float2 center, neg_center, inv_dimensions, axis_scale;
26 center.x = center_x;
27 center.y = center_y;
28 neg_center = -center;
48 // Convert x and y to floating point coordinates with center as origin
56 const float2 new_coord = mad(coord, scalar, center);
/frameworks/base/media/mca/filterpacks/native/base/
Dgeometry.cpp137 bool SlantedRect::FromCenterAxisAndLengths(const Point& center, in FromCenterAxisAndLengths() argument
150 points_[0] = center - dx - dy; in FromCenterAxisAndLengths()
151 points_[1] = center + dx - dy; in FromCenterAxisAndLengths()
152 points_[2] = center - dx + dy; in FromCenterAxisAndLengths()
153 points_[3] = center + dx + dy; in FromCenterAxisAndLengths()
/frameworks/base/tests/Camera2Tests/SmartCamera/SimpleCamera/src/androidx/media/filterfw/geometry/
DQuad.java184 PointF center = center(); in rotated() local
188 PointF topLeft = rotatePoint(topLeft(), center, cosa, sina); in rotated()
189 PointF topRight = rotatePoint(topRight(), center, cosa, sina); in rotated()
190 PointF bottomLeft = rotatePoint(bottomLeft(), center, cosa, sina); in rotated()
191 PointF bottomRight = rotatePoint(bottomRight(), center, cosa, sina); in rotated()
218 public PointF center() { in center() method in Quad
249 PointF pc = center(); in grow()
/frameworks/base/libs/hwui/tests/common/scenes/
DHwBitmapInCompositeShader.cpp57 SkPoint center; in createContent() local
58 center.set(50, 50); in createContent()
63 center, 50, colors, nullptr, 2, SkTileMode::kRepeat); in createContent()
/frameworks/base/libs/hwui/pipeline/skia/
DSkiaVulkanPipeline.cpp82 SkPoint lightCenter = mVkSurface->getCurrentPreTransform().mapXY(lightGeometry.center.x, in draw()
83 lightGeometry.center.y); in draw()
85 localGeometry.center.x = lightCenter.fX; in draw()
86 localGeometry.center.y = lightCenter.fY; in draw()
/frameworks/rs/tests/java_api/VrDemo/src/com/example/android/rs/vr/engine/
Dbugdroid.rscript68 static float distanceCircle(float3 center, float radius, float3 normal,
70 float3 pc = img - center;
77 static short circle(float3 center, float circleRadius, float3 normal, float rad,
80 * sigmoid(distanceCircle(center, circleRadius, normal, img) - rad));
83 static float distanceDisk(float3 center, float radius, float3 normal,
85 float3 pc = img - center;
96 static short disk(float3 center, float circleRadius, float3 normal, float rad,
99 * sigmoid(distanceDisk(center, circleRadius, normal, img) - rad));
103 static short cogDisk(float3 center, float circleRadius, float3 normal,
105 float3 vec = center - img;
[all …]
/frameworks/av/media/libaudioprocessing/tests/
Dmixerops_tests.cpp68 const float center = (vola[0] + vola[1]) * 0.5; in testStereoVolume() local
76 EXPECT_EQ(center, audio); in testStereoVolume()
93 const float center = (vola[0] + vola[1] + volb[0] + volb[1]) * 0.5; in testStereoVolume() local
101 EXPECT_EQ(center, audio); in testStereoVolume()
/frameworks/libs/systemui/iconloaderlib/src/com/android/launcher3/icons/
DShadowGenerator.java158 int center = Math.max(centerX, centerY); in createPill() local
160 bounds.offsetTo(center - width / 2f, center - height / 2f); in createPill()
162 int size = center * 2; in createPill()
/frameworks/base/test-runner/src/android/test/
DViewAsserts.java298 int center = (reference.getMeasuredWidth() - test.getMeasuredWidth()) / 2; in assertHorizontalCenterAligned() local
301 assertEquals("views are not horizontally center aligned", center, delta); in assertHorizontalCenterAligned()
319 int center = (reference.getMeasuredHeight() - test.getMeasuredHeight()) / 2; in assertVerticalCenterAligned() local
322 assertEquals("views are not vertically center aligned", center, delta); in assertVerticalCenterAligned()
/frameworks/av/media/extractors/mp4/
DSampleTable.cpp737 uint32_t center = left + (right_plus_one - left) / 2; in findSampleAtTime() local
739 getSampleTime(center, scale_num, scale_den); in findSampleAtTime()
742 right_plus_one = center; in findSampleAtTime()
744 left = center + 1; in findSampleAtTime()
746 *sample_index = mSampleTimeEntries[center].mSampleIndex; in findSampleAtTime()
819 uint32_t center = left + (right_plus_one - left) / 2; in findSyncSampleNear() local
820 uint32_t x = mSyncSamples[center]; in findSyncSampleNear()
823 right_plus_one = center; in findSyncSampleNear()
825 left = center + 1; in findSyncSampleNear()
/frameworks/base/packages/SystemUI/src/com/android/systemui/wallet/ui/
DWalletCardCarousel.java251 float center = (float) getWidth() / 2f; in updateCardView() local
254 float position = (viewCenter - center) / viewWidth; in updateCardView()
264 viewCenter < center ? view.getRight() + mCardMarginPx in updateCardView()
267 if (Math.abs(viewCenter - center) < mCardCenterToScreenCenterDistancePx) { in updateCardView()
273 mEdgeToCenterDistance = edgePosition - center; in updateCardView()
274 mCardCenterToScreenCenterDistancePx = Math.abs(viewCenter - center); in updateCardView()
/frameworks/base/libs/hwui/
DLighting.h25 Vector3 center; member
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/shade/
DQsBatteryModeControllerTest.kt57 fun `returns MODE_ON for qqs with center cutout`() { in returns MODE_ON for qqs with center cutout()
65 fun `returns MODE_ESTIMATE for qs with center cutout`() { in returns MODE_ESTIMATE for qs with center cutout()

123