diff options
-rw-r--r-- | src/video_out/video_out_xcbxv.c | 13 | ||||
-rw-r--r-- | src/video_out/video_out_xv.c | 13 | ||||
-rw-r--r-- | src/video_out/video_out_xvmc.c | 20 | ||||
-rw-r--r-- | src/video_out/video_out_xxmc.c | 13 |
4 files changed, 40 insertions, 19 deletions
diff --git a/src/video_out/video_out_xcbxv.c b/src/video_out/video_out_xcbxv.c index f61ae6a9c..6fed0f90a 100644 --- a/src/video_out/video_out_xcbxv.c +++ b/src/video_out/video_out_xcbxv.c @@ -1362,16 +1362,21 @@ static vo_driver_t *open_plugin(video_driver_class_t *class_gen, const void *vis (format_it.data->format == XCB_XV_IMAGE_FORMAT_INFO_FORMAT_PACKED) ? "packed" : "planar"); - if (format_it.data->id == XINE_IMGFMT_YV12) { + switch (format_it.data->id) { + case XINE_IMGFMT_YV12: this->xv_format_yv12 = format_it.data->id; this->capabilities |= VO_CAP_YV12; xprintf(this->xine, XINE_VERBOSITY_LOG, - _("%s: this adaptor supports the yv12 format.\n"), LOG_MODULE); - } else if (format_it.data->id == XINE_IMGFMT_YUY2) { + _("%s: this adaptor supports the %s format.\n"), LOG_MODULE, "YV12"); + break; + case XINE_IMGFMT_YUY2: this->xv_format_yuy2 = format_it.data->id; this->capabilities |= VO_CAP_YUY2; xprintf(this->xine, XINE_VERBOSITY_LOG, - _("%s: this adaptor supports the yuy2 format.\n"), LOG_MODULE); + _("%s: this adaptor supports the %s format.\n"), LOG_MODULE, "YUY2"); + break; + default: + break; } } diff --git a/src/video_out/video_out_xv.c b/src/video_out/video_out_xv.c index 6cdbc6b64..6f5c68e51 100644 --- a/src/video_out/video_out_xv.c +++ b/src/video_out/video_out_xv.c @@ -1406,16 +1406,21 @@ static vo_driver_t *open_plugin_2 (video_driver_class_t *class_gen, const void * fo[i].id, (char*)&fo[i].id, (fo[i].format == XvPacked) ? "packed" : "planar"); - if (fo[i].id == XINE_IMGFMT_YV12) { + switch (fo[i].id) { + case XINE_IMGFMT_YV12: this->xv_format_yv12 = fo[i].id; this->capabilities |= VO_CAP_YV12; xprintf(this->xine, XINE_VERBOSITY_LOG, - _("%s: this adaptor supports the yv12 format.\n"), LOG_MODULE); - } else if (fo[i].id == XINE_IMGFMT_YUY2) { + _("%s: this adaptor supports the %s format.\n"), LOG_MODULE, "YV12"); + break; + case XINE_IMGFMT_YUY2: this->xv_format_yuy2 = fo[i].id; this->capabilities |= VO_CAP_YUY2; xprintf(this->xine, XINE_VERBOSITY_LOG, - _("%s: this adaptor supports the yuy2 format.\n"), LOG_MODULE); + _("%s: this adaptor supports the %s format.\n"), LOG_MODULE, "YUY2"); + break; + default: + break; } } diff --git a/src/video_out/video_out_xvmc.c b/src/video_out/video_out_xvmc.c index c0fb10be3..9618b082c 100644 --- a/src/video_out/video_out_xvmc.c +++ b/src/video_out/video_out_xvmc.c @@ -1456,15 +1456,21 @@ static vo_driver_t *open_plugin (video_driver_class_t *class_gen, const void *vi fo[i].id, (char*)&fo[i].id, (fo[i].format == XvPacked) ? "packed" : "planar"); - if (fo[i].id == XINE_IMGFMT_YV12) { + switch (fo[i].id) { + case XINE_IMGFMT_YV12: this->xvmc_format_yv12 = fo[i].id; - this->capabilities |= VO_CAP_YV12; - lprintf("this adaptor supports the yv12 format.\n"); - } - else if (fo[i].id == XINE_IMGFMT_YUY2) { + this->capabilities |= VO_CAP_YV12; + xprintf(this->xine, XINE_VERBOSITY_LOG, + _("%s: this adaptor supports the %s format.\n"), LOG_MODULE, "YV12"); + break; + case XINE_IMGFMT_YUY2: this->xvmc_format_yuy2 = fo[i].id; - this->capabilities |= VO_CAP_YUY2; - lprintf("this adaptor supports the yuy2 format.\n"); + this->capabilities |= VO_CAP_YUY2; + xprintf(this->xine, XINE_VERBOSITY_LOG, + _("%s: this adaptor supports the %s format.\n"), LOG_MODULE, "YUY2"); + break; + default: + break; } } diff --git a/src/video_out/video_out_xxmc.c b/src/video_out/video_out_xxmc.c index 107ed9c7b..2c42dda2e 100644 --- a/src/video_out/video_out_xxmc.c +++ b/src/video_out/video_out_xxmc.c @@ -2655,16 +2655,21 @@ static vo_driver_t *open_plugin (video_driver_class_t *class_gen, const void *vi fo[i].id, (char*)&fo[i].id, (fo[i].format == XvPacked) ? "packed" : "planar"); - if (fo[i].id == XINE_IMGFMT_YV12) { + switch (fo[i].id) { + case XINE_IMGFMT_YV12: this->xv_format_yv12 = fo[i].id; this->capabilities |= VO_CAP_YV12; xprintf(this->xine, XINE_VERBOSITY_LOG, - _("%s: this adaptor supports the yv12 format.\n"), LOG_MODULE); - } else if (fo[i].id == XINE_IMGFMT_YUY2) { + _("%s: this adaptor supports the %s format.\n"), LOG_MODULE, "YV12"); + break; + case XINE_IMGFMT_YUY2: this->xv_format_yuy2 = fo[i].id; this->capabilities |= VO_CAP_YUY2; xprintf(this->xine, XINE_VERBOSITY_LOG, - _("%s: this adaptor supports the yuy2 format.\n"), LOG_MODULE); + _("%s: this adaptor supports the %s format.\n"), LOG_MODULE, "YUY2"); + break; + default: + break; } } |