mirror of
https://github.com/jojo61/vdr-plugin-softhdcuvid.git
synced 2023-10-10 13:37:41 +02:00
Fix Connector Search for DRM
More debug prints in syslog
This commit is contained in:
parent
37f87e2511
commit
45a83eaa3f
16
drm.c
16
drm.c
@ -168,6 +168,7 @@ void set_video_mode(int width, int height) {
|
|||||||
drmModeConnector *connector;
|
drmModeConnector *connector;
|
||||||
drmModeModeInfo *mode;
|
drmModeModeInfo *mode;
|
||||||
int ii;
|
int ii;
|
||||||
|
printf("Set video mode %d &%d\n",width,height);
|
||||||
if (height != 1080 && height != 2160)
|
if (height != 1080 && height != 2160)
|
||||||
return;
|
return;
|
||||||
connector = drmModeGetConnector(render->fd_drm, render->connector_id);
|
connector = drmModeGetConnector(render->fd_drm, render->connector_id);
|
||||||
@ -274,6 +275,8 @@ static int FindDevice(VideoRender *render) {
|
|||||||
connector->connector_type_id);
|
connector->connector_type_id);
|
||||||
printf("Connector >%s< is %sconnected\n", connectorstr,
|
printf("Connector >%s< is %sconnected\n", connectorstr,
|
||||||
connector->connection == DRM_MODE_CONNECTED ? "" : "not ");
|
connector->connection == DRM_MODE_CONNECTED ? "" : "not ");
|
||||||
|
Debug(3,"Connector >%s< is %sconnected\n", connectorstr,
|
||||||
|
connector->connection == DRM_MODE_CONNECTED ? "" : "not ");
|
||||||
if (DRMConnector && strcmp(DRMConnector, connectorstr))
|
if (DRMConnector && strcmp(DRMConnector, connectorstr))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
@ -305,7 +308,7 @@ static int FindDevice(VideoRender *render) {
|
|||||||
mode = &connector->modes[ii];
|
mode = &connector->modes[ii];
|
||||||
|
|
||||||
printf("Mode %d %dx%d Rate %d\n", ii, mode->hdisplay, mode->vdisplay, mode->vrefresh);
|
printf("Mode %d %dx%d Rate %d\n", ii, mode->hdisplay, mode->vdisplay, mode->vrefresh);
|
||||||
|
Debug(3,"Mode %d %dx%d Rate %d\n", ii, mode->hdisplay, mode->vdisplay, mode->vrefresh);
|
||||||
if (VideoWindowWidth && VideoWindowHeight) { // preset by command line
|
if (VideoWindowWidth && VideoWindowHeight) { // preset by command line
|
||||||
if (VideoWindowWidth == mode->hdisplay && VideoWindowHeight == mode->vdisplay &&
|
if (VideoWindowWidth == mode->hdisplay && VideoWindowHeight == mode->vdisplay &&
|
||||||
mode->vrefresh == DRMRefresh && !(mode->flags & DRM_MODE_FLAG_INTERLACE)) {
|
mode->vrefresh == DRMRefresh && !(mode->flags & DRM_MODE_FLAG_INTERLACE)) {
|
||||||
@ -324,11 +327,16 @@ static int FindDevice(VideoRender *render) {
|
|||||||
found = 1;
|
found = 1;
|
||||||
i = resources->count_connectors; // uuuuhh
|
i = resources->count_connectors; // uuuuhh
|
||||||
}
|
}
|
||||||
VideoWindowWidth = render->mode.hdisplay;
|
|
||||||
VideoWindowHeight = render->mode.vdisplay;
|
if (found) {
|
||||||
if (found)
|
VideoWindowWidth = render->mode.hdisplay;
|
||||||
|
VideoWindowHeight = render->mode.vdisplay;
|
||||||
|
|
||||||
printf("Use Mode %d %dx%d Rate %d\n", ii, render->mode.hdisplay, render->mode.vdisplay,
|
printf("Use Mode %d %dx%d Rate %d\n", ii, render->mode.hdisplay, render->mode.vdisplay,
|
||||||
render->mode.vrefresh);
|
render->mode.vrefresh);
|
||||||
|
Debug(3,"Use Mode %d %dx%d Rate %d\n", ii, render->mode.hdisplay, render->mode.vdisplay,
|
||||||
|
render->mode.vrefresh);
|
||||||
|
}
|
||||||
drmModeFreeConnector(connector);
|
drmModeFreeConnector(connector);
|
||||||
}
|
}
|
||||||
if (!found) {
|
if (!found) {
|
||||||
|
@ -61,7 +61,7 @@ extern void ToggleLUT();
|
|||||||
/// vdr-plugin version number.
|
/// vdr-plugin version number.
|
||||||
/// Makefile extracts the version number for generating the file name
|
/// Makefile extracts the version number for generating the file name
|
||||||
/// for the distribution archive.
|
/// for the distribution archive.
|
||||||
static const char *const VERSION = "3.7.3"
|
static const char *const VERSION = "3.7.4"
|
||||||
#ifdef GIT_REV
|
#ifdef GIT_REV
|
||||||
"-GIT" GIT_REV
|
"-GIT" GIT_REV
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user