Age | Commit message (Collapse) | Author |
|
Add an build option to allow explicitly shutting off libdrm-omap
features. This is useful for packaging situations to prevent
accidental unexpected features.
To deactivate the drm-omap specific functionality that was activated
unconditionally if present until now, use:
cmake -DKMSXX_ENABLE_LIBDRMOMAP=OFF
Signed-off-by: Matt Hoosier <matt.hoosier@garmin.com>
|
|
This makes package managers happier when the software is built
as a dynamic-library.
Signed-off-by: Matt Hoosier <matt.hoosier@garmin.com>
|
|
Many GPUs use bandwidth compression or tiling, and this information
must be passed along to KMS when constructing the framebuffer object
around the GEM handle or prime filedescriptor.
Add an vector of modifiers as an optional parameter to both of these
classes.
Bump the minimum required version of libdrm to 2.4.17 to ensure
drmModeAddFB2WithModifiers() is available.
Signed-off-by: Matt Hoosier <matt.hoosier@garmin.com>
|
|
Use std::array and .at() to get bounds checking.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Check that parameter vectors are of the same size, and match the number
of planes.
Extend the vectors to 4, as drmModeAddFB2() expects to get arrays of 4
elements.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Reported-by: Matt Hoosier <matt.hoosier@garmin.com>
|
|
Misc improvements
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
|
|
Use correct operator delete[] to free buffers in CPUFramebuffer
|
|
|
|
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Formatting changes and testmodes.py
|
|
Update travis to Ubuntu 18.04, and update the used compilers.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Add testmodes.py which goes through all videomodes from a connector one
by one.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Add to_string_short() and to_string_long() to videomode (using the fmt
library) for easy printing of videomodes.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Add fmt library as a submodule to make string formatting not a pain.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
|
|
V4L2 and DRM differ in their interpretation of YUV420::NV12
V4L2 NV12 is a Y and UV co-located planes in a single plane buffer.
DRM NV12 is a Y and UV planes presented as dual plane buffer, which is
known as NM12 in V4L2.
Since here we have hybrid DRM/V4L2 user space helper functions we need
to translate DRM::NV12 to V4L2:NM12 pixel format back and forth to keep
the data view consistent.
Signed-off-by: Benoit Parrot <bparrot@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Let's try again with the card constructors.
Card::open_modesetting_card() is removed.
The main constructor is Card(const std::string& dev_path = "").
If dev_path is set, the device node with that path is used. If dev_path
is not set, the behavior is similar as previously, except a modeset
capable card is used at the third step:
- If KMSXX_DEVICE env variable is set, the card device with that path is
opened.
- If KMSXX_DRIVER env variable is set, the card with the given driver
name and index is opened. The format is either "drvname" or
"drvname:idx".
- If neither env variable is given, the first modeset capable card is
opened.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
This reverts commit 27f1c296c4f5996227b28215400c787ea018862b.
|
|
This reverts commit c223cffa20d617863bffb0c7e3890172d93a53c8.
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Add open_modesetting_card() which iterates the DRM cards and returns the
first one that has crtcs and connectors.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Allow opening DRM cards without dumb buffers.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Allow opening DRM cards without any resources.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Add new Card constructor:
Card(const std::string& driver, uint32_t idx)
which can be used to open Nth card for the given driver.
The default constructor behavior is:
- If KMSXX_DEVICE env variable is set, the card device with that path is
opened.
- If KMSXX_DRIVER env variable is set, the card with the given driver
name and index is opened. The format is either "drvname" or
"drvname:idx".
- If neither env variable is given, open /dev/dri/card0
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Add support to get the driver name.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Use m_fd consistently.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
|
|
Signed-off-by: Benoit Parrot <bparrot@ti.com>
|
|
Add crop/selection parameter support.
Signed-off-by: Benoit Parrot <bparrot@ti.com>
|