mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2026-02-04 14:30:55 +08:00
lavfi: modify avfilter_get_matrix to support separate scale factors
This commit is contained in:
committed by
Mark Thompson
parent
d3cd33ab1b
commit
5b5746b1e0
@@ -103,12 +103,19 @@ INTERPOLATE_METHOD(interpolate_biquadratic)
|
||||
}
|
||||
}
|
||||
|
||||
void avfilter_get_matrix(float x_shift, float y_shift, float angle, float zoom, float *matrix) {
|
||||
matrix[0] = zoom * cos(angle);
|
||||
void ff_get_matrix(
|
||||
float x_shift,
|
||||
float y_shift,
|
||||
float angle,
|
||||
float scale_x,
|
||||
float scale_y,
|
||||
float *matrix
|
||||
) {
|
||||
matrix[0] = scale_x * cos(angle);
|
||||
matrix[1] = -sin(angle);
|
||||
matrix[2] = x_shift;
|
||||
matrix[3] = -matrix[1];
|
||||
matrix[4] = matrix[0];
|
||||
matrix[4] = scale_y * cos(angle);
|
||||
matrix[5] = y_shift;
|
||||
matrix[6] = 0;
|
||||
matrix[7] = 0;
|
||||
|
||||
Reference in New Issue
Block a user