|
|
@ -324,7 +324,9 @@ void wlr_drm_output_start_renderer(struct wlr_drm_output *output) {
|
|
|
|
bo = plane->back;
|
|
|
|
bo = plane->back;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
drmModeModeInfo *mode = &output->output.current_mode->state->mode;
|
|
|
|
struct wlr_drm_output_mode *_mode =
|
|
|
|
|
|
|
|
(struct wlr_drm_output_mode *)output->output.current_mode;
|
|
|
|
|
|
|
|
drmModeModeInfo *mode = &_mode->mode;
|
|
|
|
backend->iface->crtc_pageflip(backend, output, crtc, get_fb_for_bo(bo), mode);
|
|
|
|
backend->iface->crtc_pageflip(backend, output, crtc, get_fb_for_bo(bo), mode);
|
|
|
|
output->pageflip_pending = true;
|
|
|
|
output->pageflip_pending = true;
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -760,18 +762,16 @@ void wlr_drm_scan_connectors(struct wlr_drm_backend *backend) {
|
|
|
|
wlr_log(L_INFO, "Detected modes:");
|
|
|
|
wlr_log(L_INFO, "Detected modes:");
|
|
|
|
|
|
|
|
|
|
|
|
for (int i = 0; i < conn->count_modes; ++i) {
|
|
|
|
for (int i = 0; i < conn->count_modes; ++i) {
|
|
|
|
struct wlr_output_mode_state *_state = calloc(1,
|
|
|
|
struct wlr_drm_output_mode *mode = calloc(1,
|
|
|
|
sizeof(struct wlr_output_mode_state));
|
|
|
|
sizeof(struct wlr_drm_output_mode));
|
|
|
|
_state->mode = conn->modes[i];
|
|
|
|
mode->mode = conn->modes[i];
|
|
|
|
struct wlr_output_mode *mode = calloc(1,
|
|
|
|
mode->wlr_mode.width = mode->mode.hdisplay;
|
|
|
|
sizeof(struct wlr_output_mode));
|
|
|
|
mode->wlr_mode.height = mode->mode.vdisplay;
|
|
|
|
mode->width = _state->mode.hdisplay;
|
|
|
|
mode->wlr_mode.refresh = calculate_refresh_rate(&mode->mode);
|
|
|
|
mode->height = _state->mode.vdisplay;
|
|
|
|
|
|
|
|
mode->refresh = calculate_refresh_rate(&_state->mode);
|
|
|
|
|
|
|
|
mode->state = _state;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
wlr_log(L_INFO, " %"PRId32"@%"PRId32"@%"PRId32,
|
|
|
|
wlr_log(L_INFO, " %"PRId32"@%"PRId32"@%"PRId32,
|
|
|
|
mode->width, mode->height, mode->refresh);
|
|
|
|
mode->wlr_mode.width, mode->wlr_mode.height,
|
|
|
|
|
|
|
|
mode->wlr_mode.refresh);
|
|
|
|
|
|
|
|
|
|
|
|
list_add(output->output.modes, mode);
|
|
|
|
list_add(output->output.modes, mode);
|
|
|
|
}
|
|
|
|
}
|
|
|
|