Home
last modified time | relevance | path

Searched full:matrix (Results 1 – 25 of 536) sorted by relevance

12345678910>>...22

/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/util/
DMatrixTest.java32 * Unit tests for {@link com.android.server.wifi.util.Matrix}.
41 assertEquals(new Matrix(3, 2), new Matrix(2, new double[]{0, 0, 0, 0, 0, 0})); in testConstructors()
49 Matrix m1 = new Matrix(0, 20); in testDegenerate()
50 Matrix m2 = new Matrix(20, 0); in testDegenerate()
59 Matrix m1 = new Matrix(2, new double[]{1, 2, 3, 4}); in testAddition()
60 Matrix m2 = new Matrix(2, new double[]{10, 20, 30, 40}); in testAddition()
61 Matrix m3 = new Matrix(2, new double[]{11, 22, 33, 44}); in testAddition()
70 Matrix m1 = new Matrix(2, new double[]{1, 2, 3, 4}); in testSubtraction()
71 Matrix m2 = new Matrix(2, new double[]{10, 20, 30, 40}); in testSubtraction()
72 Matrix m3 = new Matrix(2, new double[]{11, 22, 33, 44}); in testSubtraction()
[all …]
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/util/
DMatrix.java22 public class Matrix { class
28 * Creates a new matrix, initialized to zeros
33 public Matrix(int rows, int cols) { in Matrix() method in Matrix
40 * Creates a new matrix using the provided array of values
48 public Matrix(int stride, double[] values) { in Matrix() method in Matrix
56 * Creates a new matrix duplicating the given one
58 * @param that is the source Matrix.
60 public Matrix(Matrix that) { in Matrix() method in Matrix
70 * Gets the matrix coefficient from row i, column j
83 * Store a matrix coefficient in row i, column j
[all …]
/frameworks/rs/script_api/
Drs_matrix.spec18 summary: Matrix Functions
28 a vector is done by postmultiplying the vector, e.g. <code>(matrix * vector)</code>,
31 To create a transformation matrix that performs two transformations at once,
33 argument. E.g. to create a transformation matrix that applies the
39 style simply stores the transformation matrix in the first argument. The latter
40 modifies a pre-existing transformation matrix so that the new transformation
41 happens first. E.g. if you call @rsMatrixTranslate() on a matrix that already
42 does a scaling, the resulting matrix when applied to a vector will first do the
51 arg: const rs_matrix4x4* viewProj, "Matrix to extract planes from."
60 Computes 6 frustum planes from the view projection matrix
[all …]
/frameworks/rs/script_api/include/
Drs_matrix.rsh20 * rs_matrix.rsh: Matrix Functions
30 * a vector is done by postmultiplying the vector, e.g. (matrix * vector),
33 * To create a transformation matrix that performs two transformations at once,
35 * argument. E.g. to create a transformation matrix that applies the
41 * style simply stores the transformation matrix in the first argument. The latter
42 * modifies a pre-existing transformation matrix so that the new transformation
43 * happens first. E.g. if you call rsMatrixTranslate() on a matrix that already
44 * does a scaling, the resulting matrix when applied to a vector will first do the
56 * Computes 6 frustum planes from the view projection matrix
59 * viewProj: Matrix to extract planes from.
[all …]
/frameworks/native/libs/math/include/math/
DTMatHelpers.h64 * Matrix utilities
67 namespace matrix {
78 * Matrix inversion
80 template<typename MATRIX>
81 MATRIX PURE gaussJordanInverse(const MATRIX& src) { in gaussJordanInverse()
82 typedef typename MATRIX::value_type T; in gaussJordanInverse()
83 static constexpr unsigned int N = MATRIX::NUM_ROWS; in gaussJordanInverse()
84 MATRIX tmp(src); in gaussJordanInverse()
85 MATRIX inverted(1); in gaussJordanInverse()
128 // 2x2 matrix inverse is easy.
[all …]
/frameworks/base/graphics/java/android/graphics/
DMatrix.java29 * The Matrix class holds a 3x3 matrix for transforming coordinates.
31 public class Matrix { class
45 public final static Matrix IDENTITY_MATRIX = new Matrix() {
47 throw new IllegalStateException("Matrix can not be modified");
51 public void set(Matrix src) {
106 public boolean setConcat(Matrix a, Matrix b) {
154 public boolean preConcat(Matrix other) {
202 public boolean postConcat(Matrix other) {
229 Matrix.class.getClassLoader(), nGetNativeFinalizer());
239 * Create an identity matrix
[all …]
DColorMatrixColorFilter.java24 * A color filter that transforms colors through a 4x5 color matrix. This filter
34 * Create a color filter that transforms colors through a 4x5 color matrix.
36 * @param matrix 4x5 matrix used to transform colors. It is copied into
37 * the filter, so changes made to the matrix after the filter
40 public ColorMatrixColorFilter(@NonNull ColorMatrix matrix) { in ColorMatrixColorFilter() argument
41 mMatrix.set(matrix); in ColorMatrixColorFilter()
45 * Create a color filter that transforms colors through a 4x5 color matrix.
48 * matrix. The first 20 entries of the array are copied into
68 * Copies the provided color matrix to be used by this filter.
70 * If the specified color matrix is null, this filter's color matrix will be reset to the
[all …]
/frameworks/base/core/java/android/transition/
DChangeImageTransform.java22 import android.graphics.Matrix;
34 * This Transition captures an ImageView's matrix before and after the
45 private static final String PROPNAME_MATRIX = "android:changeImageTransform:matrix";
53 private static TypeEvaluator<Matrix> NULL_MATRIX_EVALUATOR = new TypeEvaluator<Matrix>() {
55 public Matrix evaluate(float fraction, Matrix startValue, Matrix endValue) {
60 private static Property<ImageView, Matrix> ANIMATED_TRANSFORM_PROPERTY
61 = new Property<ImageView, Matrix>(Matrix.class, "animatedTransform") {
63 public void set(ImageView object, Matrix value) {
68 public Matrix get(ImageView object) {
98 Matrix matrix; in captureValues() local
[all …]
DChangeTransform.java25 import android.graphics.Matrix;
48 private static final String PROPNAME_MATRIX = "android:changeTransform:matrix";
64 * This property sets the animation matrix properties that are not translations.
80 * This property sets the translation animation matrix properties.
97 private Matrix mTempMatrix = new Matrix();
194 Matrix matrix = view.getMatrix(); in captureValues() local
195 if (matrix == null || matrix.isIdentity()) { in captureValues()
196 matrix = null; in captureValues()
198 matrix = new Matrix(matrix); in captureValues()
200 transitionValues.values.put(PROPNAME_MATRIX, matrix); in captureValues()
[all …]
DTransitionUtils.java24 import android.graphics.Matrix;
90 Matrix matrix = new Matrix(); in copyViewImage() local
91 matrix.setTranslate(-parent.getScrollX(), -parent.getScrollY()); in copyViewImage()
92 view.transformMatrixToGlobal(matrix); in copyViewImage()
93 sceneRoot.transformMatrixToLocal(matrix); in copyViewImage()
95 matrix.mapRect(bounds); in copyViewImage()
103 Bitmap bitmap = createViewBitmap(view, matrix, bounds, sceneRoot); in copyViewImage()
146 * Creates a Bitmap of the given view, using the Matrix matrix to transform to the local
147 * coordinates. <code>matrix</code> will be modified during the bitmap creation.
151 * @param matrix The matrix converting the view local coordinates to the coordinates that
[all …]
/frameworks/base/tests/HwAccelerationTest/src/com/android/test/hwui/
DTransform3dActivity.java25 import android.graphics.Matrix;
41 private Matrix mMatrix;
48 mMatrix = new Matrix(); in Transform3dView()
61 final Matrix matrix = mMatrix; in onDraw() local
63 rotate(centerX, centerY, camera, matrix, 32.0f); in onDraw()
64 drawBitmap(canvas, centerX, centerY, 0.0f, matrix); in onDraw()
66 rotate(centerX, centerY, camera, matrix, 12.0f); in onDraw()
67 drawBitmap(canvas, centerX, centerY, -mBitmap1.getWidth(), matrix); in onDraw()
69 rotate(centerX, centerY, camera, matrix, 52.0f); in onDraw()
70 drawBitmap(canvas, centerX, centerY, mBitmap1.getWidth(), matrix); in onDraw()
[all …]
/frameworks/base/tests/VoiceInteraction/src/com/android/test/voiceinteraction/
DAssistVisualizer.java23 import android.graphics.Matrix;
38 final Matrix matrix; field in AssistVisualizer.TextEntry
47 TextEntry(AssistStructure.ViewNode node, int parentLeft, int parentTop, Matrix matrix) { in TextEntry() argument
53 this.matrix = new Matrix(matrix); in TextEntry()
68 final ArrayList<Matrix> mMatrixStack = new ArrayList<>();
97 Matrix matrix = new Matrix(); in setAssistStructure() local
98 matrix.setTranslate(windowNode.getLeft(), windowNode.getTop()); in setAssistStructure()
99 mMatrixStack.add(matrix); in setAssistStructure()
120 + " matrix=" + te.matrix.toShortString() in logText()
145 Matrix parentMatrix = mMatrixStack.get(matrixStackIndex);
[all …]
/frameworks/base/rs/java/android/renderscript/
DScriptIntrinsicBLAS.java28 * building blocks for performing basic vector and matrix operations.
306 * SGEMV performs one of the matrix-vector operations
311 * @param TransA The type of transpose applied to matrix A.
313 * @param A The input allocation contains matrix A, supported elements type {@link Element#F32}.
328 * DGEMV performs one of the matrix-vector operations
333 * @param TransA The type of transpose applied to matrix A.
335 * @param A The input allocation contains matrix A, supported elements type {@link Element#F64}.
350 * CGEMV performs one of the matrix-vector operations
355 * @param TransA The type of transpose applied to matrix A.
357 … * @param A The input allocation contains matrix A, supported elements type {@link Element#F32_2}.
[all …]
DMatrix3f.java27 * Creates a new identity 3x3 matrix
35 * Creates a new matrix and sets its values from the given
38 * @param dataArray values to set the matrix to, must be 9
47 * Return a reference to the internal array representing matrix
48 * values. Modifying this array will also change the matrix
50 * @return internal array representing the matrix
79 * Sets the matrix values to identity
96 * Sets the values of the matrix to those of the parameter
98 * @param src matrix to load the values from
105 * Sets current values to be a rotation matrix of certain angle
[all …]
DMatrix2f.java27 * Creates a new identity 2x2 matrix
35 * Creates a new matrix and sets its values from the given
38 * @param dataArray values to set the matrix to, must be 4
47 * Return a reference to the internal array representing matrix
48 * values. Modifying this array will also change the matrix
50 * @return internal array representing the matrix
79 * Sets the matrix values to identity
90 * Sets the values of the matrix to those of the parameter
92 * @param src matrix to load the values from
99 * Sets current values to be a rotation matrix of given angle
[all …]
/frameworks/rs/cpp/
DrsCppStructs.h1817 * building blocks for performing basic vector and matrix operations.
1835 * SGEMV performs one of the matrix-vector operations
1840 * @param TransA The type of transpose applied to matrix A.
1842 * @param A The input allocation contains matrix A, supported elements type: {Element#F32}.
1854 * DGEMV performs one of the matrix-vector operations
1859 * @param TransA The type of transpose applied to matrix A.
1861 * @param A The input allocation contains matrix A, supported elements type: {Element#F64}.
1873 * CGEMV performs one of the matrix-vector operations
1878 * @param TransA The type of transpose applied to matrix A.
1880 * @param A The input allocation contains matrix A, supported elements type: {Element#F32_2}.
[all …]
/frameworks/rs/support/java/src/androidx/renderscript/
DScriptIntrinsicBLAS.java28 * building blocks for performing basic vector and matrix operations.
313 * SGEMV performs one of the matrix-vector operations
318 * @param TransA The type of transpose applied to matrix A.
320 * @param A The input allocation contains matrix A, supported elements type {@link Element#F32}.
345 * DGEMV performs one of the matrix-vector operations
350 * @param TransA The type of transpose applied to matrix A.
352 * @param A The input allocation contains matrix A, supported elements type {@link Element#F64}.
377 * CGEMV performs one of the matrix-vector operations
382 * @param TransA The type of transpose applied to matrix A.
384 … * @param A The input allocation contains matrix A, supported elements type {@link Element#F32_2}.
[all …]
DMatrix3f.java30 * Creates a new identity 3x3 matrix
38 * Creates a new matrix and sets its values from the given
41 * @param dataArray values to set the matrix to, must be 9
50 * Return a reference to the internal array representing matrix
51 * values. Modifying this array will also change the matrix
53 * @return internal array representing the matrix
82 * Sets the matrix values to identity
99 * Sets the values of the matrix to those of the parameter
101 * @param src matrix to load the values from
108 * Sets current values to be a rotation matrix of certain angle
[all …]
DMatrix2f.java30 * Creates a new identity 2x2 matrix
38 * Creates a new matrix and sets its values from the given
41 * @param dataArray values to set the matrix to, must be 4
50 * Return a reference to the internal array representing matrix
51 * values. Modifying this array will also change the matrix
53 * @return internal array representing the matrix
82 * Sets the matrix values to identity
93 * Sets the values of the matrix to those of the parameter
95 * @param src matrix to load the values from
102 * Sets current values to be a rotation matrix of given angle
[all …]
/frameworks/base/services/core/java/com/android/server/wm/utils/
DCoordinateTransforms.java26 import android.graphics.Matrix;
38 * Sets a matrix such that given a rotation, it transforms physical display
41 * @param rotation the rotation to which the matrix should transform
42 * @param out the matrix to be set
45 @Dimension int physicalWidth, @Dimension int physicalHeight, Matrix out) { in transformPhysicalToLogicalCoordinates()
68 * Sets a matrix such that given a rotation, it transforms that rotation's logical coordinates
71 * @param rotation the rotation to which the matrix should transform
72 * @param out the matrix to be set
75 @Dimension int physicalWidth, @Dimension int physicalHeight, Matrix out) { in transformLogicalToPhysicalCoordinates()
98 * Sets a matrix such that given a two rotations, that it transforms coordinates given in the
[all …]
/frameworks/base/libs/hwui/pipeline/skia/
DLayerDrawable.cpp36 // This is a less-strict matrix.isTranslate() that will still report being translate-only
38 static bool isBasicallyTranslate(const SkMatrix& matrix) { in isBasicallyTranslate() argument
39 if (!matrix.isScaleTranslate()) return false; in isBasicallyTranslate()
40 return MathUtils::isOne(matrix.getScaleX()) && MathUtils::isOne(matrix.getScaleY()); in isBasicallyTranslate()
43 static bool shouldFilter(const SkMatrix& matrix) { in shouldFilter() argument
44 if (!matrix.isScaleTranslate()) return true; in shouldFilter()
47 bool noScale = MathUtils::isOne(matrix.getScaleX()) && MathUtils::isOne(matrix.getScaleY()); in shouldFilter()
49 SkScalarIsInt(matrix.getTranslateX()) && SkScalarIsInt(matrix.getTranslateY()); in shouldFilter()
60 // transform the matrix based on the layer in DrawLayer()
81 SkMatrix matrix; in DrawLayer() local
[all …]
/frameworks/opt/bitmap/src/com/android/bitmap/util/
DRectUtils.java19 import android.graphics.Matrix;
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
[all …]
/frameworks/base/opengl/java/android/opengl/
DMatrix.java20 * Matrix math utilities. These methods operate on OpenGL ES format
38 public class Matrix { class
40 /** Temporary memory for operations that need temporary matrix data. */
47 public Matrix() {} in Matrix() method in Matrix
51 * matrix. In matrix notation: result = lhs x rhs. Due to the way
52 * matrix multiplication works, the result matrix will have the same
53 * effect as first multiplying by the rhs matrix, then multiplying by
54 * the lhs matrix. This is the opposite of what you might expect.
63 * @param lhs The float array that holds the left-hand-side matrix.
65 * @param rhs The float array that holds the right-hand-side matrix.
[all …]
/frameworks/base/services/core/java/com/android/server/wm/
DBlackFrame.java23 import android.graphics.Matrix;
68 void setMatrix(SurfaceControl.Transaction t, Matrix matrix) { in setMatrix() argument
70 mTmpMatrix.postConcat(matrix); in setMatrix()
72 t.setPosition(surface, mTmpFloats[Matrix.MTRANS_X], in setMatrix()
73 mTmpFloats[Matrix.MTRANS_Y]); in setMatrix()
75 mTmpFloats[Matrix.MSCALE_X], mTmpFloats[Matrix.MSKEW_Y], in setMatrix()
76 mTmpFloats[Matrix.MSKEW_X], mTmpFloats[Matrix.MSCALE_Y]); in setMatrix()
79 + mTmpFloats[Matrix.MTRANS_X] + "," in setMatrix()
80 + mTmpFloats[Matrix.MTRANS_Y] + ") matrix=[" in setMatrix()
81 + mTmpFloats[Matrix.MSCALE_X] + "," in setMatrix()
[all …]
/frameworks/base/core/java/android/view/inputmethod/
DCursorAnchorInfo.java21 import android.graphics.Matrix;
73 * transformed with the transformation matrix when rendered on the screen. This should be
80 * transformed with the transformation matrix when rendered on the screen. This should be
87 * transformed with the transformation matrix when rendered on the screen. This should be
94 * transformed with the transformation matrix when rendered on the screen. This should be
102 * Java chars, in the local coordinates that will be transformed with the transformation matrix
108 * Transformation matrix that is applied to any positional information of this class to
305 * coordinates that will be transformed with the transformation matrix when rendered on the
309 * will be transformed with the transformation matrix when rendered on the screen. This
312 * that will be transformed with the transformation matrix when rendered on the screen. This
[all …]

12345678910>>...22