Descriptive Contents
Introduction | Compilation | References
Tools Documentation | Environment Variables | User API Documentation | Programming Tutorial | Threading | Extending Oyranos
- License
- new BSD http://www.opensource.org/licenses/BSD-3-Clause
- Author
- Kai-Uwe Behrmann and others
- Since
- March 2004
- Internet
- http://www.oyranos.org/about
- Development
- https://gitlab.com/oyranos/oyranos
Introduction
Oyranos is intended as a entry point for color savy applications. In its current stage it configures profile paths, sets default profiles, maps devices to profiles, sets a monitor profile in X and uploads a vcgt tag. This means for instance all applications using Oyranos will use for a incoming digital camera picture the same profile and watch it through the same monitor profile with the same options for rendering intent, simulation and so on.
Tools Documentation
- oyranos-icc - access embedded profiles from images, color convert images
- oyranos-config v0.9.7 - a command line tool for settings and to get compiler flags to using Oyranos in your own project.
- oyranos-config-synnefo - a GUI for policies, settings and information
- oyranos-config-fltk - a configuration UI application, using some functions of the Oyranos APIs. If you have ICC Examin installed it can be called too
- oyranos-policy v0.9.7 - a command line tool to list, set and dump color management settings groups
- oyranos-profile v0.9.7 - a command line tool to show internal profile information
- oyranos-profiles v0.9.7 - lookup profiles in the systems color paths, download and install
- oyranos-profile-graph v0.9.7 - draw a 2D graph from ICC profiles and spectral data
- oyranos-device v0.9.7 - a command line tool showing and administrating ICC profiles for color devices
- oyranos-monitor v0.9.7 - a command line tool to handle monitor device ICC color profiles. Affected are default profiles and some behaviour settings.
- oyranos-monitor-white-point v0.9.7 - a command line tool to handle nightly red light monitor white point It covers a geo location and time sensitive daemon for white point adaption to red night light. The daemon is called from oyranos-monitor.
User API Documentation
The basic Oyranos API gets included with oyranos.h. An application, which wants to use these functions, needs to link against Oyranos.
The monitor related interfaces are accessed through Device Handling interfaces. Loading of the according module for the device depedent libraries is done on runtime.
The key names, which Oyranos uses to store its configuration in an Elektra file tree, are defined in oyranos_definitions.h.
Programming Tutorial
Frist you have to put a
in your source text, in order to use Oyranos.
int main(
int argc,
char ** argv ) {
return 0;
}
oyranos-config –cflags delivers the compiler flags and oyranos-config –ldflags the linker flags.
Then you can put Oyranos functions in your code and compile with:
cc `oyranos-config --cflags --ldflags` mycode.c -o myApp
to link Oyranos into your application.
The second code sample will be more useful and handle obtaining a monitor profile:
#include <stdio.h>
int main(
int argc OY_UNUSED,
char ** argv OY_UNUSED ) {
const char * monitor_icc_dscr = NULL;
printf( "first monitor has profile: %s\n", monitor_icc_dscr );
float rgb_in[9] = {0,0,0, 0.5,0.5,0.5, 1,1,1};
float rgb_moni[9];
NULL, 3 );
int i;
for(i = 0; i < 3; ++i)
printf("%.02f %.02f %.02f -> %.05f %.05f %.05f\n",
rgb_in[3*i+0],rgb_in[3*i+1],rgb_in[3*i+2], rgb_moni[3*i+0],rgb_moni[3*i+1],rgb_moni[3*i+2]);
return 0;
}
The code is from tutorial1.c
Writing of filters and modules for Oyranos is covered in the Extending Oyranos page.