summaryrefslogtreecommitdiff
path: root/src/xine-engine/video_out.c
diff options
context:
space:
mode:
authorMiguel Freitas <miguelfreitas@users.sourceforge.net>2005-09-24 19:08:26 +0000
committerMiguel Freitas <miguelfreitas@users.sourceforge.net>2005-09-24 19:08:26 +0000
commit37cc903c609ca656a71852e5f50731f0b43bdda0 (patch)
tree50d8c59540de4b6ef20b24acd784903764b99522 /src/xine-engine/video_out.c
parent097426600056a112752e92eb1c13f0d6900f3907 (diff)
downloadxine-lib-37cc903c609ca656a71852e5f50731f0b43bdda0.tar.gz
xine-lib-37cc903c609ca656a71852e5f50731f0b43bdda0.tar.bz2
- rename all clip_top, clip_left, clip_color... to hili_xxxx. that
"clip" thing has caused too much confusion already since these variables define a highlight area. - add overlay offset support to video_out.c/alphablend/vo drivers - use overlay offset to implement proper croping of frames when vo driver doesn't support it - add clipping checks to alphablend to avoid buffer overflow, buffer "underflow" and wrapping. - increase vo api number - note: dxr3 support is incomplete about overlay offset CVS patchset: 7739 CVS date: 2005/09/24 19:08:26
Diffstat (limited to 'src/xine-engine/video_out.c')
-rw-r--r--src/xine-engine/video_out.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/xine-engine/video_out.c b/src/xine-engine/video_out.c
index 7e3ce577c..4928cc0c6 100644
--- a/src/xine-engine/video_out.c
+++ b/src/xine-engine/video_out.c
@@ -17,7 +17,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*
- * $Id: video_out.c,v 1.218 2005/02/14 14:04:55 holstsn Exp $
+ * $Id: video_out.c,v 1.219 2005/09/24 19:08:26 miguelfreitas Exp $
*
* frame allocation / queuing / scheduling / output functions
*/
@@ -338,6 +338,8 @@ static vo_frame_t *vo_get_frame (xine_video_port_t *this_gen,
img->crop_right = 0;
img->crop_top = 0;
img->crop_bottom = 0;
+ img->overlay_offset_x = 0;
+ img->overlay_offset_y = 0;
img->stream = NULL;
_x_extra_info_reset ( img->extra_info );
@@ -451,6 +453,8 @@ static int vo_frame_draw (vo_frame_t *img, xine_stream_t *stream) {
(this->grab_only ||
!(this->driver->get_capabilities (this->driver) & VO_CAP_CROP)) ) {
if (img->format == XINE_IMGFMT_YV12 || img->format == XINE_IMGFMT_YUY2) {
+ img->overlay_offset_x -= img->crop_left;
+ img->overlay_offset_y -= img->crop_top;
img = crop_frame( img->port, img );
img_already_locked = 1;
} else {
@@ -626,6 +630,8 @@ static vo_frame_t * duplicate_frame( vos_t *this, vo_frame_t *img ) {
dupl->crop_right = img->crop_right;
dupl->crop_top = img->crop_top;
dupl->crop_bottom = img->crop_bottom;
+ dupl->overlay_offset_x = img->overlay_offset_x;
+ dupl->overlay_offset_y = img->overlay_offset_y;
this->driver->update_frame_format (this->driver, dupl, dupl->width, dupl->height,
dupl->ratio, dupl->format, dupl->flags);
@@ -1604,6 +1610,8 @@ static vo_frame_t * crop_frame( xine_video_port_t *this_gen, vo_frame_t *img ) {
dupl->progressive_frame = img->progressive_frame;
dupl->repeat_first_field = img->repeat_first_field;
dupl->top_field_first = img->top_field_first;
+ dupl->overlay_offset_x = img->overlay_offset_x;
+ dupl->overlay_offset_y = img->overlay_offset_y;
switch (img->format) {
case XINE_IMGFMT_YV12: