Functions that deal with setup of outputs. More...
Functions | |
EAPI Eina_Bool | ecore_drm2_outputs_create (Ecore_Drm2_Device *device) |
Iterate drm resources and create outputs. More... | |
EAPI void | ecore_drm2_outputs_destroy (Ecore_Drm2_Device *device) |
Destroy any created outputs. More... | |
EAPI const Eina_List * | ecore_drm2_outputs_get (Ecore_Drm2_Device *device) |
Get the list of outputs from a drm device. More... | |
EAPI int | ecore_drm2_output_dpms_get (Ecore_Drm2_Output *output) |
Get the dpms level of a given output. More... | |
EAPI void | ecore_drm2_output_dpms_set (Ecore_Drm2_Output *output, int level) |
Set the dpms level of a given output. More... | |
EAPI char * | ecore_drm2_output_edid_get (Ecore_Drm2_Output *output) |
Get the edid of a given output. More... | |
EAPI Eina_Bool | ecore_drm2_output_backlight_get (Ecore_Drm2_Output *output) |
Get if a given output has a backlight. More... | |
EAPI Ecore_Drm2_Output * | ecore_drm2_output_find (Ecore_Drm2_Device *device, int x, int y) |
Find an output at the given position. More... | |
EAPI void | ecore_drm2_output_dpi_get (Ecore_Drm2_Output *output, int *xdpi, int *ydpi) |
Get the dpi of a given output. More... | |
EAPI unsigned int | ecore_drm2_output_crtc_get (Ecore_Drm2_Output *output) |
Get the id of the crtc that an output is using. More... | |
EAPI Ecore_Drm2_Fb * | ecore_drm2_output_latest_fb_get (Ecore_Drm2_Output *output) |
Return the most recently set Ecore_Drm2_Fb for a given output. More... | |
EAPI Eina_Bool | ecore_drm2_output_primary_get (Ecore_Drm2_Output *output) |
Get if a given output is marked as the primary output. More... | |
EAPI void | ecore_drm2_output_primary_set (Ecore_Drm2_Output *output, Eina_Bool primary) |
Set a given output to be primary. More... | |
EAPI Eina_Bool | ecore_drm2_output_enabled_get (Ecore_Drm2_Output *output) |
Get if a given output is enabled. More... | |
EAPI void | ecore_drm2_output_enabled_set (Ecore_Drm2_Output *output, Eina_Bool enabled) |
Set if a given output is enabled. More... | |
EAPI void | ecore_drm2_output_physical_size_get (Ecore_Drm2_Output *output, int *w, int *h) |
Get the physical size of a given output. More... | |
EAPI const Eina_List * | ecore_drm2_output_modes_get (Ecore_Drm2_Output *output) |
Get a list of the modes supported on a given output. More... | |
EAPI void | ecore_drm2_output_mode_info_get (Ecore_Drm2_Output_Mode *mode, int *w, int *h, unsigned int *refresh, unsigned int *flags) |
Get information from an existing output mode. More... | |
EAPI Eina_Bool | ecore_drm2_output_mode_set (Ecore_Drm2_Output *output, Ecore_Drm2_Output_Mode *mode, int x, int y) |
Set a given mode to be used on a given output. More... | |
EAPI char * | ecore_drm2_output_name_get (Ecore_Drm2_Output *output) |
Get the name of a given output. More... | |
EAPI char * | ecore_drm2_output_model_get (Ecore_Drm2_Output *output) |
Get the model of a given output. More... | |
EAPI Eina_Bool | ecore_drm2_output_connected_get (Ecore_Drm2_Output *output) |
Get if a given output is connected. More... | |
EAPI Eina_Bool | ecore_drm2_output_cloned_get (Ecore_Drm2_Output *output) |
Get if a given output is cloned. More... | |
EAPI unsigned int | ecore_drm2_output_connector_type_get (Ecore_Drm2_Output *output) |
Get the connector type of a given output. More... | |
EAPI void | ecore_drm2_output_info_get (Ecore_Drm2_Output *output, int *x, int *y, int *w, int *h, unsigned int *refresh) |
Get the geometry and refresh rate for a given output. More... | |
EAPI Eina_Bool | ecore_drm2_output_possible_crtc_get (Ecore_Drm2_Output *output, unsigned int crtc) |
Get if an output can be used on a given crtc. More... | |
EAPI void | ecore_drm2_output_gamma_set (Ecore_Drm2_Output *output, uint16_t size, uint16_t *red, uint16_t *green, uint16_t *blue) |
Set the gamma level of an Ecore_Drm_Output. More... | |
EAPI int | ecore_drm2_output_supported_rotations_get (Ecore_Drm2_Output *output) |
Get the supported rotations of a given output. More... | |
EAPI Eina_Bool | ecore_drm2_output_rotation_set (Ecore_Drm2_Output *output, int rotation) |
Set a rotation on a given output. More... | |
EAPI int | ecore_drm2_output_rotation_get (Ecore_Drm2_Output *output) |
Get current output rotation. More... | |
EAPI void | ecore_drm2_output_user_data_set (Ecore_Drm2_Output *o, void *data) |
Set the user data for the output's page flip handler. More... | |
EAPI void * | ecore_drm2_output_user_data_get (Ecore_Drm2_Output *output) |
Get the user data for a given output. More... | |
EAPI unsigned int | ecore_drm2_output_subpixel_get (const Ecore_Drm2_Output *output) |
Get the subpixel state of the output. More... | |
EAPI void | ecore_drm2_output_relative_mode_set (Ecore_Drm2_Output *output, Ecore_Drm2_Relative_Mode mode) |
Set the relative mode for an output. More... | |
EAPI Ecore_Drm2_Relative_Mode | ecore_drm2_output_relative_mode_get (Ecore_Drm2_Output *output) |
Get the relative mode of an output. More... | |
EAPI void | ecore_drm2_output_relative_to_set (Ecore_Drm2_Output *output, const char *relative) |
Set which output a given output is relative to. More... | |
EAPI const char * | ecore_drm2_output_relative_to_get (Ecore_Drm2_Output *output) |
Get which output is relative to a given output. More... | |
EAPI void * | ecore_drm2_fb_bo_get (Ecore_Drm2_Fb *fb) |
Get the Framebuffer's gbm buffer object. More... | |
EAPI Eina_Bool | ecore_drm2_output_blanktime_get (Ecore_Drm2_Output *output, int sequence, long *sec, long *usec) |
Get the time of the last vblank. More... | |
EAPI Eina_Bool | ecore_drm2_output_pending_get (Ecore_Drm2_Output *output) |
Check if there's a pageflip in progress for an output. More... | |
Functions that deal with setup of outputs.
Iterate drm resources and create outputs.
device |
References EEZE_UDEV_EVENT_ADD, EEZE_UDEV_EVENT_CHANGE, EEZE_UDEV_EVENT_REMOVE, EEZE_UDEV_TYPE_DRM, eeze_udev_watch_add(), EINA_FALSE, eina_list_count(), EINA_SAFETY_ON_NULL_RETURN_VAL, EINA_SAFETY_ON_TRUE_RETURN_VAL, and EINA_TRUE.
EAPI void ecore_drm2_outputs_destroy | ( | Ecore_Drm2_Device * | device | ) |
Destroy any created outputs.
device |
References EINA_LIST_FREE, and EINA_SAFETY_ON_NULL_RETURN.
Get the list of outputs from a drm device.
device |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI int ecore_drm2_output_dpms_get | ( | Ecore_Drm2_Output * | output | ) |
Get the dpms level of a given output.
output |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI void ecore_drm2_output_dpms_set | ( | Ecore_Drm2_Output * | output, |
int | level | ||
) |
Set the dpms level of a given output.
output | |
level |
References ecore_drm2_fb_flip(), EINA_SAFETY_ON_NULL_RETURN, and EINA_SAFETY_ON_TRUE_RETURN.
Referenced by ecore_drm2_output_enabled_set().
EAPI char * ecore_drm2_output_edid_get | ( | Ecore_Drm2_Output * | output | ) |
Get the edid of a given output.
output |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
Get if a given output has a backlight.
output |
References EINA_FALSE, and EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI Ecore_Drm2_Output * ecore_drm2_output_find | ( | Ecore_Drm2_Device * | device, |
int | x, | ||
int | y | ||
) |
Find an output at the given position.
device | |
x | |
y |
References EINA_LIST_FOREACH, and EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI void ecore_drm2_output_dpi_get | ( | Ecore_Drm2_Output * | output, |
int * | xdpi, | ||
int * | ydpi | ||
) |
Get the dpi of a given output.
output | |
xdpi | |
ydpi |
References EINA_SAFETY_ON_NULL_RETURN, and EINA_SAFETY_ON_TRUE_RETURN.
EAPI unsigned int ecore_drm2_output_crtc_get | ( | Ecore_Drm2_Output * | output | ) |
Get the id of the crtc that an output is using.
output |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI Ecore_Drm2_Fb * ecore_drm2_output_latest_fb_get | ( | Ecore_Drm2_Output * | output | ) |
Return the most recently set Ecore_Drm2_Fb for a given output.
This may be the currently scanned out buffer, a buffer currently being flipped to scanout, or a buffer that has been submit but may not actually ever hit scanout at all.
output |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
Get if a given output is marked as the primary output.
output |
References EINA_FALSE, and EINA_SAFETY_ON_NULL_RETURN_VAL.
Set a given output to be primary.
output | |
primary |
References EINA_SAFETY_ON_NULL_RETURN.
Get if a given output is enabled.
output |
References EINA_FALSE, and EINA_SAFETY_ON_NULL_RETURN_VAL.
Set if a given output is enabled.
output | |
enabled |
References ecore_drm2_fb_flip(), ecore_drm2_output_dpms_set(), and EINA_SAFETY_ON_NULL_RETURN.
EAPI void ecore_drm2_output_physical_size_get | ( | Ecore_Drm2_Output * | output, |
int * | w, | ||
int * | h | ||
) |
Get the physical size of a given output.
This function will give the physical size (in mm) of an output
output | |
*w | |
*h |
References EINA_SAFETY_ON_NULL_RETURN.
Get a list of the modes supported on a given output.
output |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI void ecore_drm2_output_mode_info_get | ( | Ecore_Drm2_Output_Mode * | mode, |
int * | w, | ||
int * | h, | ||
unsigned int * | refresh, | ||
unsigned int * | flags | ||
) |
Get information from an existing output mode.
mode | |
w | |
h | |
refresh | |
flags |
References EINA_SAFETY_ON_NULL_RETURN.
EAPI Eina_Bool ecore_drm2_output_mode_set | ( | Ecore_Drm2_Output * | output, |
Ecore_Drm2_Output_Mode * | mode, | ||
int | x, | ||
int | y | ||
) |
Set a given mode to be used on a given output.
output | |
mode | |
x | |
y |
References EINA_FALSE, EINA_SAFETY_ON_NULL_RETURN_VAL, EINA_SAFETY_ON_TRUE_RETURN_VAL, EINA_TRUE, and ERR.
EAPI char * ecore_drm2_output_name_get | ( | Ecore_Drm2_Output * | output | ) |
Get the name of a given output.
output |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI char * ecore_drm2_output_model_get | ( | Ecore_Drm2_Output * | output | ) |
Get the model of a given output.
output |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
Get if a given output is connected.
output |
References EINA_FALSE, and EINA_SAFETY_ON_NULL_RETURN_VAL.
Get if a given output is cloned.
output |
References EINA_FALSE, and EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI unsigned int ecore_drm2_output_connector_type_get | ( | Ecore_Drm2_Output * | output | ) |
Get the connector type of a given output.
output |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI void ecore_drm2_output_info_get | ( | Ecore_Drm2_Output * | output, |
int * | x, | ||
int * | y, | ||
int * | w, | ||
int * | h, | ||
unsigned int * | refresh | ||
) |
Get the geometry and refresh rate for a given output.
output | |
*x | |
*y | |
*w | |
*h | |
*refresh |
References EINA_SAFETY_ON_NULL_RETURN, and EINA_SAFETY_ON_TRUE_RETURN.
EAPI Eina_Bool ecore_drm2_output_possible_crtc_get | ( | Ecore_Drm2_Output * | output, |
unsigned int | crtc | ||
) |
Get if an output can be used on a given crtc.
This function will loop the possible crtcs of an encoder to determine if a given output can be assigned to a given crtc
output | |
crtc |
References EINA_FALSE, EINA_SAFETY_ON_NULL_RETURN_VAL, EINA_SAFETY_ON_TRUE_RETURN_VAL, and EINA_TRUE.
EAPI void ecore_drm2_output_gamma_set | ( | Ecore_Drm2_Output * | output, |
uint16_t | size, | ||
uint16_t * | red, | ||
uint16_t * | green, | ||
uint16_t * | blue | ||
) |
Set the gamma level of an Ecore_Drm_Output.
This function will set the gamma of an Ecore_Drm2_Output
output | The Ecore_Drm2_Output to set the gamma level on |
size | The gamma table size to set |
red | The amount to scale the red channel |
green | The amount to scale the green channel |
blue | The amount to scale the blue channel |
References EINA_SAFETY_ON_NULL_RETURN, EINA_SAFETY_ON_TRUE_RETURN, and ERR.
EAPI int ecore_drm2_output_supported_rotations_get | ( | Ecore_Drm2_Output * | output | ) |
Get the supported rotations of a given output.
output |
References EINA_LIST_FOREACH, and EINA_SAFETY_ON_NULL_RETURN_VAL.
Set a rotation on a given output.
output | |
rotation |
References EINA_FALSE, EINA_LIST_FOREACH, EINA_SAFETY_ON_NULL_RETURN_VAL, EINA_TRUE, and WRN.
EAPI int ecore_drm2_output_rotation_get | ( | Ecore_Drm2_Output * | output | ) |
Get current output rotation.
output |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI void ecore_drm2_output_user_data_set | ( | Ecore_Drm2_Output * | o, |
void * | data | ||
) |
Set the user data for the output's page flip handler.
o | The output to update user data for |
data | The new user data pointer |
References EINA_SAFETY_ON_NULL_RETURN.
EAPI void * ecore_drm2_output_user_data_get | ( | Ecore_Drm2_Output * | output | ) |
Get the user data for a given output.
output | The output to get user data for |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI unsigned int ecore_drm2_output_subpixel_get | ( | const Ecore_Drm2_Output * | output | ) |
Get the subpixel state of the output.
output | the output |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI void ecore_drm2_output_relative_mode_set | ( | Ecore_Drm2_Output * | output, |
Ecore_Drm2_Relative_Mode | mode | ||
) |
Set the relative mode for an output.
output | The output to set relative mode |
mode | The relative mode to set |
References EINA_SAFETY_ON_NULL_RETURN.
EAPI Ecore_Drm2_Relative_Mode ecore_drm2_output_relative_mode_get | ( | Ecore_Drm2_Output * | output | ) |
Get the relative mode of an output.
output | The output to retrieve relative mode for |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI void ecore_drm2_output_relative_to_set | ( | Ecore_Drm2_Output * | output, |
const char * | relative | ||
) |
Set which output a given output is relative to.
output | The output for which to set relative |
relative | The output for which the first output is relative to |
References EINA_SAFETY_ON_NULL_RETURN, and eina_stringshare_replace().
EAPI const char * ecore_drm2_output_relative_to_get | ( | Ecore_Drm2_Output * | output | ) |
Get which output is relative to a given output.
output | The output for which to retrieve relative |
References EINA_SAFETY_ON_NULL_RETURN_VAL.
EAPI void * ecore_drm2_fb_bo_get | ( | Ecore_Drm2_Fb * | fb | ) |
Get the Framebuffer's gbm buffer object.
fb | The framebuffer to query |
References EINA_SAFETY_ON_NULL_RETURN_VAL, and EINA_SAFETY_ON_TRUE_RETURN_VAL.
EAPI Eina_Bool ecore_drm2_output_blanktime_get | ( | Ecore_Drm2_Output * | output, |
int | sequence, | ||
long * | sec, | ||
long * | usec | ||
) |
Get the time of the last vblank.
Query the display hardware for the time of a vblank, potentially blocking.
If sequence is 0 the time of the last vblank will be immediately returned, if it's above zero that number of vblanks will pass before the function returns.
output | |
sequence | |
sec | |
usec |
References EINA_FALSE, EINA_SAFETY_ON_NULL_RETURN_VAL, and EINA_TRUE.
Check if there's a pageflip in progress for an output.
Checks whether an output has submit a flip but not yet had a callback completion event for that flip yet.
output |
References EINA_FALSE, EINA_SAFETY_ON_NULL_RETURN_VAL, and EINA_TRUE.