/aosp12/frameworks/rs/script_api/ |
H A D | rs_matrix.spec | 207 The matrix is first inverted then transposed. Returns true if the matrix was 219 Set the elements of a matrix from an array of floats or from another matrix. 276 summary: Load identity matrix 278 Set the elements of a matrix to the identity matrix. 293 by the first transformation matrix. E.g. to create a transformation matrix that applies 394 summary: Multiply a matrix by a vector or another matrix 396 For the matrix by matrix variant, sets m to the matrix product <code>m * rhs</code>. 520 Multiply the matrix m with a rotation matrix. 538 Multiply the matrix m with a scaling matrix. 557 Set an element of a matrix. [all …]
|
/aosp12/frameworks/base/tests/HwAccelerationTest/src/com/android/test/hwui/ |
H A D | Transform3dActivity.java | 61 final Matrix matrix = mMatrix; in onDraw() local 63 rotate(centerX, centerY, camera, matrix, 32.0f); in onDraw() 66 rotate(centerX, centerY, camera, matrix, 12.0f); in onDraw() 69 rotate(centerX, centerY, camera, matrix, 52.0f); in onDraw() 72 rotate(centerX, centerY, camera, matrix, 122.0f); in onDraw() 78 Matrix matrix) { in drawBitmap() argument 81 canvas.concat(matrix); in drawBitmap() 87 Matrix matrix, float angle) { in rotate() argument 90 camera.getMatrix(matrix); in rotate() 93 matrix.preTranslate(-centerX, -centerY); in rotate() [all …]
|
/aosp12/frameworks/base/core/java/com/android/internal/graphics/cam/ |
H A D | CamUtils.java | 129 float[][] matrix = SRGB_TO_XYZ; in yFromInt() local 130 float y = (r * matrix[1][0]) + (g * matrix[1][1]) + (b * matrix[1][2]); in yFromInt() 140 float[][] matrix = SRGB_TO_XYZ; in xyzFromInt() local 141 float x = (r * matrix[0][0]) + (g * matrix[0][1]) + (b * matrix[0][2]); in xyzFromInt() 142 float y = (r * matrix[1][0]) + (g * matrix[1][1]) + (b * matrix[1][2]); in xyzFromInt() 143 float z = (r * matrix[2][0]) + (g * matrix[2][1]) + (b * matrix[2][2]); in xyzFromInt()
|
H A D | Frame.java | 131 float[][] matrix = CamUtils.XYZ_TO_CAM16RGB; in make() local 133 float rW = (xyz[0] * matrix[0][0]) + (xyz[1] * matrix[0][1]) + (xyz[2] * matrix[0][2]); in make() 134 float gW = (xyz[0] * matrix[1][0]) + (xyz[1] * matrix[1][1]) + (xyz[2] * matrix[1][2]); in make() 135 float bW = (xyz[0] * matrix[2][0]) + (xyz[1] * matrix[2][1]) + (xyz[2] * matrix[2][2]); in make()
|
H A D | Cam.java | 157 float[][] matrix = CamUtils.XYZ_TO_CAM16RGB; in fromIntInFrame() local 158 float rT = (xyz[0] * matrix[0][0]) + (xyz[1] * matrix[0][1]) + (xyz[2] * matrix[0][2]); in fromIntInFrame() 159 float gT = (xyz[0] * matrix[1][0]) + (xyz[1] * matrix[1][1]) + (xyz[2] * matrix[1][2]); in fromIntInFrame() 160 float bT = (xyz[0] * matrix[2][0]) + (xyz[1] * matrix[2][1]) + (xyz[2] * matrix[2][2]); in fromIntInFrame() 323 float[][] matrix = CamUtils.CAM16RGB_TO_XYZ; in viewed() local 324 float x = (rF * matrix[0][0]) + (gF * matrix[0][1]) + (bF * matrix[0][2]); in viewed() 325 float y = (rF * matrix[1][0]) + (gF * matrix[1][1]) + (bF * matrix[1][2]); in viewed() 326 float z = (rF * matrix[2][0]) + (gF * matrix[2][1]) + (bF * matrix[2][2]); in viewed()
|
/aosp12/frameworks/opt/photoviewer/sample/src/com/example/photoviewersample/ |
H A D | SampleProvider.java | 72 addRow(matrix, PHOTO_INDIVIDUAL_1); in query() 73 addRow(matrix, PHOTO_INDIVIDUAL_2); in query() 74 addRow(matrix, PHOTO_INDIVIDUAL_3); in query() 75 addRow(matrix, PHOTO_INDIVIDUAL_4); in query() 80 addRow(matrix, PHOTO_INDIVIDUAL_1); in query() 83 addRow(matrix, PHOTO_INDIVIDUAL_2); in query() 97 return matrix; in query() 107 matrix.newRow() in addRow() 115 matrix.newRow() in addRow() 123 matrix.newRow() in addRow() [all …]
|
/aosp12/frameworks/opt/bitmap/src/com/android/bitmap/util/ |
H A D | RectUtils.java | 39 final Matrix matrix = new Matrix(); in rotateRectForOrientation() local 42 matrix.setRotate(-orientation); in rotateRectForOrientation() 45 matrix.mapRect(fullRectF); in rotateRectForOrientation() 46 matrix.mapRect(partialRectF); in rotateRectForOrientation() 48 matrix.reset(); in rotateRectForOrientation() 49 matrix.setTranslate(-fullRectF.left, -fullRectF.top); in rotateRectForOrientation() 50 matrix.mapRect(fullRectF); in rotateRectForOrientation() 51 matrix.mapRect(partialRectF); in rotateRectForOrientation() 61 final Matrix matrix = new Matrix(); in rotateRect() local 62 matrix.setRotate(degrees, px, py); in rotateRect() [all …]
|
/aosp12/frameworks/rs/script_api/include/ |
H A D | rs_matrix.rsh | 210 * The matrix is first inverted then transposed. Returns true if the matrix was 222 * Set the elements of a matrix from an array of floats or from another matrix. 241 * source: Source matrix. 286 * Set the elements of a matrix to the identity matrix. 420 * rsMatrixMultiply: Multiply a matrix by a vector or another matrix 422 * For the matrix by matrix variant, sets m to the matrix product m * rhs. 429 * by the matrix, ie. m * in. 440 * m: Left matrix of the product and the matrix to be set. 515 * Multiply the matrix m with a rotation matrix. 536 * Multiply the matrix m with a scaling matrix. [all …]
|
/aosp12/system/libvintf/xsd/compatibilityMatrix/api/ |
H A D | current.txt | 2 package compatibility.matrix { 12 method public compatibility.matrix.Avb getAvb(); 13 method public java.util.List<compatibility.matrix.Hal> getHal(); 16 method public compatibility.matrix.Sepolicy getSepolicy(); 17 method public compatibility.matrix.SystemSdk getSystemSdk(); 19 method public compatibility.matrix.VendorNdk getVendorNdk(); 21 method public compatibility.matrix.Vndk getVndk(); 23 method public void setAvb(compatibility.matrix.Avb); 25 method public void setSepolicy(compatibility.matrix.Sepolicy); 30 method public void setVndk(compatibility.matrix.Vndk); [all …]
|
/aosp12/packages/apps/Camera2/tests/src/com/android/camera/unittest/ |
H A D | CameraUnitTest.java | 29 Matrix matrix = new Matrix(); in testPrepareMatrix() local 33 CameraUtil.prepareMatrix(matrix, false, 0, 800, 480); in testPrepareMatrix() 36 matrix.mapPoints(points); in testPrepareMatrix() 39 CameraUtil.prepareMatrix(matrix, false, 90, 800, 480); in testPrepareMatrix() 42 matrix.mapPoints(points); in testPrepareMatrix() 45 CameraUtil.prepareMatrix(matrix, false, 180, 800, 480); in testPrepareMatrix() 48 matrix.mapPoints(points); in testPrepareMatrix() 51 CameraUtil.prepareMatrix(matrix, true, 180, 800, 480); in testPrepareMatrix() 54 matrix.mapPoints(points); in testPrepareMatrix()
|
/aosp12/frameworks/base/tests/VoiceInteraction/src/com/android/test/voiceinteraction/ |
H A D | AssistVisualizer.java | 38 final Matrix matrix; field in AssistVisualizer.TextEntry 53 this.matrix = new Matrix(matrix); in TextEntry() 97 Matrix matrix = new Matrix(); in setAssistStructure() local 99 mMatrixStack.add(matrix); in setAssistStructure() 147 Matrix matrix; 149 matrix = mMatrixStack.get(matrixStackIndex); 150 matrix.set(parentMatrix); 152 matrix = new Matrix(parentMatrix); 153 mMatrixStack.add(matrix); 160 matrix.preConcat(transform); [all …]
|
/aosp12/frameworks/base/tests/Camera2Tests/SmartCamera/SimpleCamera/src/androidx/media/filterfw/ |
H A D | ImageShader.java | 442 matrix[0] + matrix[12], in setSourceTransform() 443 matrix[1] + matrix[13], in setSourceTransform() 445 matrix[4] + matrix[12], in setSourceTransform() 446 matrix[5] + matrix[13], in setSourceTransform() 448 matrix[0] + matrix[4] + matrix[12], in setSourceTransform() 449 matrix[1] + matrix[5] + matrix[13], in setSourceTransform() 493 matrix[0] + matrix[12], in setTargetTransform() 494 matrix[1] + matrix[13], in setTargetTransform() 496 matrix[4] + matrix[12], in setTargetTransform() 499 matrix[0] + matrix[4] + matrix[12], in setTargetTransform() [all …]
|
/aosp12/frameworks/base/libs/hwui/pipeline/skia/ |
H A D | LayerDrawable.cpp | 42 static bool shouldFilterRect(const SkMatrix& matrix, const SkRect& srcRect, const SkRect& dstRect) { in shouldFilterRect() argument 43 if (!matrix.rectStaysRect()) return true; in shouldFilterRect() 44 SkRect dstDevRect = matrix.mapRect(dstRect); in shouldFilterRect() 46 if (MathUtils::isZero(matrix.getScaleX()) && MathUtils::isZero(matrix.getScaleY())) { in shouldFilterRect() 102 SkMatrix matrix; in DrawLayer() local 104 matrix = SkMatrix::Concat(layerTransform, textureMatrix); in DrawLayer() 106 matrix = textureMatrix; in DrawLayer() 113 const bool nonIdentityMatrix = !matrix.isIdentity(); in DrawLayer() 116 canvas->concat(matrix); in DrawLayer() 121 if (!matrix.invert(&matrixInv)) { in DrawLayer() [all …]
|
/aosp12/frameworks/base/libs/hwui/hwui/ |
H A D | AnimatedImageDrawable.cpp | 135 matrix->preTranslate(bounds.left(), bounds.top()); in handleBounds() 136 matrix->preScale(bounds.width() / intrinsicBounds.width(), in handleBounds() 146 SkMatrix matrix; in onDraw() local 151 matrix.preTranslate(mSkAnimatedImage->getBounds().width(), 0); in onDraw() 152 matrix.preScale(-1, 1); in onDraw() 163 canvas->concat(matrix); in onDraw() 174 (void) matrix.invert(&inverse); in onDraw() 241 SkMatrix matrix; in drawStaging() local 247 matrix.preScale(-1, 1); in drawStaging() 250 canvas->concat(matrix); in drawStaging() [all …]
|
/aosp12/frameworks/base/core/java/android/gesture/ |
H A D | OrientedBoundingBox.java | 60 Matrix matrix = new Matrix(); in toPath() local 61 matrix.setRotate(orientation); in toPath() 62 matrix.postTranslate(centerX, centerY); in toPath() 63 matrix.mapPoints(point); in toPath() 68 matrix.mapPoints(point); in toPath() 73 matrix.mapPoints(point); in toPath() 78 matrix.mapPoints(point); in toPath()
|
/aosp12/frameworks/base/libs/hwui/ |
H A D | Layer.cpp | 62 static bool shouldFilterRect(const SkMatrix& matrix, const SkRect& srcRect, const SkRect& dstRect) { in shouldFilterRect() argument 63 if (!matrix.rectStaysRect()) return true; in shouldFilterRect() 64 SkRect dstDevRect = matrix.mapRect(dstRect); in shouldFilterRect() 66 if (MathUtils::isZero(matrix.getScaleX()) && MathUtils::isZero(matrix.getScaleY())) { in shouldFilterRect() 115 SkMatrix matrix; in draw() local 116 matrix = SkMatrix::Concat(layerTransform, textureMatrix); in draw() 122 const bool nonIdentityMatrix = !matrix.isIdentity(); in draw() 125 canvas->concat(matrix); in draw()
|
H A D | RenderProperties.cpp | 106 SkMatrix* matrix) { in dumpMatrix() argument 107 if (matrix) { in dumpMatrix() 108 output << indent << "(" << label << " " << matrix << ": "; in dumpMatrix() 110 output << "[" << matrix->get(0) << " " << matrix->get(1) << " " << matrix->get(2) << "]"; in dumpMatrix() 111 output << " [" << matrix->get(3) << " " << matrix->get(4) << " " << matrix->get(5) << "]"; in dumpMatrix() 112 output << " [" << matrix->get(6) << " " << matrix->get(7) << " " << matrix->get(8) << "]"; in dumpMatrix()
|
/aosp12/packages/apps/LegacyCamera/tests/src/com/android/camera/unittest/ |
H A D | CameraTest.java | 77 Matrix matrix = new Matrix(); in testPrepareMatrix() local 81 Util.prepareMatrix(matrix, false, 0, 800, 480); in testPrepareMatrix() 84 matrix.mapPoints(points); in testPrepareMatrix() 87 Util.prepareMatrix(matrix, false, 90, 800, 480); in testPrepareMatrix() 90 matrix.mapPoints(points); in testPrepareMatrix() 93 Util.prepareMatrix(matrix, false, 180, 800, 480); in testPrepareMatrix() 96 matrix.mapPoints(points); in testPrepareMatrix() 99 Util.prepareMatrix(matrix, true, 180, 800, 480); in testPrepareMatrix() 102 matrix.mapPoints(points); in testPrepareMatrix()
|
/aosp12/frameworks/base/libs/hwui/jni/ |
H A D | ColorFilter.cpp | 47 float matrix[20]; in CreateColorMatrixFilter() local 48 env->GetFloatArrayRegion(jarray, 0, 20, matrix); in CreateColorMatrixFilter() 50 matrix[ 4] *= (1.0f/255); in CreateColorMatrixFilter() 51 matrix[ 9] *= (1.0f/255); in CreateColorMatrixFilter() 52 matrix[14] *= (1.0f/255); in CreateColorMatrixFilter() 53 matrix[19] *= (1.0f/255); in CreateColorMatrixFilter() 54 return reinterpret_cast<jlong>(SkColorFilters::Matrix(matrix).release()); in CreateColorMatrixFilter()
|
H A D | android_graphics_Matrix.cpp | 58 SkMatrix* matrix = reinterpret_cast<SkMatrix*>(matrixHandle); in mapPoints() local 76 SkMatrix* matrix = reinterpret_cast<SkMatrix*>(matrixHandle); in mapRect__RectFRectF() local 79 jboolean rectStaysRect = matrix->mapRect(&dst_, src_); in mapRect__RectFRectF() 86 SkMatrix* matrix = reinterpret_cast<SkMatrix*>(matrixHandle); in setRectToRect() local 111 result = matrix->setPolyToPoly((const SkPoint*) src, in setPolyToPoly() 122 dst[i] = matrix->get(i); in getValues() 133 matrix->set(i, src[i]); in setValues() 301 matrix->postSkew(kx, ky); in postSkew__FF() 307 matrix->postConcat(*other); in postConcat() 313 return matrix->invert(inverse); in invert() [all …]
|
/aosp12/frameworks/base/services/tests/servicestests/src/com/android/server/utils/ |
H A D | WatcherTest.java | 946 fill(matrix, size, indexes); in matrixGrow() 948 verify(matrix, indexes, null); in matrixGrow() 953 assertEquals(matrix.keyAt(matrix.indexOfKey(key)), key); in matrixGrow() 959 fill(matrix, size, indexes); in matrixDelete() 974 fill(matrix, size, indexes); in matrixShrink() 986 matrix.compact(); in matrixShrink() 989 assertTrue("Matrix shrink", finalCapacity - matrix.size() < matrix.STEP); in matrixShrink() 1019 matrix.deleteKey(INDEX_B); in testWatchedSparseBooleanMatrix() 1025 matrix.clear(); in testWatchedSparseBooleanMatrix() 1027 assertEquals(matrix.size(), 0); in testWatchedSparseBooleanMatrix() [all …]
|
/aosp12/frameworks/base/libs/hwui/tests/unit/ |
H A D | SkiaRenderPropertiesTests.cpp | 127 Matrix4 matrix; in TEST() local 128 matrix.loadTranslate(10, 10, 0); // left, top in TEST() 129 matrix.scale(1.2f, 1.2f, 1); // static matrix in TEST() 133 matrix.translate(10, 20); in TEST() 136 matrix.translate(50, 50); in TEST() 137 matrix.scale(0.5f, 0.7f, 1); in TEST() 138 matrix.translate(-50, -50); in TEST() 140 EXPECT_MATRIX_APPROX_EQ(matrix, actual) << "Op draw matrix must match expected " in TEST()
|
/aosp12/frameworks/base/core/java/android/view/ |
H A D | SyncRtSurfaceTransactionApplier.java | 106 t.setMatrix(params.surface, params.matrix, tmpFloat9); in applyParams() 169 Matrix matrix; field in SyncRtSurfaceTransactionApplier.SurfaceParams.Builder 196 public Builder withMatrix(Matrix matrix) { in withMatrix() argument 197 this.matrix = new Matrix(matrix); in withMatrix() 267 return new SurfaceParams(surface, flags, alpha, matrix, windowCrop, layer, in build() 272 private SurfaceParams(SurfaceControl surface, int params, float alpha, Matrix matrix, in SurfaceParams() argument 278 this.matrix = matrix; in SurfaceParams() 302 public final Matrix matrix; field in SyncRtSurfaceTransactionApplier.SurfaceParams
|
H A D | GhostView.java | 64 public void setMatrix(Matrix matrix) { in setMatrix() argument 65 mRenderNode.setAnimationMatrix(matrix); in setMatrix() 92 matrix.reset(); in calculateMatrix() 93 parent.transformMatrixToGlobal(matrix); in calculateMatrix() 95 host.transformMatrixToLocal(matrix); in calculateMatrix() 117 if (matrix == null) { in addGhost() 118 matrix = new Matrix(); in addGhost() 119 calculateMatrix(view, viewGroup, matrix); in addGhost() 122 ghostView.setMatrix(matrix); in addGhost() 132 } else if (matrix != null) { in addGhost() [all …]
|
/aosp12/frameworks/base/services/core/java/com/android/server/display/color/ |
H A D | AppSaturationController.java | 136 static void computeGrayscaleTransformMatrix(float saturation, float[] matrix) { in computeGrayscaleTransformMatrix() argument 140 matrix[0] = luminance[0] + saturation; in computeGrayscaleTransformMatrix() 141 matrix[1] = luminance[0]; in computeGrayscaleTransformMatrix() 142 matrix[2] = luminance[0]; in computeGrayscaleTransformMatrix() 143 matrix[3] = luminance[1]; in computeGrayscaleTransformMatrix() 144 matrix[4] = luminance[1] + saturation; in computeGrayscaleTransformMatrix() 145 matrix[5] = luminance[1]; in computeGrayscaleTransformMatrix() 146 matrix[6] = luminance[2]; in computeGrayscaleTransformMatrix() 147 matrix[7] = luminance[2]; in computeGrayscaleTransformMatrix() 148 matrix[8] = luminance[2] + saturation; in computeGrayscaleTransformMatrix()
|