summaryrefslogtreecommitdiff
path: root/video.c
diff options
context:
space:
mode:
authorJohns <johns98@gmx.net>2014-01-14 14:59:01 +0100
committerJohns <johns98@gmx.net>2014-01-14 14:59:01 +0100
commit501d46793f19062c5fb20c8b8d8091b27a7cd19c (patch)
tree297e3f2512c7a57f692fb1f39e1c647c60c10eb6 /video.c
parent978fc59abadba1b9d305572554e6638198753a00 (diff)
downloadvdr-plugin-softhddevice-501d46793f19062c5fb20c8b8d8091b27a7cd19c.tar.gz
vdr-plugin-softhddevice-501d46793f19062c5fb20c8b8d8091b27a7cd19c.tar.bz2
Fix alternative OSD support with VDPAU bitmap surfaces.
Diffstat (limited to 'video.c')
-rw-r--r--video.c20
1 files changed, 17 insertions, 3 deletions
diff --git a/video.c b/video.c
index ef6facd..4656397 100644
--- a/video.c
+++ b/video.c
@@ -46,7 +46,7 @@
#define USE_DOUBLEBUFFER ///< use GLX double buffers
//#define USE_VAAPI ///< enable vaapi support
//#define USE_VDPAU ///< enable vdpau support
-#define noUSE_BITMAP ///< use vdpau bitmap surface
+//#define USE_BITMAP ///< use vdpau bitmap surface
//#define AV_INFO ///< log a/v sync informations
#ifndef AV_INFO_TIME
#define AV_INFO_TIME (50 * 60) ///< a/v info every minute
@@ -8024,7 +8024,7 @@ static void VdpauMixOsd(void)
status =
VdpauOutputSurfaceRenderBitmapSurface(VdpauSurfacesRb
[VdpauSurfaceIndex], &output_double_rect,
- VdpauOsdOutputSurface[!VdpauOsdSurfaceIndex], &source_rect, NULL,
+ VdpauOsdBitmapSurface[!VdpauOsdSurfaceIndex], &source_rect, NULL,
VideoTransparentOsd ? &blend_state : NULL,
VDP_OUTPUT_SURFACE_RENDER_ROTATE_0);
if (status != VDP_STATUS_OK) {
@@ -8253,15 +8253,29 @@ static void VdpauBlackSurface(VdpauDecoder * decoder)
output_rect.y1 = decoder->VideoHeight;
}
+ // FIXME: double buffered osd disabled
+ // VdpauOsdSurfaceIndex always 0 and only 0 valid
+#ifdef USE_BITMAP
+ status =
+ VdpauOutputSurfaceRenderBitmapSurface(VdpauSurfacesRb
+ [VdpauSurfaceIndex], &output_rect,
+ VdpauOsdBitmapSurface[VdpauOsdSurfaceIndex], &source_rect, NULL, NULL,
+ VDP_OUTPUT_SURFACE_RENDER_ROTATE_0);
+ if (status != VDP_STATUS_OK) {
+ Error(_("video/vdpau: can't render output surface: %s\n"),
+ VdpauGetErrorString(status));
+ }
+#else
status =
VdpauOutputSurfaceRenderOutputSurface(VdpauSurfacesRb
[VdpauSurfaceIndex], &output_rect,
- VdpauOsdOutputSurface[!VdpauOsdSurfaceIndex], &source_rect, NULL, NULL,
+ VdpauOsdOutputSurface[VdpauOsdSurfaceIndex], &source_rect, NULL, NULL,
VDP_OUTPUT_SURFACE_RENDER_ROTATE_0);
if (status != VDP_STATUS_OK) {
Error(_("video/vdpau: can't render output surface: %s\n"),
VdpauGetErrorString(status));
}
+#endif
}
///