Android: Remove custom matrix helper functions in RendererCommon
Bug: webrtc:9487 Change-Id: I2b5720d55cae9684a7ef2b14cabce262a5321ef0 Reviewed-on: https://webrtc-review.googlesource.com/87820 Reviewed-by: Sami Kalliomäki <sakal@webrtc.org> Commit-Queue: Magnus Jedvert <magjed@webrtc.org> Cr-Commit-Position: refs/heads/master@{#24183}
This commit is contained in:
committed by
Commit Bot
parent
489767830b
commit
0cbe05cc86
@ -118,57 +118,6 @@ public class RendererCommon {
|
||||
// The minimum fraction of the frame content that will be shown for |SCALE_ASPECT_BALANCED|.
|
||||
// This limits excessive cropping when adjusting display size.
|
||||
private static float BALANCED_VISIBLE_FRACTION = 0.5625f;
|
||||
// clang-format off
|
||||
@Deprecated
|
||||
public static final float[] identityMatrix() {
|
||||
return new float[] {
|
||||
1, 0, 0, 0,
|
||||
0, 1, 0, 0,
|
||||
0, 0, 1, 0,
|
||||
0, 0, 0, 1};
|
||||
}
|
||||
// Matrix with transform y' = 1 - y.
|
||||
@Deprecated
|
||||
public static final float[] verticalFlipMatrix() {
|
||||
return new float[] {
|
||||
1, 0, 0, 0,
|
||||
0, -1, 0, 0,
|
||||
0, 0, 1, 0,
|
||||
0, 1, 0, 1};
|
||||
}
|
||||
|
||||
// Matrix with transform x' = 1 - x.
|
||||
@Deprecated
|
||||
public static final float[] horizontalFlipMatrix() {
|
||||
return new float[] {
|
||||
-1, 0, 0, 0,
|
||||
0, 1, 0, 0,
|
||||
0, 0, 1, 0,
|
||||
1, 0, 0, 1};
|
||||
}
|
||||
// clang-format on
|
||||
|
||||
/**
|
||||
* Returns texture matrix that will have the effect of rotating the frame |rotationDegree|
|
||||
* clockwise when rendered.
|
||||
*/
|
||||
@Deprecated
|
||||
public static float[] rotateTextureMatrix(float[] textureMatrix, float rotationDegree) {
|
||||
final float[] rotationMatrix = new float[16];
|
||||
Matrix.setRotateM(rotationMatrix, 0, rotationDegree, 0, 0, 1);
|
||||
adjustOrigin(rotationMatrix);
|
||||
return multiplyMatrices(textureMatrix, rotationMatrix);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns new matrix with the result of a * b.
|
||||
*/
|
||||
@Deprecated
|
||||
public static float[] multiplyMatrices(float[] a, float[] b) {
|
||||
final float[] resultMatrix = new float[16];
|
||||
Matrix.multiplyMM(resultMatrix, 0, a, 0, b, 0);
|
||||
return resultMatrix;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns layout transformation matrix that applies an optional mirror effect and compensates
|
||||
|
||||
Reference in New Issue
Block a user