/** * Concatenates (premultiplies) the given matrix to this matrix. * * @param matrix The matrix to concatenate. */ public void concatenate(Matrix matrix) { matrix.multiply(this, this); }
/** * This will take the current matrix and multiply it with a matrix that is passed in. * * @param b The matrix to multiply by. * * @return The result of the two multiplied matrices. */ public Matrix multiply( Matrix b ) { return this.multiply(b, new Matrix()); }
/** * Concatenates (premultiplies) the given matrix to this matrix. * * @param matrix The matrix to concatenate. */ public void concatenate(Matrix matrix) { matrix.multiply(this, this); }
/** * Concatenates (premultiplies) the given matrix to this matrix. * * @param matrix The matrix to concatenate. */ public void concatenate(Matrix matrix) { matrix.multiply(this, this); }
float horizontalScaling = textState.getHorizontalScaling() / 100f; [...] Matrix parameters = new Matrix( fontSize * horizontalScaling, 0, // 0 0, fontSize, // 0 0, textState.getRise()); // 1 [...] Matrix textRenderingMatrix = parameters.multiply(textMatrix).multiply(ctm);
Matrix a = CRSMatrix.random(10000, 10000, 0.25 /* density */, new Random()); Matrix b = CCSMatrix.random(10000, 10000, 0.25 /* density */, new Random()); Matrix c = a.multiply(b);
/** * This will take the current matrix and multiply it with a matrix that is passed in. * * @param b The matrix to multiply by. * * @return The result of the two multiplied matrices. */ public Matrix multiply( Matrix b ) { return this.multiply(b, new Matrix()); }
/** * This will take the current matrix and multiply it with a matrix that is passed in. * * @param b The matrix to multiply by. * * @return The result of the two multiplied matrices. */ public Matrix multiply( Matrix b ) { return this.multiply(b, new Matrix()); }
Matrix a = new Basic2DMatrix(...); // simple 2D array matrix Matrix b = new Basic2DMatrix(...); // that is too Matrix c = a.multiply(b); // a * b in sequental mode Matrix c = a.par().multiply(b); // a * b in parallel mode
/** * Transforms a length according to the current transformation matrix. */ protected float transformLength(float w) { Matrix ctm = getGraphicsState().getCurrentTransformationMatrix(); Matrix m = new Matrix(); m.setValue(2, 0, w); return m.multiply(ctm).getTranslateX(); }
(context.getGraphicsState().getTextState().getHorizontalScalingPercent()/100); adjMatrix.setValue( 2, 0, adjustment ); context.setTextMatrix( adjMatrix.multiply( context.getTextMatrix() ) );
scalingParams = scalingParams.multiply( scalingMatrix ); translationParams.setValue(2,1, -translationParams.getValue( 2,1 )); translationMatrix = Matrix.getTranslatingInstance(0, (float)pageSize.getHeight()-height*scalingParams.getYScale() ); translationParams = translationParams.multiply( translationMatrix );
if (matrix != null) Matrix xobjectCTM = matrix.multiply( getGraphicsState().getCurrentTransformationMatrix()); getGraphicsState().setCurrentTransformationMatrix(xobjectCTM);