summaryrefslogtreecommitdiffstats
path: root/stream/stream_avdevice.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2012-11-30 17:45:40 +0100
committerwm4 <wm4@nowhere>2012-12-03 21:08:51 +0100
commit3b4682183ceecdf6c34237f66b3ddcbc4cf849e2 (patch)
tree98042e69930adc9806d57ac69ef0cf91eaae70ae /stream/stream_avdevice.c
parent9ace4f1f4982891a25ff98126649bcf5b3816326 (diff)
downloadmpv-3b4682183ceecdf6c34237f66b3ddcbc4cf849e2.tar.bz2
mpv-3b4682183ceecdf6c34237f66b3ddcbc4cf849e2.tar.xz
vo_xv: try harder to get correctly aligned pointers/strides
To get guaranteed alignment for the chroma planes with typical YV12 playback, we have to double the alignment on the image width, as the chroma planes have half the image width. Clear the image with black instead of green to hide scaling artifacts on the right border of the screen. (It might be possible to create the image layout ourselves by not calling XvShmCreateImage(), and filling in our own image width and exact strides, but that's probably too risky: the Xv client library sends an X protocol request to query the real image dimension and strides. It is unknown to me whether X servers or drivers would generally accept an image with mismatching parameters, even if the image is conceptually valid.) Allocate the image with av_malloc() in the non-SHM case. I suspect the non-SHM case doesn't matter much, though.
Diffstat (limited to 'stream/stream_avdevice.c')
0 files changed, 0 insertions, 0 deletions