summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Stembridge <jstembridge@users.sourceforge.net>2003-04-24 00:21:01 +0000
committerJames Stembridge <jstembridge@users.sourceforge.net>2003-04-24 00:21:01 +0000
commit3f470710d81626eb7d18848661013ef5ccca4a1d (patch)
treeeed3b2221fe4d10b4fb9f4c89a5ac93aa514b1a4
parentc7aaa4cfb1c1ff8720fe38e48c511f9b0a342108 (diff)
downloadxine-lib-3f470710d81626eb7d18848661013ef5ccca4a1d.tar.gz
xine-lib-3f470710d81626eb7d18848661013ef5ccca4a1d.tar.bz2
fix scaling of video with aspect ratio != 1
CVS patchset: 4668 CVS date: 2003/04/24 00:21:01
-rw-r--r--ChangeLog1
-rw-r--r--src/xine-engine/vo_scale.c6
2 files changed, 4 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 92165f7bb..1cd6150fc 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -9,6 +9,7 @@ xine-lib (1-beta11)
* performance improvements (enabled ffmpeg direct rendering)
* faster seeking
* simple 10-band equalizer
+ * fix scaling of video with an aspect ratio not equal to one
xine-lib (1-beta10)
* loading and displaying png images (e.g. for logos)
diff --git a/src/xine-engine/vo_scale.c b/src/xine-engine/vo_scale.c
index ed024a1dc..8fa0cb328 100644
--- a/src/xine-engine/vo_scale.c
+++ b/src/xine-engine/vo_scale.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: vo_scale.c,v 1.19 2003/02/28 02:51:51 storri Exp $
+ * $Id: vo_scale.c,v 1.20 2003/04/24 00:21:01 jstembridge Exp $
*
* Contains common code to calculate video scaling parameters.
* In short, it will map frame dimensions to screen/window size.
@@ -151,7 +151,7 @@ void vo_scale_compute_output_size (vo_scale_t *this) {
* black borders to use.
* - exceding zoom shall be accounted by reducing displayed image.
*/
- if ( x_factor <= y_factor ) {
+ if ( x_factor <= (y_factor - (this->video_pixel_aspect - 1)) ) {
this->output_width = this->gui_width;
this->displayed_width = (double)this->delivered_width / this->zoom_factor_x + 0.5;
@@ -180,7 +180,7 @@ void vo_scale_compute_output_size (vo_scale_t *this) {
}
} else {
- if(x_factor < y_factor) {
+ if(x_factor < (y_factor - (this->video_pixel_aspect - 1))) {
this->output_width = (double) this->gui_width;
this->output_height = (double) this->delivered_height * x_factor + 0.5;
} else {