From 1992bb51515b46555e2a75b780dc79d973b7cf3a Mon Sep 17 00:00:00 2001 From: Lionel CHAZALLON Date: Sun, 22 Oct 2017 23:59:58 -0700 Subject: video : Move drm options to substruct. This allows to group them and most of all query the group config when needed and when we don't have the access to vo. --- video/out/drm_common.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'video/out/drm_common.c') diff --git a/video/out/drm_common.c b/video/out/drm_common.c index c1f374118a..8402ac7e69 100644 --- a/video/out/drm_common.c +++ b/video/out/drm_common.c @@ -41,6 +41,18 @@ static int vt_switcher_pipe[2]; +#define OPT_BASE_STRUCT struct drm_opts +const struct m_sub_options drm_conf = { + .opts = (const struct m_option[]) { + OPT_STRING_VALIDATE("drm-connector", drm_connector_spec, + 0, drm_validate_connector_opt), + OPT_INT("drm-mode", drm_mode_id, 0), + OPT_INT("drm-overlay", drm_overlay_id, 0), + {0}, + }, + .size = sizeof(struct drm_opts), +}; + static const char *connector_names[] = { "Unknown", // DRM_MODE_CONNECTOR_Unknown "VGA", // DRM_MODE_CONNECTOR_VGA -- cgit v1.2.3