summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2014-12-27 12:23:00 +0100
committerDiogo Franco (Kovensky) <diogomfranco@gmail.com>2015-01-25 17:00:13 +0900
commitab4c857ff6023397d8299607f97ab251d8b7d809 (patch)
treec66193b33e6e0dbdfca61b5f3d2307c0ef6b1662
parente3f4491a24875691a3d2b2545e27e2097223911a (diff)
downloadmpv-ab4c857ff6023397d8299607f97ab251d8b7d809.tar.bz2
mpv-ab4c857ff6023397d8299607f97ab251d8b7d809.tar.xz
player: cosmetics: rename a function
Something which has this many important sideffects shouldn't start have a "get" prefix. Conflicts: player/sub.c
-rw-r--r--player/command.c2
-rw-r--r--player/core.h4
-rw-r--r--player/sub.c8
3 files changed, 7 insertions, 7 deletions
diff --git a/player/command.c b/player/command.c
index 9bd3b21deb..90ddcd4758 100644
--- a/player/command.c
+++ b/player/command.c
@@ -4167,7 +4167,7 @@ int run_command(MPContext *mpctx, mp_cmd_t *cmd)
if (!mpctx->num_sources)
return -1;
struct osd_sub_state state;
- get_osd_sub_state(mpctx, 0, &state);
+ update_osd_sub_state(mpctx, 0, &state);
double refpts = get_current_time(mpctx);
if (state.dec_sub && refpts != MP_NOPTS_VALUE) {
double a[2];
diff --git a/player/core.h b/player/core.h
index 4b45d32e36..4c8b067bb7 100644
--- a/player/core.h
+++ b/player/core.h
@@ -471,8 +471,8 @@ void uninit_sub_all(struct MPContext *mpctx);
void update_osd_msg(struct MPContext *mpctx);
void update_subtitles(struct MPContext *mpctx);
void uninit_sub_renderer(struct MPContext *mpctx);
-void get_osd_sub_state(struct MPContext *mpctx, int order,
- struct osd_sub_state *out_state);
+void update_osd_sub_state(struct MPContext *mpctx, int order,
+ struct osd_sub_state *out_state);
// timeline/tl_matroska.c
void build_ordered_chapter_timeline(struct MPContext *mpctx);
diff --git a/player/sub.c b/player/sub.c
index 66f28658e8..bc9759e3e5 100644
--- a/player/sub.c
+++ b/player/sub.c
@@ -191,8 +191,8 @@ void reset_subtitle_state(struct MPContext *mpctx)
reset_subtitles(mpctx, 1);
}
-void get_osd_sub_state(struct MPContext *mpctx, int order,
- struct osd_sub_state *out_state)
+void update_osd_sub_state(struct MPContext *mpctx, int order,
+ struct osd_sub_state *out_state)
{
struct MPOpts *opts = mpctx->opts;
struct track *track = mpctx->current_track[order][STREAM_SUB];
@@ -238,7 +238,7 @@ static void update_subtitle(struct MPContext *mpctx, int order)
}
struct osd_sub_state state;
- get_osd_sub_state(mpctx, order, &state);
+ update_osd_sub_state(mpctx, order, &state);
double refpts_s = mpctx->playback_pts - state.video_offset;
double curpts_s = refpts_s - opts->sub_delay;
@@ -342,5 +342,5 @@ void reinit_subs(struct MPContext *mpctx, int order)
struct dec_sub *dec_sub = mpctx->d_sub[order];
reinit_subdec(mpctx, track, dec_sub);
- get_osd_sub_state(mpctx, order, NULL);
+ update_osd_sub_state(mpctx, order, NULL);
}