cmdutils: round rotation value to nearest integer
As recommended by the doxy for av_display_rotation_get(). Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
@@ -2207,7 +2207,7 @@ double get_rotation(AVStream *st)
|
|||||||
AV_PKT_DATA_DISPLAYMATRIX, NULL);
|
AV_PKT_DATA_DISPLAYMATRIX, NULL);
|
||||||
double theta = 0;
|
double theta = 0;
|
||||||
if (displaymatrix)
|
if (displaymatrix)
|
||||||
theta = -av_display_rotation_get((int32_t*) displaymatrix);
|
theta = -round(av_display_rotation_get((int32_t*) displaymatrix));
|
||||||
|
|
||||||
theta -= 360*floor(theta/360 + 0.9/360);
|
theta -= 360*floor(theta/360 + 0.9/360);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user