mirror of
https://github.com/jojo61/vdr-plugin-softhdcuvid.git
synced 2023-10-10 13:37:41 +02:00
Fix Placebo for AMD
This commit is contained in:
parent
3ca2a06e9d
commit
1878eaec88
@ -63,7 +63,7 @@ extern void ToggleLUT();
|
||||
/// vdr-plugin version number.
|
||||
/// Makefile extracts the version number for generating the file name
|
||||
/// for the distribution archive.
|
||||
static const char *const VERSION = "3.5.3"
|
||||
static const char *const VERSION = "3.5.4"
|
||||
#ifdef GIT_REV
|
||||
"-GIT" GIT_REV
|
||||
#endif
|
||||
|
11
video.c
11
video.c
@ -2409,6 +2409,7 @@ void generateVAAPIImage(CuvidDecoder * decoder, int index, const AVFrame * frame
|
||||
uint64_t first_time;
|
||||
VADRMPRIMESurfaceDescriptor desc;
|
||||
|
||||
vaSyncSurface(decoder->VaDisplay, (unsigned int)frame->data[3]);
|
||||
status =
|
||||
vaExportSurfaceHandle(decoder->VaDisplay, (unsigned int)frame->data[3], VA_SURFACE_ATTRIB_MEM_TYPE_DRM_PRIME_2,
|
||||
VA_EXPORT_SURFACE_READ_ONLY | VA_EXPORT_SURFACE_SEPARATE_LAYERS, &desc);
|
||||
@ -2417,7 +2418,7 @@ void generateVAAPIImage(CuvidDecoder * decoder, int index, const AVFrame * frame
|
||||
printf("Fehler beim export VAAPI Handle\n");
|
||||
return;
|
||||
}
|
||||
vaSyncSurface(decoder->VaDisplay, (unsigned int)frame->data[3]);
|
||||
//vaSyncSurface(decoder->VaDisplay, (unsigned int)frame->data[3]);
|
||||
Lock_and_SharedContext;
|
||||
for (n = 0; n < 2; n++) { // Set DMA_BUF from VAAPI decoder to Textures
|
||||
int id = desc.layers[n].object_index[0];
|
||||
@ -2431,6 +2432,11 @@ void generateVAAPIImage(CuvidDecoder * decoder, int index, const AVFrame * frame
|
||||
return;
|
||||
}
|
||||
|
||||
if (!size) {
|
||||
size = n==0 ? desc.width * desc.height: desc.width * desc.height /2 ;
|
||||
}
|
||||
|
||||
|
||||
// fmt = pl_find_fourcc(p->gpu,desc.layers[n].drm_format);
|
||||
#if 1
|
||||
if (decoder->PixFmt == AV_PIX_FMT_NV12) {
|
||||
@ -2592,6 +2598,7 @@ void generateVAAPIImage(CuvidDecoder * decoder, VASurfaceID index, const AVFrame
|
||||
#if defined (VAAPI) && !defined (RASPI)
|
||||
VADRMPRIMESurfaceDescriptor desc;
|
||||
|
||||
vaSyncSurface(decoder->VaDisplay, (VASurfaceID) (uintptr_t) frame->data[3]);
|
||||
status =
|
||||
vaExportSurfaceHandle(decoder->VaDisplay, (VASurfaceID) (uintptr_t) frame->data[3],
|
||||
VA_SURFACE_ATTRIB_MEM_TYPE_DRM_PRIME_2, VA_EXPORT_SURFACE_READ_ONLY | VA_EXPORT_SURFACE_SEPARATE_LAYERS,
|
||||
@ -2601,7 +2608,7 @@ void generateVAAPIImage(CuvidDecoder * decoder, VASurfaceID index, const AVFrame
|
||||
printf("Fehler beim export VAAPI Handle\n");
|
||||
return;
|
||||
}
|
||||
vaSyncSurface(decoder->VaDisplay, (VASurfaceID) (uintptr_t) frame->data[3]);
|
||||
//vaSyncSurface(decoder->VaDisplay, (VASurfaceID) (uintptr_t) frame->data[3]);
|
||||
#endif
|
||||
#ifdef RASPI
|
||||
AVDRMFrameDescriptor desc;
|
||||
|
Loading…
Reference in New Issue
Block a user