Mode Setting through libdrm
Ville Syrjälä
ville.syrjala at linux.intel.com
Wed Mar 9 16:05:59 UTC 2016
On Wed, Mar 09, 2016 at 10:15:17AM -0300, Alberto Simón Francés wrote:
> Hello,
>
> I have a question with regards to the libdrm library. I'm currently working
> on an app that relies on KMS, DRM and EGL to output accelerated graphics
> without a display server in between. It does so to reduce input latency.
> The system this app will run is connected to a CRT monitor and I'd like to
> be able to switch resolutions in order to use the best resolution depending
> on the input of the user and do so as fast as possible. I understand that
> this might pose problems to the user but it will run on a custom
> installation of Linux devoted just to this application. It doesn't need to
> interact with other apps at all.
>
> The problem I have is that I haven't found info on how I would go about
> doing this with libdrm. I need to be able to set custom timings to drive
> the display, since it's not just about driving the monitor with standard
> resolutions. This monitor doesn't report correct EDID info and won't report
> it either. Currently it's using a single default resolution I baked in, but
> the idea is to be able to switch between them.
>
> I know that this is possible by drivers, I've seen examples in the drivers
> themselves, but I still haven't been able to make the connection since the
> documentation on the specific calls, functions and structures is sparse.
>
> I'd appreciate any help you could give me or any pointers.
Just populate a drmModeModeInfo with whatever custom timings you want,
and then feed it to drmModeSetCrtc().
--
Ville Syrjälä
Intel OTC
More information about the dri-devel
mailing list