[vlc-devel] commit: XCB: duplicate values from output to fmt_out ( Rémi Denis-Courmont )
git version control
git at videolan.org
Thu Jan 29 21:14:10 CET 2009
vlc | branch: master | Rémi Denis-Courmont <rdenis at simphalempin.com> | Thu Jan 29 22:01:40 2009 +0200| [7a710eaac222197044bb1c188dd5ac131c529123] | committer: Rémi Denis-Courmont
XCB: duplicate values from output to fmt_out
The image still misses borders due to Qt4 window provider not returning
the correct height (it pretends the window is bigger than it is).
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=7a710eaac222197044bb1c188dd5ac131c529123
---
modules/video_output/xcb/xcb.c | 23 ++++++++++++++++++-----
1 files changed, 18 insertions(+), 5 deletions(-)
diff --git a/modules/video_output/xcb/xcb.c b/modules/video_output/xcb/xcb.c
index 9cf1535..48f3164 100644
--- a/modules/video_output/xcb/xcb.c
+++ b/modules/video_output/xcb/xcb.c
@@ -406,13 +406,26 @@ static int Init (vout_thread_t *vout)
default:
assert (0);
}
-
vout_PlacePicture (vout, width, height, &x, &y, &width, &height);
- vout->output.i_width = width;
- vout->output.i_height = height;
- assert (height > 0);
- vout->output.i_aspect = width * VOUT_ASPECT_FACTOR / height;
+
/* FIXME: I don't get the subtlety between output and fmt_out here */
+ vout->fmt_out.i_chroma = vout->output.i_chroma;
+ vout->fmt_out.i_visible_width = width;
+ vout->fmt_out.i_visible_height = height;
+ vout->fmt_out.i_sar_num = vout->fmt_out.i_sar_den = 1;
+
+ vout->output.i_width = vout->fmt_out.i_width =
+ width * vout->fmt_in.i_width / vout->fmt_in.i_visible_width;
+ vout->output.i_height = vout->fmt_out.i_height =
+ height * vout->fmt_in.i_height / vout->fmt_in.i_visible_height;
+ vout->fmt_out.i_x_offset =
+ width * vout->fmt_in.i_x_offset / vout->fmt_in.i_visible_width;
+ p_vout->fmt_out.i_y_offset =
+ height * vout->fmt_in.i_y_offset / vout->fmt_in.i_visible_height;
+
+ assert (height > 0);
+ vout->output.i_aspect = vout->fmt_out.i_aspect =
+ width * VOUT_ASPECT_FACTOR / height;
/* Create window */
const uint32_t mask = XCB_CW_BACK_PIXEL | XCB_CW_EVENT_MASK;
More information about the vlc-devel
mailing list