Skip to content

Commit

Permalink
glw: Stop clock driving subtitles when paused
Browse files Browse the repository at this point in the history
Otherwise subtitles will disappear shortly after video is paused.
Fixed ticket #463
  • Loading branch information
andoma committed Apr 20, 2011
1 parent eca677e commit c176cb0
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 8 deletions.
3 changes: 2 additions & 1 deletion src/ui/glw/glw_video_common.c
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,8 @@ glw_video_newframe(glw_t *w, int flags)

pts = gv->gv_cfg_cur.gvc_engine->gve_newframe(gv, vd, flags);

glw_video_overlay_layout(gv, pts, vd);
if(pts != AV_NOPTS_VALUE)
glw_video_overlay_layout(gv, pts, vd);
}


Expand Down
5 changes: 2 additions & 3 deletions src/ui/glw/glw_video_opengl.c
Original file line number Diff line number Diff line change
Expand Up @@ -382,8 +382,6 @@ yuvp_newframe(glw_video_t *gv, video_decoder_t *vd, int flags)
gv->gv_sa = NULL;
}

pts = AV_NOPTS_VALUE;

} else {

/* There are frames available that we are going to display,
Expand All @@ -394,7 +392,8 @@ yuvp_newframe(glw_video_t *gv, video_decoder_t *vd, int flags)

/* */
sb = TAILQ_NEXT(sa, gvs_link);
pts = gv_compute_blend(gv, sa, sb, output_duration);
if(!vd->vd_hold)
pts = gv_compute_blend(gv, sa, sb, output_duration);
epoch = sa->gvs_epoch;

if(!vd->vd_hold || sb != NULL) {
Expand Down
7 changes: 3 additions & 4 deletions src/ui/glw/glw_video_rsx.c
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ yuvp_newframe(glw_video_t *gv, video_decoder_t *vd, int flags)
glw_video_surface_t *sa, *sb, *s;
media_pipe_t *mp = gv->gv_mp;
int output_duration;
int64_t pts = 0;
int64_t pts = AV_NOPTS_VALUE;
int frame_duration = gv->w.glw_root->gr_frameduration;
int epoch = 0;

Expand All @@ -331,8 +331,6 @@ yuvp_newframe(glw_video_t *gv, video_decoder_t *vd, int flags)
gv->gv_sa = NULL;
}

pts = AV_NOPTS_VALUE;

} else {

/* There are frames available that we are going to display,
Expand All @@ -343,7 +341,8 @@ yuvp_newframe(glw_video_t *gv, video_decoder_t *vd, int flags)

/* */
sb = TAILQ_NEXT(sa, gvs_link);
pts = gv_compute_blend(gv, sa, sb, output_duration);
if(!vd->vd_hold)
pts = gv_compute_blend(gv, sa, sb, output_duration);
epoch = sa->gvs_epoch;

if(!vd->vd_hold || sb != NULL) {
Expand Down

0 comments on commit c176cb0

Please sign in to comment.