![]() |
Oyranos Colour Management System API |
Functions | |
| int | oyGetMonitorInfo (const char *display_name, char **manufacturer, char **model, char **serial, char **system_port, char **display_geometry, oyBlob_s **edid, oyAlloc_f allocate_func) |
| brief pick up monitor information with Xlib | |
| int | oyGetScreenFromPosition (const char *display_name, int x, int y) |
| screen number from position | |
| char * | oyGetDisplayNameFromPosition2 (const char *device_type, const char *device_class, const char *display_name, int x, int y, oyAlloc_f allocateFunc) |
| display name from position | |
| char * | oyGetDisplayNameFromPosition (const char *display_name, int x, int y, oyAlloc_f allocateFunc) |
| display name from position | |
| char * | oyGetMonitorProfile (const char *device_name, size_t *size, oyAlloc_f allocate_func) |
| get the monitor profile from the server | |
| char * | oyMonitorProfileNameFromDB (oyConfig_s *device, oyAlloc_f allocateFunc) |
| get the monitor profile filename from the device database | |
| char * | oyGetMonitorProfileNameFromDB (const char *display_name, oyAlloc_f allocateFunc) |
| get the monitor profile filename from the device profile database | |
| int | oySetMonitorProfile (const char *display_name, const char *profile_name) |
| set the monitor profile by filename | |
| int | oyActivateMonitorProfiles (const char *display_name) |
| activate the monitor using the stored configuration | |
The notation of screens for the X Window system is equal for traditional and Xinerama screens.
The X11 libraries will be loaded at runtime.
The functions can be studied by looking at the oyranos-monitor utiliy. The code for that tool is in oyranos_gamma.c .
| int oyActivateMonitorProfiles | ( | const char * | display_name | ) |
activate the monitor using the stored configuration
Function: oyActivateMonitorProfiles
| display_name | the device string |
References oyConfig_s::oyConfig_FindString(), oyConfig_s::oyConfig_Release(), oyConfigs_s::oyConfigs_Count(), oyConfigs_s::oyConfigs_FromDeviceClass(), oyConfigs_s::oyConfigs_Get(), oyConfigs_s::oyConfigs_Release(), and oyDeviceSetup().
| char* oyGetDisplayNameFromPosition | ( | const char * | display_name, | |
| int | x, | |||
| int | y, | |||
| oyAlloc_f | allocateFunc | |||
| ) |
display name from position
Function: oyGetDisplayNameFromPosition This function will hit exact results only with Xinerama.
| display_name | raw display string | |
| x | x position on screen | |
| y | y position on screen | |
| allocateFunc | function used to allocate memory for the string |
we want a fuzzy look at our display, not the narrow "device_name"
References oyConfig_s::oyConfig_Find(), oyConfig_s::oyConfig_FindString(), oyConfig_s::oyConfig_Release(), oyConfigs_s::oyConfigs_Count(), oyConfigs_s::oyConfigs_FromDeviceClass(), oyConfigs_s::oyConfigs_Get(), oyConfigs_s::oyConfigs_Release(), and oyRectangle_s::oyRectangle_PointIsInside().
| char* oyGetDisplayNameFromPosition2 | ( | const char * | device_type, | |
| const char * | device_class, | |||
| const char * | display_name, | |||
| int | x, | |||
| int | y, | |||
| oyAlloc_f | allocateFunc | |||
| ) |
display name from position
Function: oyGetDisplayNameFromPosition2 This function will hit exact results only with Xinerama.
| [in] | device_type | the device type, e.g. OY_TYPE_STD, defaults to OY_TYPE_STD (optional) |
| [in] | device_class | registration oyFILTER_REG_APPLICATION part, e.g. "monitor", mandatory |
| display_name | raw display string | |
| x | x position on screen | |
| y | y position on screen | |
| allocateFunc | function used to allocate memory for the string |
we want a fuzzy look at our display, not the narrow "device_name"
References oyConfig_s::oyConfig_Find(), oyConfig_s::oyConfig_FindString(), oyConfig_s::oyConfig_Release(), oyConfigs_s::oyConfigs_Count(), oyConfigs_s::oyConfigs_FromDeviceClass(), oyConfigs_s::oyConfigs_Get(), oyConfigs_s::oyConfigs_Release(), and oyRectangle_s::oyRectangle_PointIsInside().
| int oyGetMonitorInfo | ( | const char * | display_name, | |
| char ** | manufacturer, | |||
| char ** | model, | |||
| char ** | serial, | |||
| char ** | system_port, | |||
| char ** | display_geometry, | |||
| oyBlob_s ** | edid, | |||
| oyAlloc_f | allocate_func | |||
| ) |
brief pick up monitor information with Xlib
Function: oyGetMonitorInfo
| display_name | the display string | |
| [out] | manufacturer | the manufacturer of the monitor device |
| [out] | model | the model of the monitor device |
| [out] | serial | the serial number of the monitor device |
| [out] | system_port | the system port name the monitor device is connectted to |
| [out] | display_geometry | the display geometry description of the monitor |
| [out] | edid | the edid data blob of the monitor device |
| allocate_func | the allocator for the above strings |
| char* oyGetMonitorProfile | ( | const char * | device_name, | |
| size_t * | size, | |||
| oyAlloc_f | allocate_func | |||
| ) |
get the monitor profile from the server
Function: oyGetMonitorProfile
| device_name | the display string | |
| [out] | size | the size of profile |
| allocate_func | function used to allocate memory for the profile |
References oyConfig_s::oyConfig_Release(), oyDeviceGet(), oyDeviceGetProfile(), and oyProfile_s::oyProfile_GetMem().
| char* oyGetMonitorProfileNameFromDB | ( | const char * | display_name, | |
| oyAlloc_f | allocateFunc | |||
| ) |
get the monitor profile filename from the device profile database
Function: oyGetMonitorProfileNameFromDB
| display_name | the display string | |
| allocateFunc | function used to allocate memory for the string |
1. get monitor device
2. check for success of device detection
References oyConfig_s::oyConfig_Release(), oyDeviceGet(), oyDeviceProfileFromDB(), and oyProfile_s::oyProfile_Release().
| int oyGetScreenFromPosition | ( | const char * | display_name, | |
| int | x, | |||
| int | y | |||
| ) |
screen number from position
Function: oyGetScreenFromPosition
| display_name | the display string | |
| x | x position on screen | |
| y | y position on screen |
| char* oyMonitorProfileNameFromDB | ( | oyConfig_s * | device, | |
| oyAlloc_f | allocateFunc | |||
| ) |
get the monitor profile filename from the device database
Function: oyMonitorProfileNameFromDB
| device | the device | |
| allocateFunc | user function used to allocate memory |
References oyDeviceProfileFromDB(), and oyProfile_s::oyProfile_Release().
| int oySetMonitorProfile | ( | const char * | display_name, | |
| const char * | profile_name | |||
| ) |
set the monitor profile by filename
Function: oySetMonitorProfile
// store new settings in the Oyranos data base
oySetMonitorProfile( display_name, profile_name );
// remove the server entries
oySetMonitorProfile( display_name, 0 );
// update the window server from the newly Oyranos data base settings
oyActivateMonitorProfiles( display_name );
| display_name | the display string | |
| profile_name | the file to use as monitor profile or 0 to unset |
1. obtain detailed and expensive device informations
1.1 add "properties" call to module arguments
1.2 get monitor device
2. check for success of device detection
References oyConfig_s::oyConfig_Release(), oyDeviceGet(), oyDeviceSetProfile(), and oyDeviceUnset().