summaryrefslogtreecommitdiff
path: root/libavcodec/mpegvideo.c
diff options
context:
space:
mode:
authorGanesh Ajjanagadde <gajjanagadde@gmail.com>2015-11-14 10:49:45 -0500
committerGanesh Ajjanagadde <gajjanagadde@gmail.com>2015-11-14 10:58:39 -0500
commitc5fa42c69aeccd644fb5a42b4995602d206f168b (patch)
tree9fbb49afcd69d07c763b2000da5d402d5cd4cb56 /libavcodec/mpegvideo.c
parentf1726ad1b0d0345cc9dbae917c3141f703b19050 (diff)
avcodec/mpegvideo: use predefined M_PI
M_PI is defined in math.h, or in avutil/mathematics.h for compatibility hacks. This uses this value instead of an ad-hoc floating literal. Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
Diffstat (limited to 'libavcodec/mpegvideo.c')
-rw-r--r--libavcodec/mpegvideo.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/mpegvideo.c b/libavcodec/mpegvideo.c
index 96634ec7b5..69e0595db9 100644
--- a/libavcodec/mpegvideo.c
+++ b/libavcodec/mpegvideo.c
@@ -1870,8 +1870,8 @@ void ff_print_debug_info2(AVCodecContext *avctx, AVFrame *pict, uint8_t *mbskip_
uint64_t u,v;
int y;
#define COLOR(theta, r) \
- u = (int)(128 + r * cos(theta * 3.141592 / 180)); \
- v = (int)(128 + r * sin(theta * 3.141592 / 180));
+ u = (int)(128 + r * cos(theta * M_PI / 180)); \
+ v = (int)(128 + r * sin(theta * M_PI / 180));
u = v = 128;