summaryrefslogtreecommitdiffstats
path: root/video
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2013-12-16 20:40:02 +0100
committerwm4 <wm4@nowhere>2013-12-16 20:41:08 +0100
commit7dc7b900c622235d595337c988a0c75280084b7c (patch)
tree7f896555c9478430edd28d56fb6fde5691b0e643 /video
parent3e6cd3ef19aca7c79dfc73412f98b70b7de011b4 (diff)
downloadmpv-7dc7b900c622235d595337c988a0c75280084b7c.tar.bz2
mpv-7dc7b900c622235d595337c988a0c75280084b7c.tar.xz
Replace mp_tmsg, mp_dbg -> mp_msg, remove mp_gtext(), remove set_osd_tmsg
The tmsg stuff was for the internal gettext() based translation system, which nobody ever attempted to use and thus was removed. mp_gtext() and set_osd_tmsg() were also for this. mp_dbg was once enabled in debug mode only, but since we have log level for enabling debug messages, it seems utterly useless.
Diffstat (limited to 'video')
-rw-r--r--video/decode/dec_video.c18
-rw-r--r--video/decode/vd_lavc.c22
-rw-r--r--video/filter/vf.c8
-rw-r--r--video/filter/vf_crop.c2
-rw-r--r--video/out/x11_common.c2
5 files changed, 26 insertions, 26 deletions
diff --git a/video/decode/dec_video.c b/video/decode/dec_video.c
index 6cfab92798..a77e77ec6d 100644
--- a/video/decode/dec_video.c
+++ b/video/decode/dec_video.c
@@ -87,13 +87,13 @@ int video_set_colors(struct dec_video *d_video, const char *item, int value)
data.item = item;
data.value = value;
- mp_dbg(MSGT_DECVIDEO, MSGL_V, "set video colors %s=%d \n", item, value);
+ mp_msg(MSGT_DECVIDEO, MSGL_V, "set video colors %s=%d \n", item, value);
if (d_video->vfilter) {
int ret = video_vf_vo_control(d_video, VFCTRL_SET_EQUALIZER, &data);
if (ret == CONTROL_TRUE)
return 1;
}
- mp_tmsg(MSGT_DECVIDEO, MSGL_V, "Video attribute '%s' is not supported by selected vo.\n",
+ mp_msg(MSGT_DECVIDEO, MSGL_V, "Video attribute '%s' is not supported by selected vo.\n",
item);
return 0;
}
@@ -104,7 +104,7 @@ int video_get_colors(struct dec_video *d_video, const char *item, int *value)
data.item = item;
- mp_dbg(MSGT_DECVIDEO, MSGL_V, "get video colors %s \n", item);
+ mp_msg(MSGT_DECVIDEO, MSGL_V, "get video colors %s \n", item);
if (d_video->vfilter) {
int ret = video_vf_vo_control(d_video, VFCTRL_GET_EQUALIZER, &data);
if (ret == CONTROL_TRUE) {
@@ -119,7 +119,7 @@ void video_uninit(struct dec_video *d_video)
{
mp_image_unrefp(&d_video->waiting_decoded_mpi);
if (d_video->vd_driver) {
- mp_tmsg(MSGT_DECVIDEO, MSGL_V, "Uninit video.\n");
+ mp_msg(MSGT_DECVIDEO, MSGL_V, "Uninit video.\n");
d_video->vd_driver->uninit(d_video);
}
talloc_free(d_video->priv);
@@ -130,7 +130,7 @@ void video_uninit(struct dec_video *d_video)
static int init_video_codec(struct dec_video *d_video, const char *decoder)
{
if (!d_video->vd_driver->init(d_video, decoder)) {
- mp_tmsg(MSGT_DECVIDEO, MSGL_V, "Video decoder init failed.\n");
+ mp_msg(MSGT_DECVIDEO, MSGL_V, "Video decoder init failed.\n");
return 0;
}
return 1;
@@ -179,7 +179,7 @@ bool video_init_best_codec(struct dec_video *d_video, char* video_decoders)
const struct vd_functions *driver = find_driver(sel->family);
if (!driver)
continue;
- mp_tmsg(MSGT_DECVIDEO, MSGL_V, "Opening video decoder %s:%s\n",
+ mp_msg(MSGT_DECVIDEO, MSGL_V, "Opening video decoder %s:%s\n",
sel->family, sel->decoder);
d_video->vd_driver = driver;
if (init_video_codec(d_video, sel->decoder)) {
@@ -187,7 +187,7 @@ bool video_init_best_codec(struct dec_video *d_video, char* video_decoders)
break;
}
d_video->vd_driver = NULL;
- mp_tmsg(MSGT_DECVIDEO, MSGL_WARN, "Video decoder init failed for "
+ mp_msg(MSGT_DECVIDEO, MSGL_WARN, "Video decoder init failed for "
"%s:%s\n", sel->family, sel->decoder);
}
@@ -410,7 +410,7 @@ int video_reconfig_filters(struct dec_video *d_video,
vf_set_dar(&p.d_w, &p.d_h, p.w, p.h, force_aspect);
if (abs(p.d_w - p.w) >= 4 || abs(p.d_h - p.h) >= 4) {
- mp_tmsg(MSGT_CPLAYER, MSGL_V, "Aspect ratio is %.2f:1 - "
+ mp_msg(MSGT_CPLAYER, MSGL_V, "Aspect ratio is %.2f:1 - "
"scaling to correct movie aspect.\n", sh->aspect);
mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_VIDEO_ASPECT=%1.4f\n", sh->aspect);
} else {
@@ -434,7 +434,7 @@ int video_reconfig_filters(struct dec_video *d_video,
p.w, p.h, p.d_w, p.d_h, p.imgfmt);
if (vf_reconfig(d_video->vfilter, &p) < 0) {
- mp_tmsg(MSGT_CPLAYER, MSGL_WARN, "FATAL: Cannot initialize video driver.\n");
+ mp_msg(MSGT_CPLAYER, MSGL_WARN, "FATAL: Cannot initialize video driver.\n");
return -1;
}
diff --git a/video/decode/vd_lavc.c b/video/decode/vd_lavc.c
index ed87a16b50..7e24cbcd90 100644
--- a/video/decode/vd_lavc.c
+++ b/video/decode/vd_lavc.c
@@ -218,7 +218,7 @@ static bool probe_hwdec(struct dec_video *vd, bool autoprobe, enum hwdec_type ap
{
struct vd_lavc_hwdec *hwdec = find_hwcodec(api);
if (!hwdec) {
- mp_tmsg(MSGT_DECVIDEO, MSGL_V, "Requested hardware decoder not "
+ mp_msg(MSGT_DECVIDEO, MSGL_V, "Requested hardware decoder not "
"compiled.\n");
return false;
}
@@ -229,10 +229,10 @@ static bool probe_hwdec(struct dec_video *vd, bool autoprobe, enum hwdec_type ap
*use_decoder = hw_decoder;
return true;
} else if (r == HWDEC_ERR_NO_CODEC) {
- mp_tmsg(MSGT_DECVIDEO, MSGL_V, "Hardware decoder '%s' not found in "
+ mp_msg(MSGT_DECVIDEO, MSGL_V, "Hardware decoder '%s' not found in "
"libavcodec.\n", hw_decoder ? hw_decoder : decoder);
} else if (r == HWDEC_ERR_NO_CTX && !autoprobe) {
- mp_tmsg(MSGT_DECVIDEO, MSGL_WARN, "VO does not support requested "
+ mp_msg(MSGT_DECVIDEO, MSGL_WARN, "VO does not support requested "
"hardware decoder.\n");
}
return false;
@@ -247,7 +247,7 @@ static int init(struct dec_video *vd, const char *decoder)
ctx->non_dr1_pool = talloc_steal(ctx, mp_image_pool_new(16));
if (bstr_endswith0(bstr0(decoder), "_vdpau")) {
- mp_tmsg(MSGT_DECVIDEO, MSGL_WARN, "VDPAU decoder '%s' was requested. "
+ mp_msg(MSGT_DECVIDEO, MSGL_WARN, "VDPAU decoder '%s' was requested. "
"This way of enabling hardware\ndecoding is not supported "
"anymore. Use --hwdec=vdpau instead.\nThe --hwdec-codec=... "
"option can be used to restrict which codecs are\nenabled, "
@@ -272,7 +272,7 @@ static int init(struct dec_video *vd, const char *decoder)
&hwdec, &hw_decoder);
}
} else {
- mp_tmsg(MSGT_DECVIDEO, MSGL_V, "Not trying to use hardware decoding: "
+ mp_msg(MSGT_DECVIDEO, MSGL_V, "Not trying to use hardware decoding: "
"codec %s is blacklisted by user.\n", decoder);
}
@@ -280,15 +280,15 @@ static int init(struct dec_video *vd, const char *decoder)
ctx->software_fallback_decoder = talloc_strdup(ctx, decoder);
if (hw_decoder)
decoder = hw_decoder;
- mp_tmsg(MSGT_DECVIDEO, MSGL_INFO, "Trying to use hardware decoding.\n");
+ mp_msg(MSGT_DECVIDEO, MSGL_INFO, "Trying to use hardware decoding.\n");
} else if (vd->opts->hwdec_api != HWDEC_NONE) {
- mp_tmsg(MSGT_DECVIDEO, MSGL_INFO, "Using software decoding.\n");
+ mp_msg(MSGT_DECVIDEO, MSGL_INFO, "Using software decoding.\n");
}
init_avctx(vd, decoder, hwdec);
if (!ctx->avctx) {
if (ctx->software_fallback_decoder) {
- mp_tmsg(MSGT_DECVIDEO, MSGL_ERR, "Error initializing hardware "
+ mp_msg(MSGT_DECVIDEO, MSGL_ERR, "Error initializing hardware "
"decoding, falling back to software decoding.\n");
decoder = ctx->software_fallback_decoder;
ctx->software_fallback_decoder = NULL;
@@ -455,7 +455,7 @@ static void init_avctx(struct dec_video *vd, const char *decoder,
/* open it */
if (avcodec_open2(avctx, lavc_codec, NULL) < 0) {
- mp_tmsg(MSGT_DECVIDEO, MSGL_ERR, "Could not open codec.\n");
+ mp_msg(MSGT_DECVIDEO, MSGL_ERR, "Could not open codec.\n");
uninit_avctx(vd);
return;
}
@@ -468,7 +468,7 @@ static void uninit_avctx(struct dec_video *vd)
if (avctx) {
if (avctx->codec && avcodec_close(avctx) < 0)
- mp_tmsg(MSGT_DECVIDEO, MSGL_ERR, "Could not close codec.\n");
+ mp_msg(MSGT_DECVIDEO, MSGL_ERR, "Could not close codec.\n");
av_freep(&avctx->extradata);
av_freep(&avctx->slice_offset);
@@ -762,7 +762,7 @@ static int force_fallback(struct dec_video *vd)
vd_ffmpeg_ctx *ctx = vd->priv;
if (ctx->software_fallback_decoder) {
uninit_avctx(vd);
- mp_tmsg(MSGT_DECVIDEO, MSGL_ERR, "Error using hardware "
+ mp_msg(MSGT_DECVIDEO, MSGL_ERR, "Error using hardware "
"decoding, falling back to software decoding.\n");
const char *decoder = ctx->software_fallback_decoder;
ctx->software_fallback_decoder = NULL;
diff --git a/video/filter/vf.c b/video/filter/vf.c
index 69d5b29137..c1e9084b0d 100644
--- a/video/filter/vf.c
+++ b/video/filter/vf.c
@@ -225,7 +225,7 @@ static struct vf_instance *vf_open(struct vf_chain *c, const char *name,
{
struct m_obj_desc desc;
if (!m_obj_list_find(&desc, &vf_obj_list, bstr0(name))) {
- mp_tmsg(MSGT_VFILTER, MSGL_ERR,
+ mp_msg(MSGT_VFILTER, MSGL_ERR,
"Couldn't find video filter '%s'.\n", name);
return NULL;
}
@@ -437,7 +437,7 @@ static void update_formats(struct vf_chain *c, struct vf_instance *vf,
// If there are output formats, but no input formats (meaning the
// filters after vf work, but vf can't output any format the filters
// after it accept), try to insert a conversion filter.
- mp_tmsg(MSGT_VFILTER, MSGL_INFO, "Using conversion filter.\n");
+ mp_msg(MSGT_VFILTER, MSGL_INFO, "Using conversion filter.\n");
struct vf_instance *conv = vf_open(c, "scale", NULL);
if (conv) {
conv->next = vf->next;
@@ -507,8 +507,8 @@ int vf_reconfig(struct vf_chain *c, const struct mp_image_params *params)
c->initialized = r < 0 ? -1 : 1;
int loglevel = r < 0 ? MSGL_WARN : MSGL_V;
if (r == -2)
- mp_tmsg(MSGT_VFILTER, MSGL_ERR, "Image formats incompatible.\n");
- mp_tmsg(MSGT_VFILTER, loglevel, "Video filter chain:\n");
+ mp_msg(MSGT_VFILTER, MSGL_ERR, "Image formats incompatible.\n");
+ mp_msg(MSGT_VFILTER, loglevel, "Video filter chain:\n");
vf_print_filter_chain(c, loglevel);
return r;
}
diff --git a/video/filter/vf_crop.c b/video/filter/vf_crop.c
index b1f41e5b18..fffcc62921 100644
--- a/video/filter/vf_crop.c
+++ b/video/filter/vf_crop.c
@@ -59,7 +59,7 @@ static int config(struct vf_instance *vf,
// check:
if(vf->priv->crop_w+vf->priv->crop_x>width ||
vf->priv->crop_h+vf->priv->crop_y>height){
- mp_tmsg(MSGT_VFILTER, MSGL_WARN, "[CROP] Bad position/width/height - cropped area outside of the original!\n");
+ mp_msg(MSGT_VFILTER, MSGL_WARN, "[CROP] Bad position/width/height - cropped area outside of the original!\n");
return 0;
}
vf_rescale_dsize(&d_width, &d_height, width, height,
diff --git a/video/out/x11_common.c b/video/out/x11_common.c
index 54cd063505..e1c67b177a 100644
--- a/video/out/x11_common.c
+++ b/video/out/x11_common.c
@@ -258,7 +258,7 @@ static const struct fstype fstypes[] = {
void fstype_help(void)
{
- mp_tmsg(MSGT_VO, MSGL_INFO, "Available fullscreen layer change modes:\n");
+ mp_msg(MSGT_VO, MSGL_INFO, "Available fullscreen layer change modes:\n");
for (int n = 0; fstypes[n].sym; n++) {
mp_msg(MSGT_VO, MSGL_INFO, " %-15s %s\n", fstypes[n].sym,
fstypes[n].help);