diff options
author | Reinhard Nißl <rnissl@gmx.de> | 2007-07-29 23:46:26 +0200 |
---|---|---|
committer | Reinhard Nißl <rnissl@gmx.de> | 2007-07-29 23:46:26 +0200 |
commit | 101cc49fe3f5c3bd1ab066101c9d97b5a6b1794b (patch) | |
tree | 5d83d9f37eee4e70b97d2eb3fcf624794444ff54 /src | |
parent | 9c0fb4297e3bbbab42f6b96c372a3102952ddb27 (diff) | |
download | xine-lib-101cc49fe3f5c3bd1ab066101c9d97b5a6b1794b.tar.gz xine-lib-101cc49fe3f5c3bd1ab066101c9d97b5a6b1794b.tar.bz2 |
have post_vdr_video use the recent postprocessing changes
post_vdr_video is now able to always intercept any frame as XXMC
and XVMC postprocessing has been fixed.
As long as post_vdr_video's image scaling isn't requested or possible
due too unsuitable frame format, the preprocessing procs shall still
get routed as we will not draw on the frame in that situation.
--HG--
extra : transplant_source : %C4%B3%C9%AC%7C%DBJ%D8%60%E2%EF%B4z%C0%01%97%CCQX%D7
Diffstat (limited to 'src')
-rw-r--r-- | src/vdr/post_vdr_video.c | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/src/vdr/post_vdr_video.c b/src/vdr/post_vdr_video.c index 84e05f8b5..52bef43b6 100644 --- a/src/vdr/post_vdr_video.c +++ b/src/vdr/post_vdr_video.c @@ -90,8 +90,8 @@ static void vdr_video_class_dispose(post_class_t *class_gen); /* plugin instance functions */ static void vdr_video_dispose(post_plugin_t *this_gen); -/* frame intercept check */ -static int vdr_video_intercept_frame(post_video_port_t *port, vo_frame_t *frame); +/* route preprocessing functions check */ +static int vdr_video_route_preprocessing_procs(post_video_port_t *port, vo_frame_t *frame); /* replaced vo_frame functions */ static int vdr_video_draw(vo_frame_t *frame, xine_stream_t *stream); @@ -131,12 +131,10 @@ static post_plugin_t *vdr_video_open_plugin(post_class_t *class_gen, int inputs, this->post_plugin.dispose = vdr_video_dispose; port = _x_post_intercept_video_port(&this->post_plugin, video_target[ 0 ], &input, &output); - port->intercept_frame = vdr_video_intercept_frame; - port->new_frame->draw = vdr_video_draw; + port->route_preprocessing_procs = vdr_video_route_preprocessing_procs; + port->new_frame->draw = vdr_video_draw; this->post_plugin.xine_post.video_input[ 0 ] = &port->new_port; - - this->enabled = 0; this->vdr_stream = 0; this->event_queue = 0; @@ -195,11 +193,12 @@ static void vdr_video_dispose(post_plugin_t *this_gen) } } - -static int vdr_video_intercept_frame(post_video_port_t *port, vo_frame_t *frame) +static int vdr_video_route_preprocessing_procs(post_video_port_t *port, vo_frame_t *frame) { - return (frame->format == XINE_IMGFMT_YUY2 - || frame->format == XINE_IMGFMT_YV12); + vdr_video_post_plugin_t *this = (vdr_video_post_plugin_t *)port->post; + return !this->enabled + || (frame->format != XINE_IMGFMT_YUY2 + && frame->format != XINE_IMGFMT_YV12); } @@ -416,6 +415,8 @@ static int vdr_video_draw(vo_frame_t *frame, xine_stream_t *stream) frame_height = frame->height; if (this->vdr_stream + && frame_width != 0 + && frame_height != 0 && (this->old_frame_left != frame_left || this->old_frame_top != frame_top || this->old_frame_width != frame_width @@ -460,7 +461,9 @@ static int vdr_video_draw(vo_frame_t *frame, xine_stream_t *stream) if (!this->enabled || frame->bad_frame || (frame->format != XINE_IMGFMT_YUY2 - && frame->format != XINE_IMGFMT_YV12)) + && frame->format != XINE_IMGFMT_YV12) + || frame->proc_frame + || frame->proc_slice) { _x_post_frame_copy_down(frame, frame->next); skip = frame->next->draw(frame->next, stream); |