summaryrefslogtreecommitdiff
path: root/lib/igt_kms.h
AgeCommit message (Collapse)Author
2014-06-12lib: various documentation fixesThomas Wood
Fix some documentation comments and mark some struct members private. Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2014-04-30lib: extract kmstest_set_connector_dpmsDaniel Vetter
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-26lib: fold igt_display into igt_kmsDaniel Vetter
For 1 function and 2 types we kinda don't need separate files. Especially now that igt_kms is much more focused on the actual modeset stuff with all the framebuffer helpers extracted to igt_fb. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-26lib/igt_fb: switch to igt_ prefix from kmstest_Daniel Vetter
Shorter and more in line with our general igt_ prefix for everything which isn't somehow intel or i915-gem or otherwise hw specific - these helpers here are all fully generic framebuffer handling functions based on kms + cairo. Well, the actual buffer alloc is done with i915 gem, but meh ;-) Two special cases: - bpp_depth_to_drm_format and drm_format_to_bpp completely lacked prefixes, so just add igt_. - write_fb was a bit misleading given that we have gem_write for uploading to buffers. Rename that to write_fb_to_png to make it crystal clear what this thing does even without looking at docs. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-26lib: extract igt_fb libraryDaniel Vetter
Stuff all the framebuffer creation, cairo and drm fourcc format handling in there. This gives us a very clear cut in the headers where igt_fb.c only needs to include igt_fb.h, and igt_kms.c includes both (well igt_kms.h pulls in igt_fb.h since we always need this). The aim here is to add api docs for igt_fb since that part of the kms library seems fairly stable already, while all the mode setting and iteration is still a bit in flux. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-26lib/igt_kms: make kmstest_get_cairo_surface staticDaniel Vetter
Only used internally in igt_kms.c. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-26lib/igt_kms: s/kmstest_create_fb2/kmstest_create_fb/Daniel Vetter
Simplify the name since the old _fb function is now gone. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-26lib: remove kmstest_create_fbDaniel Vetter
Use the new-style function using drm fourcc codes instead everywhere. To easily use thew fourcc based interface also expose bpp_depth_to_drm_format from the library. Finally include drm_fourcc.h from the igt_kms.h header since pretty much everyone needs this now. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-23lib: extract igt_aux.[hc]Daniel Vetter
And shovel all the various helpers in there. Also move igt_set_vt_graphics_mode to igt_kms.h since the function is implemented in igt_kms.c. And it fits better. I kinda missed this in the prep work. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-22lib: unnecessary header removal for drmtest.h, part 2Daniel Vetter
I've left unistd.h in it - it's not strictly required but most users of drmtest.h want it for the open helpers, and then you kinda need to close that file descriptor again ... Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-22lib: more unecessary header removalDaniel Vetter
This time big with media_fill.h Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-22lib: remove uncessary #includes from headersDaniel Vetter
Only include what the header itself needs. The big fish here is intel-gpu-tools.h. More will follow. One ugly thing removed here is the duplicated GEN6_TD_CTL #define, one of which was broken. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-13lib/igt_kms: rip out custom verbose loggin supportDaniel Vetter
Instead just piggy-pack on top of igt_log. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-02-11lib: fix header includeDaniel Vetter
drm/ path is for the headers from kernel sources, without when using the pkgconfig libdrm version. Cc: Damien Lespiau <damien.lespiau@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-02-11lib: Fix igt_ouput_get_plane() typo (output)Damien Lespiau
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-02-11lib/display: Wait for a vblank after SetPlane()Damien Lespiau
Let's be testing friendly and gently wait for the next vblank before returning from commit() when needed. After igt_display_commit() one can safely look at the CRC. Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-02-11lib: Include drm_fourcc.h from igt_kms.hDamien Lespiau
This include is needed for the DRM_FORMAT* defines used in the fb creation helpers. Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-02-11lib: Introduce a new helper kmstest_create_color_fb()Damien Lespiau
We need to create fbs of a single color in a few places. Time to abstract that out to a helper function. Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-02-11lib/display: Add support for DRM planesDamien Lespiau
We can now extend our plane support beyond primary and cursor planes. Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-02-11lib/display: Add a way to specify we don't care about the pipe to useDamien Lespiau
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-02-11lib/display: Add support for the cursor planeDamien Lespiau
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-02-11lib/display: Add an accessor to retrieve the number of pipesDamien Lespiau
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-02-11lib: Introduce a for_each_connected_output() macroDamien Lespiau
So we can easily cycle through them in tests without knowing too many internal details about how igt_display_t organize its data. Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-02-11lib: Introduce symbolic names for display planesDamien Lespiau
It'd be nice to have symbolic names for planes instead of using an index in igt_output_get_plane(). We also namespace the enum to not conflict with anyone. Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2014-02-11lib: Introduce a modeset APIDamien Lespiau
The goals here are: - Reduce duplicated code in each KMS test - Provide an API that looks more like what we want for atomic modesets. The hope is then that it'll be easy to switch, at run-time, between the "legacy" path and atomic modesets, keeping the same API for tests. Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2013-12-31kmstest: Fix up lifetimes of cairo objectsChris Wilson
cairo_t is the short lived drawing context, whereas cairo_surface_t is the heavyweight object that persists and is also tied to underlying GEM objects. So make the kmstest API reflect the different weights and fix the lifetime and underlying object reference leaks. Based on the fix by Paulo Zanoni. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-11-12lib: Move kms stuff from drmtest.c over to igt_kms.cOscar Mateo
This makes cairo dependencies easier to handle. Otherwise, we would have to litter drmtest all over with "#ifndef ANDROID" Signed-off-by: Oscar Mateo <oscar.mateo@intel.com> [danvet: Add missing _GNU_SOURCE to igt_kms.c and missing include to intel_sprite_on.c] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>