Originally committed as revision 30236 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale
Unified · Split
| @@ -157,6 +157,12 @@ const char *swscale_license(void) · 156 unmodified lines | |||
| 157 | || (x)==PIX_FMT_YUV422P16BE \ | 157 | || (x)==PIX_FMT_YUV422P16BE \ |
| 158 | || (x)==PIX_FMT_YUV444P16BE \ | 158 | || (x)==PIX_FMT_YUV444P16BE \ |
| 159 | ) | 159 | ) |
| 160 | |||
| 161 | int sws_isSupportedInput(enum PixelFormat pix_fmt) | ||
| 162 | { | ||
| 163 | return isSupportedIn(pix_fmt); | ||
| 164 | } | ||
| 165 | |||
| 160 | #define isSupportedOut(x) ( \ | 166 | #define isSupportedOut(x) ( \ |
| 161 | (x)==PIX_FMT_YUV420P \ | 167 | (x)==PIX_FMT_YUV420P \ |
| 162 | || (x)==PIX_FMT_YUVA420P \ | 168 | || (x)==PIX_FMT_YUVA420P \ |
| @@ -181,6 +187,12 @@ const char *swscale_license(void) · 18 unmodified lines | |||
| 181 | || (x)==PIX_FMT_YUV422P16BE \ | 187 | || (x)==PIX_FMT_YUV422P16BE \ |
| 182 | || (x)==PIX_FMT_YUV444P16BE \ | 188 | || (x)==PIX_FMT_YUV444P16BE \ |
| 183 | ) | 189 | ) |
| 190 | |||
| 191 | int sws_isSupportedOutput(enum PixelFormat pix_fmt) | ||
| 192 | { | ||
| 193 | return isSupportedOut(pix_fmt); | ||
| 194 | } | ||
| 195 | |||
| 184 | #define isPacked(x) ( \ | 196 | #define isPacked(x) ( \ |
| 185 | (x)==PIX_FMT_PAL8 \ | 197 | (x)==PIX_FMT_PAL8 \ |
| 186 | || (x)==PIX_FMT_YUYV422 \ | 198 | || (x)==PIX_FMT_YUYV422 \ |
| @@ -30,8 +30,8 @@ · 29 unmodified lines | |||
| 30 | #include "libavutil/avutil.h" | 30 | #include "libavutil/avutil.h" |
| 31 | 31 | ||
| 32 | #define LIBSWSCALE_VERSION_MAJOR 0 | 32 | #define LIBSWSCALE_VERSION_MAJOR 0 |
| 33 | #define LIBSWSCALE_VERSION_MINOR 7 | 33 | #define LIBSWSCALE_VERSION_MINOR 8 |
| 34 | #define LIBSWSCALE_VERSION_MICRO 2 | 34 | #define LIBSWSCALE_VERSION_MICRO 0 |
| 35 | 35 | ||
| 36 | #define LIBSWSCALE_VERSION_INT AV_VERSION_INT(LIBSWSCALE_VERSION_MAJOR, \ | 36 | #define LIBSWSCALE_VERSION_INT AV_VERSION_INT(LIBSWSCALE_VERSION_MAJOR, \ |
| 37 | LIBSWSCALE_VERSION_MINOR, \ | 37 | LIBSWSCALE_VERSION_MINOR, \ |
| @@ -122,6 +122,18 @@ typedef struct { · 84 unmodified lines | |||
| 122 | 122 | ||
| 123 | struct SwsContext; | 123 | struct SwsContext; |
| 124 | 124 | ||
| 125 | /** | ||
| 126 | * Returns a positive value if pix_fmt is a supported input format, 0 | ||
| 127 | * otherwise. | ||
| 128 | */ | ||
| 129 | int sws_isSupportedInput(enum PixelFormat pix_fmt); | ||
| 130 | |||
| 131 | /** | ||
| 132 | * Returns a positive value if pix_fmt is a supported output format, 0 | ||
| 133 | * otherwise. | ||
| 134 | */ | ||
| 135 | int sws_isSupportedOutput(enum PixelFormat pix_fmt); | ||
| 136 | |||
| 125 | /** | 137 | /** |
| 126 | * Frees the swscaler context swsContext. | 138 | * Frees the swscaler context swsContext. |
| 127 | * If swsContext is NULL, then does nothing. | 139 | * If swsContext is NULL, then does nothing. |