Introduce XRDP_H264 macro to indicate any H264 encoder enabled

This commit is contained in:
Koichiro Iwao 2024-08-26 18:18:08 +09:00
parent 07e4e23c7b
commit 7238f8f99d
2 changed files with 9 additions and 1 deletions

View File

@ -38,6 +38,14 @@
#include "xrdp_client_info.h"
#include "log.h"
#if defined(XRDP_X264) || defined(XRDP_OPENH264) || defined(XRDP_NVENC)
#if !defined(XRDP_H264)
#define XRDP_H264 1
#endif
#else
#undef XRDP_H264
#endif
/* xrdp.c */
long
g_xrdp_sync(long (*sync_func)(long param1, long param2), long sync_param1,

View File

@ -1440,7 +1440,7 @@ xrdp_mm_egfx_caps_advertise(void *user, int caps_count,
/* prefer h264, todo use setting in xrdp.ini for this */
if (best_h264_index >= 0)
{
#if defined(XRDP_X264) || defined(XRDP_NVENC)
#if defined(XRDP_H264)
best_index = best_h264_index;
self->egfx_flags = XRDP_EGFX_H264;
#endif