Home
last modified time | relevance | path

Searched refs:coords (Results 1 – 25 of 49) sorted by relevance

12

/frameworks/layoutlib/bridge/src/com/android/layoutlib/bridge/util/
DCachedPathIteratorFactory.java128 private static void quadCurveSegment(float[] coords, float t0, float t1) { in quadCurveSegment() argument
132 float mx = mu * mu * coords[0] + 2 * mu * mt * coords[2] + mt * mt * coords[4]; in quadCurveSegment()
133 float my = mu * mu * coords[1] + 2 * mu * mt * coords[3] + mt * mt * coords[5]; in quadCurveSegment()
139 coords[0] = coords[0] * u0 * u0 + coords[2] * 2 * t0 * u0 + coords[4] * t0 * t0; in quadCurveSegment()
140 coords[1] = coords[1] * u0 * u0 + coords[3] * 2 * t0 * u0 + coords[5] * t0 * t0; in quadCurveSegment()
143 coords[4] = coords[0] * u1 * u1 + coords[2] * 2 * t1 * u1 + coords[4] * t1 * t1; in quadCurveSegment()
144 coords[5] = coords[1] * u1 * u1 + coords[3] * 2 * t1 * u1 + coords[5] * t1 * t1; in quadCurveSegment()
147 coords[2] = 2 * mx - coords[0] / 2 - coords[4] / 2; in quadCurveSegment()
148 coords[3] = 2 * my - coords[1] / 2 - coords[5] / 2; in quadCurveSegment()
151 private static void cubicCurveSegment(float[] coords, float t0, float t1) { in cubicCurveSegment() argument
[all …]
/frameworks/av/services/camera/libcameraservice/device3/
DDistortionMapper.cpp219 quad->coords[0], quad->coords[1], in mapRawToCorrected()
220 quad->coords[2], quad->coords[3], in mapRawToCorrected()
221 quad->coords[4], quad->coords[5], in mapRawToCorrected()
222 quad->coords[6], quad->coords[7]); in mapRawToCorrected()
230 corrQuad->coords[0], corrQuad->coords[1], in mapRawToCorrected()
231 corrQuad->coords[2], corrQuad->coords[3], in mapRawToCorrected()
232 corrQuad->coords[4], corrQuad->coords[5], in mapRawToCorrected()
233 corrQuad->coords[6], corrQuad->coords[7]); in mapRawToCorrected()
241 float corrX = corrQuad->coords[0] + u * (corrQuad->coords[2] - corrQuad->coords[0]); in mapRawToCorrected()
243 float corrY = corrQuad->coords[1] + v * (corrQuad->coords[7] - corrQuad->coords[1]); in mapRawToCorrected()
[all …]
DZoomRatioMapper.cpp361 int32_t coords[4] = { in scaleRects() local
369 scaleCoordinates(coords, 1, scaleRatio, true /*clamp*/); in scaleRects()
371 scaleCoordinates(coords+2, 1, scaleRatio, true /*clamp*/); in scaleRects()
374 rects[i] = coords[0]; in scaleRects()
375 rects[i + 1] = coords[1]; in scaleRects()
376 rects[i + 2] = coords[2] - coords[0] + 1; in scaleRects()
377 rects[i + 3] = coords[3] - coords[1] + 1; in scaleRects()
/frameworks/native/libs/input/tests/
DInputEvent_test.cpp42 PointerCoords coords; in TEST_F() local
43 coords.clear(); in TEST_F()
45 ASSERT_EQ(0ULL, coords.bits); in TEST_F()
49 PointerCoords coords; in TEST_F() local
50 coords.clear(); in TEST_F()
53 ASSERT_EQ(0, coords.getAxisValue(0)) in TEST_F()
55 ASSERT_EQ(0, coords.getAxisValue(1)) in TEST_F()
59 ASSERT_EQ(OK, coords.setAxisValue(1, 5)); in TEST_F()
60 ASSERT_EQ(5, coords.values[0]); in TEST_F()
61 ASSERT_EQ(0x4000000000000000ULL, coords.bits); in TEST_F()
[all …]
/frameworks/native/services/inputflinger/tests/
DInputClassifierConverter_test.cpp35 PointerCoords coords; in generateBasicMotionArgs() local
36 coords.clear(); in generateBasicMotionArgs()
37 coords.setAxisValue(AMOTION_EVENT_AXIS_X, 1); in generateBasicMotionArgs()
38 coords.setAxisValue(AMOTION_EVENT_AXIS_Y, 2); in generateBasicMotionArgs()
39 coords.setAxisValue(AMOTION_EVENT_AXIS_SIZE, 0.5); in generateBasicMotionArgs()
46 &coords, 0 /*xPrecision*/, 0 /*yPrecision*/, in generateBasicMotionArgs()
53 static float getMotionEventAxis(common::V1_0::PointerCoords coords, in getMotionEventAxis() argument
55 uint32_t index = BitSet64::getIndexOfBit(static_cast<uint64_t>(coords.bits), in getMotionEventAxis()
57 return coords.values[index]; in getMotionEventAxis()
DInputClassifier_test.cpp39 PointerCoords coords; in generateBasicMotionArgs() local
40 coords.clear(); in generateBasicMotionArgs()
41 coords.setAxisValue(AMOTION_EVENT_AXIS_X, 1); in generateBasicMotionArgs()
42 coords.setAxisValue(AMOTION_EVENT_AXIS_Y, 1); in generateBasicMotionArgs()
49 &coords, 0 /*xPrecision*/, 0 /*yPrecision*/, in generateBasicMotionArgs()
/frameworks/base/opengl/java/javax/microedition/khronos/opengles/
DGL11Ext.java55 float[] coords, in glDrawTexfvOES() argument
60 java.nio.FloatBuffer coords in glDrawTexfvOES() argument
72 int[] coords, in glDrawTexivOES() argument
77 java.nio.IntBuffer coords in glDrawTexivOES() argument
89 short[] coords, in glDrawTexsvOES() argument
94 java.nio.ShortBuffer coords in glDrawTexsvOES() argument
106 int[] coords, in glDrawTexxvOES() argument
111 java.nio.IntBuffer coords in glDrawTexxvOES() argument
/frameworks/av/services/camera/libcameraservice/tests/
DDistortionMapperTest.cpp134 auto coords = basicCoords; in TEST() local
135 res = m.mapCorrectedToRaw(coords.data(), 5, /*clamp*/true); in TEST()
138 for (size_t i = 0; i < coords.size(); i++) { in TEST()
139 EXPECT_EQ(coords[i], basicCoords[i]); in TEST()
142 res = m.mapRawToCorrected(coords.data(), 5, /*clamp*/true); in TEST()
145 for (size_t i = 0; i < coords.size(); i++) { in TEST()
146 EXPECT_EQ(coords[i], basicCoords[i]); in TEST()
202 auto coords = basicCoords; in TEST() local
203 res = m.mapCorrectedToRaw(coords.data(), 5, /*clamp*/true, /*simple*/true); in TEST()
206 ASSERT_EQ(coords[0], 0); ASSERT_EQ(coords[1], 0); in TEST()
[all …]
DZoomRatioTest.cpp184 auto coords = originalCoords; in subScaleCoordinatesTest() local
185 mapper.scaleCoordinates(coords.data(), coords.size()/2, 1.0f, false /*clamp*/); in subScaleCoordinatesTest()
186 for (size_t i = 0; i < coords.size(); i++) { in subScaleCoordinatesTest()
187 EXPECT_EQ(coords[i], originalCoords[i]); in subScaleCoordinatesTest()
201 coords = originalCoords; in subScaleCoordinatesTest()
202 mapper.scaleCoordinates(coords.data(), coords.size()/2, 2.0f, false /*clamp*/); in subScaleCoordinatesTest()
203 for (size_t i = 0; i < coords.size(); i++) { in subScaleCoordinatesTest()
204 EXPECT_LE(std::abs(coords[i] - expected2xCoords[i]), kMaxAllowedPixelError); in subScaleCoordinatesTest()
218 coords = originalCoords; in subScaleCoordinatesTest()
219 mapper.scaleCoordinates(coords.data(), coords.size()/2, 2.0f, true /*clamp*/); in subScaleCoordinatesTest()
[all …]
/frameworks/base/core/tests/coretests/src/android/view/
DMotionEventTest.java50 final PointerCoords[] coords = new PointerCoords[pointerCount]; in testObtainWithDisplayId() local
55 coords[i] = c; in testObtainWithDisplayId()
64 pointerCount, properties, coords, in testObtainWithDisplayId()
84 pointerCount, properties, coords, in testObtainWithDisplayId()
125 final PointerCoords[] coords = new PointerCoords[pointerCount]; in testCalculatesCursorPositionForMultiTouchMouseEvents() local
132 coords[i] = new PointerCoords(); in testCalculatesCursorPositionForMultiTouchMouseEvents()
133 coords[i].x = 20 + i * 20; in testCalculatesCursorPositionForMultiTouchMouseEvents()
134 coords[i].y = 60 - i * 20; in testCalculatesCursorPositionForMultiTouchMouseEvents()
138 0 /* eventTime */, ACTION_POINTER_DOWN, pointerCount, properties, coords, in testCalculatesCursorPositionForMultiTouchMouseEvents()
DViewGroupTest.java72 MotionEvent.PointerCoords[] coords = new MotionEvent.PointerCoords[2]; in testDispatchMouseEventsUnderCursor() local
73 coords[0] = new MotionEvent.PointerCoords(); in testDispatchMouseEventsUnderCursor()
74 coords[0].x = 80; in testDispatchMouseEventsUnderCursor()
75 coords[0].y = 100; in testDispatchMouseEventsUnderCursor()
76 coords[1] = new MotionEvent.PointerCoords(); in testDispatchMouseEventsUnderCursor()
77 coords[1].x = 240; in testDispatchMouseEventsUnderCursor()
78 coords[1].y = 100; in testDispatchMouseEventsUnderCursor()
84 2 /* pointerCount */, properties, coords, 0 /* metaState */, 0 /* buttonState */, in testDispatchMouseEventsUnderCursor()
92 2 /* pointerCount */, properties, coords, 0 /* metaState */, 0 /* buttonState */, in testDispatchMouseEventsUnderCursor()
/frameworks/layoutlib/bridge/src/com/android/layoutlib/bridge/impl/
DGcSnapshot.java617 double[] coords = new double[16]; in transformRect() local
618 coords[0] = rect.x; in transformRect()
619 coords[1] = rect.y; in transformRect()
620 coords[2] = rect.x + rect.width; in transformRect()
621 coords[3] = rect.y + rect.height; in transformRect()
622 coords[4] = rect.x; in transformRect()
623 coords[5] = rect.y + rect.height; in transformRect()
624 coords[6] = rect.x + rect.width; in transformRect()
625 coords[7] = rect.y; in transformRect()
626 transform.transform(coords, 0, coords, 8, 4); in transformRect()
[all …]
/frameworks/native/opengl/tools/glgen/specs/jsr239/
Dglspec-1.1ext3 void glDrawTexfvOES ( const GLfloat *coords )
5 void glDrawTexivOES ( const GLint *coords )
7 void glDrawTexsvOES ( const GLshort *coords )
9 void glDrawTexxvOES ( const GLfixed *coords )
Dglspec-checks28 glDrawTexfvOES check coords 5
29 glDrawTexivOES check coords 5
30 glDrawTexsvOES check coords 5
31 glDrawTexxvOES check coords 5
/frameworks/base/services/accessibility/java/com/android/server/accessibility/gestures/
DEventDispatcher.java202 PointerCoords[] coords = PointerCoords.createArray(pointerCount); in offsetEvent() local
205 event.getPointerCoords(i, coords[i]); in offsetEvent()
207 coords[i].x += offsetX; in offsetEvent()
208 coords[i].y += offsetY; in offsetEvent()
217 coords, in offsetEvent()
346 PointerCoords[] coords = new PointerCoords[1]; in clickWithTouchEvents() local
347 coords[0] = new PointerCoords(); in clickWithTouchEvents()
348 coords[0].x = clickLocation.x; in clickWithTouchEvents()
349 coords[0].y = clickLocation.y; in clickWithTouchEvents()
357 coords, in clickWithTouchEvents()
/frameworks/layoutlib/bridge/src/android/graphics/
DRoundRectangle.java334 public int currentSegment(float[] coords) { in getPathIterator() argument
341 coords[nc++] = (float) (x + ctrls[i] * width + ctrls[i + 1] / 2d); in getPathIterator()
342 coords[nc++] = (float) (y + ctrls[i + 2] * height + ctrls[i + 3] / 2d); in getPathIterator()
345 at.transform(coords, 0, coords, 0, nc / 2); in getPathIterator()
351 public int currentSegment(double[] coords) { in getPathIterator() argument
358 coords[nc++] = x + ctrls[i] * width + ctrls[i + 1] / 2d; in getPathIterator()
359 coords[nc++] = y + ctrls[i + 2] * height + ctrls[i + 3] / 2d; in getPathIterator()
362 at.transform(coords, 0, coords, 0, nc / 2); in getPathIterator()
/frameworks/base/core/java/com/android/internal/widget/
DPointerLocationView.java482 MotionEvent.PointerCoords coords, int id, MotionEvent event) { in logCoords() argument
539 .append(" (").append(coords.x, 3).append(", ").append(coords.y, 3) in logCoords()
540 .append(") Pressure=").append(coords.pressure, 3) in logCoords()
541 .append(" Size=").append(coords.size, 3) in logCoords()
542 .append(" TouchMajor=").append(coords.touchMajor, 3) in logCoords()
543 .append(" TouchMinor=").append(coords.touchMinor, 3) in logCoords()
544 .append(" ToolMajor=").append(coords.toolMajor, 3) in logCoords()
545 .append(" ToolMinor=").append(coords.toolMinor, 3) in logCoords()
546 .append(" Orientation=").append((float)(coords.orientation * 180 / Math.PI), 1) in logCoords()
549 coords.getAxisValue(MotionEvent.AXIS_TILT) * 180 / Math.PI), 1) in logCoords()
[all …]
/frameworks/ml/nn/tools/test_generator/
Dspec_visualizer.py137 coords = {}
140 coords[node] = (CoordX(layer_cnt[layers[node]]), CoordY(layers[node]))
163 "x": coords[op][0],
164 "y": coords[op][1],
173 "x": coords[op][0],
174 "y": coords[op][1],
/frameworks/base/opengl/java/android/opengl/
DGLES11Ext.java199 short[] coords, in glDrawTexsvOES() argument
206 java.nio.ShortBuffer coords in glDrawTexsvOES() argument
212 int[] coords, in glDrawTexivOES() argument
219 java.nio.IntBuffer coords in glDrawTexivOES() argument
225 int[] coords, in glDrawTexxvOES() argument
232 java.nio.IntBuffer coords in glDrawTexxvOES() argument
248 float[] coords, in glDrawTexfvOES() argument
255 java.nio.FloatBuffer coords in glDrawTexfvOES() argument
DGLErrorWrapper.java879 public void glDrawTexfvOES(float[] coords, int offset) { in glDrawTexfvOES() argument
881 mgl11Ext.glDrawTexfvOES(coords, offset); in glDrawTexfvOES()
885 public void glDrawTexfvOES(FloatBuffer coords) { in glDrawTexfvOES() argument
887 mgl11Ext.glDrawTexfvOES(coords); in glDrawTexfvOES()
897 public void glDrawTexivOES(int[] coords, int offset) { in glDrawTexivOES() argument
899 mgl11Ext.glDrawTexivOES(coords, offset); in glDrawTexivOES()
903 public void glDrawTexivOES(IntBuffer coords) { in glDrawTexivOES() argument
905 mgl11Ext.glDrawTexivOES(coords); in glDrawTexivOES()
916 public void glDrawTexsvOES(short[] coords, int offset) { in glDrawTexsvOES() argument
918 mgl11Ext.glDrawTexsvOES(coords, offset); in glDrawTexsvOES()
[all …]
/frameworks/native/opengl/tools/glgen/specs/gles11/
Dchecks.spec39 glDrawTexfvOES check coords 5
40 glDrawTexivOES check coords 5
41 glDrawTexsvOES check coords 5
42 glDrawTexxvOES check coords 5
DGLES11Ext.spec7 void glDrawTexsvOES ( const GLshort *coords )
8 void glDrawTexivOES ( const GLint *coords )
9 void glDrawTexxvOES ( const GLfixed *coords )
11 void glDrawTexfvOES ( const GLfloat *coords )
/frameworks/base/media/mca/filterfw/native/core/
Dshader_program.h451 bool PushCoords(ProgramVar attr, float* coords);
454 bool PushSourceCoords(float* coords);
457 bool PushTargetCoords(float* coords);
/frameworks/base/tests/Camera2Tests/SmartCamera/SimpleCamera/src/androidx/media/filterfw/
DImageShader.java426 public void setSourceCoords(float[] coords) { in setSourceCoords() argument
427 if (coords.length != 8) { in setSourceCoords()
429 + "got " + coords.length + " coordinates!"); in setSourceCoords()
431 mSourceCoords = Arrays.copyOf(coords, 8); in setSourceCoords()
474 public void setTargetCoords(float[] coords) { in setTargetCoords() argument
475 if (coords.length != 8) { in setTargetCoords()
477 + "got " + coords.length + " coordinates!"); in setTargetCoords()
481 mTargetCoords[i] = coords[i] * 2f - 1f; in setTargetCoords()
/frameworks/native/opengl/tests/gldual/src/com/android/gldual/
DTriangleRenderer.java133 float[] coords = { in Triangle() local
142 mFVertexBuffer.put(coords[i*3+j] * 2.0f); in Triangle()

12