oyranos.c File Reference

The API implementation. More...

#include <sys/stat.h>
#include <unistd.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include "config.h"
#include "oyranos.h"
#include "oyranos_check.h"
#include "oyranos_cmms.h"
#include "oyranos_debug.h"
#include "oyranos_elektra.h"
#include "oyranos_helper.h"
#include "oyranos_internal.h"
#include "oyranos_io.h"
#include "oyranos_sentinel.h"
#include "oyranos_texts.h"
#include "oyranos_xml.h"

Functions

oyWIDGEToyWidgetListGet (oyGROUP group, int *count)
 all widgets of a group
oyWIDGET_TYPE oyWidgetTitleGet (oyWIDGET option, const oyGROUP **categories, const char **name, const char **tooltip, int *flags)
 Get a special Options UI strings.
int oyOptionChoicesGet (oyWIDGET option, int *choices, const char ***choices_string_list, int *current)
 Get a Options choices UI strings.
void oyOptionChoicesFree (oyWIDGET_TYPE option, char ***list, int size)
 delete list of choices from a option
int oySetBehaviour (oyBEHAVIOUR type, int choice)
int oyGetBehaviour (oyBEHAVIOUR type)
char * oyPolicyToXML (oyGROUP group, int add_header, oyAllocFunc_t allocate_func)
int oyReadXMLPolicy (oyGROUP group, const char *xml)
int oyPathsCount (void)
char * oyPathName (int number, oyAllocFunc_t allocate_func)
int oyPathAdd (const char *pathname)
void oyPathRemove (const char *pathname)
char * oyGetPathFromProfileName (const char *profile_name, oyAllocFunc_t allocate_func)
int oySetDefaultProfile (oyDEFAULT_PROFILE type, const char *file_name)
int oySetDefaultProfileBlock (oyDEFAULT_PROFILE type, const char *file_name, void *mem, size_t size)
char * oyGetDefaultProfileName (oyDEFAULT_PROFILE type, oyAllocFunc_t allocate_func)
char ** oyProfileListGet (const char *coloursig, int *size)
 get a list of profile filenames
int oyCheckProfile (const char *filename, const char *coloursig)
 check an file if it is a profile
int oyCheckProfileMem (const void *mem, size_t size, const char *coloursig)
 check an memory block if it is a profile
size_t oyGetProfileSize (const char *profilename)
 get the profiles size
void * oyGetProfileBlock (const char *profilename, size_t *size, oyAllocFunc_t allocate_func)
 obtain an memory block in the responsibility of the user
char * oyGetDeviceProfile (oyDEVICETYP typ, const char *manufacturer, const char *model, const char *product_id, const char *host, const char *port, const char *attrib1, const char *attrib2, const char *attrib3, oyAllocFunc_t allocate_func)
 ask for a profile name by specifying device attributes
int oySetDeviceProfile (oyDEVICETYP typ, const char *manufacturer, const char *model, const char *product_id, const char *host, const char *port, const char *attrib1, const char *attrib2, const char *attrib3, const char *profileName, const void *mem, size_t size)
 set a profile name with specifying device attributes
int oyEraseDeviceProfile (oyDEVICETYP typ, const char *manufacturer, const char *model, const char *product_id, const char *host, const char *port, const char *attrib1, const char *attrib2, const char *attrib3)
 remove or deinstall the profile from the current path
int oyModulRegisterXML (oyGROUP group, const char *xml)
 read in the declarations of available options and functions
char ** oyModulsGetNames (int *count, oyAllocFunc_t allocate_func)
 get the user allocated CMM 4 char ID's
void oyI18NSet (int active, int reserved)
 switch internationalisation of strings on or off
int oyProfileGetMD5 (void *buffer, size_t size, char *md5_return)
 calculate a md5 digest beginning after the header offset


Detailed Description

The API implementation.

This file contains functions implementing the Oyranos API.
For the Oyranos API see


Function Documentation

int oyEraseDeviceProfile ( oyDEVICETYP  typ,
const char *  manufacturer,
const char *  model,
const char *  product_id,
const char *  host,
const char *  port,
const char *  attrib1,
const char *  attrib2,
const char *  attrib3 
)

remove or deinstall the profile from the current path

char* oyGetDeviceProfile ( oyDEVICETYP  typ,
const char *  manufacturer,
const char *  model,
const char *  product_id,
const char *  host,
const char *  port,
const char *  attrib1,
const char *  attrib2,
const char *  attrib3,
oyAllocFunc_t  allocate_func 
)

ask for a profile name by specifying device attributes

Parameters:
typ kind of device
manufacturer the device manufacturer (EIZO)
model the model (LCD2100)
product_id the ID reported during connection (ID_701200xx)
host useful for monitor identification (grafic:0.0)
port kind of connection (Matrox G650)
attrib1 additional attribute
attrib2 additional attribute
attrib3 additional attribute
allocate_func the users memory allocation function
simply pass 0 for not specified properties

   char* profile_name = oyGetDeviceProfile ("EIZO", "LCD2100",
                                            "ID 87-135.19",
                                            "grafic:0.0", "Matrox G650",
                                             "100lux", 0,
                                            "", allocate_func);
   if (profile_name)
   { char* ptr = NULL;
     ptr = oyGetProfileBlock (profile_name, allocate_func);
       // do something
     free (ptr);
   }

Returns:
allocated by oyAllocFunc_t

int oySetDeviceProfile ( oyDEVICETYP  typ,
const char *  manufacturer,
const char *  model,
const char *  product_id,
const char *  host,
const char *  port,
const char *  attrib1,
const char *  attrib2,
const char *  attrib3,
const char *  profileName,
const void *  mem,
size_t  size 
)

set a profile name with specifying device attributes

Parameters:
mem remains in the users domain


Generated on Sat Jun 16 21:05:40 2007 for Oyranos by  doxygen 1.5.1