diff options
author | Anton Khirnov <anton@khirnov.net> | 2012-10-06 14:10:34 +0400 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2012-10-08 09:13:26 +0400 |
commit | 716d413c13981da15323c7a3821860536eefdbbb (patch) | |
tree | b15ebcded50b8edaa5b9fc8f261774043138e1fa /libavdevice/x11grab.c | |
parent | 78071a1420b425dfb787ac739048f523007b8139 (diff) |
Replace PIX_FMT_* -> AV_PIX_FMT_*, PixelFormat -> AVPixelFormat
Diffstat (limited to 'libavdevice/x11grab.c')
-rw-r--r-- | libavdevice/x11grab.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/libavdevice/x11grab.c b/libavdevice/x11grab.c index ab5362d282..8edbf7bf2b 100644 --- a/libavdevice/x11grab.c +++ b/libavdevice/x11grab.c @@ -158,7 +158,7 @@ x11grab_read_header(AVFormatContext *s1) struct x11grab *x11grab = s1->priv_data; Display *dpy; AVStream *st = NULL; - enum PixelFormat input_pixfmt; + enum AVPixelFormat input_pixfmt; XImage *image; int x_off = 0; int y_off = 0; @@ -259,19 +259,19 @@ x11grab_read_header(AVFormatContext *s1) switch (image->bits_per_pixel) { case 8: av_log (s1, AV_LOG_DEBUG, "8 bit palette\n"); - input_pixfmt = PIX_FMT_PAL8; + input_pixfmt = AV_PIX_FMT_PAL8; break; case 16: if ( image->red_mask == 0xf800 && image->green_mask == 0x07e0 && image->blue_mask == 0x001f ) { av_log (s1, AV_LOG_DEBUG, "16 bit RGB565\n"); - input_pixfmt = PIX_FMT_RGB565; + input_pixfmt = AV_PIX_FMT_RGB565; } else if (image->red_mask == 0x7c00 && image->green_mask == 0x03e0 && image->blue_mask == 0x001f ) { av_log(s1, AV_LOG_DEBUG, "16 bit RGB555\n"); - input_pixfmt = PIX_FMT_RGB555; + input_pixfmt = AV_PIX_FMT_RGB555; } else { av_log(s1, AV_LOG_ERROR, "RGB ordering at image depth %i not supported ... aborting\n", image->bits_per_pixel); av_log(s1, AV_LOG_ERROR, "color masks: r 0x%.6lx g 0x%.6lx b 0x%.6lx\n", image->red_mask, image->green_mask, image->blue_mask); @@ -283,11 +283,11 @@ x11grab_read_header(AVFormatContext *s1) if ( image->red_mask == 0xff0000 && image->green_mask == 0x00ff00 && image->blue_mask == 0x0000ff ) { - input_pixfmt = PIX_FMT_BGR24; + input_pixfmt = AV_PIX_FMT_BGR24; } else if ( image->red_mask == 0x0000ff && image->green_mask == 0x00ff00 && image->blue_mask == 0xff0000 ) { - input_pixfmt = PIX_FMT_RGB24; + input_pixfmt = AV_PIX_FMT_RGB24; } else { av_log(s1, AV_LOG_ERROR,"rgb ordering at image depth %i not supported ... aborting\n", image->bits_per_pixel); av_log(s1, AV_LOG_ERROR, "color masks: r 0x%.6lx g 0x%.6lx b 0x%.6lx\n", image->red_mask, image->green_mask, image->blue_mask); @@ -296,7 +296,7 @@ x11grab_read_header(AVFormatContext *s1) } break; case 32: - input_pixfmt = PIX_FMT_RGB32; + input_pixfmt = AV_PIX_FMT_RGB32; break; default: av_log(s1, AV_LOG_ERROR, "image depth %i not supported ... aborting\n", image->bits_per_pixel); |