![]() |
Oyranos Color Management System API |
A profile constituting element. More...
#include <oyProfileTag_s.h>
Public Member Functions | |
OYAPI oyProfileTag_s *OYEXPORT | oyProfileTag_New (oyObject_s object) |
allocate a new ProfileTag object More... | |
OYAPI oyProfileTag_s *OYEXPORT | oyProfileTag_Copy (oyProfileTag_s *profiletag, oyObject_s object) |
copy or reference a ProfileTag object More... | |
OYAPI int OYEXPORT | oyProfileTag_Release (oyProfileTag_s **profiletag) |
release and possibly deallocate a oyProfileTag_s object More... | |
OYAPI oyProfileTag_s *OYEXPORT | oyProfileTag_Create (oyStructList_s *list, icTagSignature tag_use, icTagTypeSignature tag_type, uint32_t version, const char *required_cmm, oyObject_s object) |
Create a oyProfileTag_s from a list of arguments. More... | |
OYAPI oyProfileTag_s *OYEXPORT | oyProfileTag_CreateFromText (const char *text, icTagTypeSignature tag_type, icTagSignature tag_usage, oyObject_s object) |
Create a oyProfileTag_s from a string. More... | |
OYAPI oyProfileTag_s *OYEXPORT | oyProfileTag_CreateFromData (icTagSignature sig, icTagTypeSignature type, oySTATUS_e status, size_t tag_size, oyPointer tag_block, oyObject_s object) |
Create a oyProfileTag_s from some data. More... | |
OYAPI int OYEXPORT | oyProfileTag_Set (oyProfileTag_s *tag, icTagSignature sig, icTagTypeSignature type, oySTATUS_e status, size_t tag_size, oyPointer tag_block) |
The function is a simple setter for the object elements. More... | |
oyStructList_s * | oyProfileTag_Get (oyProfileTag_s *tag) |
char ** | oyProfileTag_GetText (oyProfileTag_s *tag, int32_t *n, const char *language, const char *country, int32_t *tag_size, oyAlloc_f allocateFunc) |
int | oyProfileTag_GetBlock (oyProfileTag_s *tag, oyPointer *tag_block, size_t *tag_size, oyAlloc_f allocateFunc) |
Get the raw memory block of the tag. More... | |
size_t | oyProfileTag_GetOffset (oyProfileTag_s *tag) |
Get the offset of the tag in the profile. More... | |
int | oyProfileTag_SetOffset (oyProfileTag_s *tag, size_t offset) |
Set the offset of the tag in the profile. More... | |
oySTATUS_e | oyProfileTag_GetStatus (oyProfileTag_s *tag) |
Get the status. More... | |
int | oyProfileTag_SetStatus (oyProfileTag_s *tag, oySTATUS_e status) |
Set the status. More... | |
OYAPI const char *OYEXPORT | oyProfileTag_GetCMM (oyProfileTag_s *tag) |
Get the profile cmm of the tag. More... | |
OYAPI int OYEXPORT | oyProfileTag_SetCMM (oyProfileTag_s *tag, const char *profile_cmm) |
Set the profile CMM in the tag. More... | |
OYAPI const char *OYEXPORT | oyProfileTag_GetLastCMM (oyProfileTag_s *tag) |
Get the last processing cmm of the tag. More... | |
OYAPI int OYEXPORT | oyProfileTag_SetLastCMM (oyProfileTag_s *tag, const char *cmm) |
Set the last processing CMM. More... | |
OYAPI const char *OYEXPORT | oyProfileTag_GetRequiredCMM (oyProfileTag_s *tag) |
Get the certainly selected CMM. More... | |
OYAPI int OYEXPORT | oyProfileTag_SetRequiredCMM (oyProfileTag_s *tag, const char *cmm) |
Require a certain CMM. More... | |
OYAPI icTagSignature OYEXPORT | oyProfileTag_GetUse (oyProfileTag_s *tag) |
Get the usage signature. More... | |
OYAPI icTagTypeSignature OYEXPORT | oyProfileTag_GetType (oyProfileTag_s *tag) |
Get the type signature. More... | |
OYAPI size_t OYEXPORT | oyProfileTag_GetSize (oyProfileTag_s *tag) |
Get the data size. More... | |
OYAPI size_t OYEXPORT | oyProfileTag_GetSizeCheck (oyProfileTag_s *tag) |
Get the data check size. More... | |
OYAPI void OYEXPORT | oyProfileTag_SetSizeCheck (oyProfileTag_s *tag, size_t size_check) |
Set the data check size. More... | |
![]() | |
const char * | oyStruct_GetTextFromModule (oyStruct_s *obj, oyNAME_e name_type, uint32_t flags) |
get object infos from a module More... | |
const char * | oyStruct_GetText (oyStruct_s *obj, oyNAME_e name_type, uint32_t flags) |
get a text dump More... | |
Data Fields | |
const oyOBJECT_e | type_ |
Type of object. More... | |
oyStruct_Copy_f | copy |
Copy function. More... | |
oyStruct_Release_f | release |
Release function. More... | |
oyObject_s | oy_ |
Oyranos internal object. More... | |
![]() | |
const oyOBJECT_e | type_ |
Type of object. More... | |
oyStruct_Copy_f | copy |
Copy function. More... | |
oyStruct_Release_f | release |
Release function. More... | |
oyObject_s | oy_ |
Oyranos internal object. More... | |
A profile constituting element.
OYAPI oyProfileTag_s *OYEXPORT oyProfileTag_Copy | ( | oyProfileTag_s * | profiletag, |
oyObject_s | object | ||
) |
copy or reference a ProfileTag object
Function oyProfileTag_Copy
The function is for copying and for referencing. The reference is the most often used way, which saves resourcs and time.
[in] | profiletag | ProfileTag struct object |
object | NULL - means reference, the optional object triggers a real copy |
References oyOBJECT_PROFILE_TAG_S.
OYAPI oyProfileTag_s *OYEXPORT oyProfileTag_Create | ( | oyStructList_s * | list, |
icTagSignature | tag_use, | ||
icTagTypeSignature | tag_type, | ||
uint32_t | version, | ||
const char * | required_cmm, | ||
oyObject_s | object | ||
) |
Create a oyProfileTag_s from a list of arguments.
Function oyProfileTag_Create
The API relies on an generic arguments inside a list. The arguments are not specified here but in the appropriate modules. This allows flexibility, which needs more understanding.
For the effect of the parameters look at the appropriate module documentation and the function infos.
[in] | list | a list of arguments |
[in] | tag_type | type to create |
[in] | version | version as supported |
[in,out] | required_cmm | in: CMM to create the tag; out: used CMM |
[in] | object | the user object for the tag creation |
References oyOBJECT_STRUCT_LIST_S, and oyQUERY_PROFILE_TAG_TYPE_WRITE.
OYAPI oyProfileTag_s *OYEXPORT oyProfileTag_CreateFromData | ( | icTagSignature | sig, |
icTagTypeSignature | type, | ||
oySTATUS_e | status, | ||
size_t | tag_size, | ||
oyPointer | tag_block, | ||
oyObject_s | object | ||
) |
Create a oyProfileTag_s from some data.
Function oyProfileTag_CreateFromData
[in] | sig | usage signature |
[in] | type | content type |
[in] | status | to be set |
[in] | tag_size | memory size of tag_block |
[in] | tag_block | the to be copied memory |
[in] | object | the user object for the tag creation |
References oyOBJECT_PROFILE_TAG_S, and oyProfileTag_New().
OYAPI oyProfileTag_s *OYEXPORT oyProfileTag_CreateFromText | ( | const char * | text, |
icTagTypeSignature | tag_type, | ||
icTagSignature | tag_usage, | ||
oyObject_s | object | ||
) |
Create a oyProfileTag_s from a string.
Function oyProfileTag_CreateFromText
[in] | text | a string |
[in] | tag_type | type to create, e.g. icSigTextDescriptionType or icSigTextType |
[in] | tag_usage | signature, e.g. icSigCopyrightTag |
[in] | object | the user object for the tag creation |
References oyNAME_NAME, oyStructList_s::oyStructList_MoveIn(), and oyStructList_s::oyStructList_New().
oyStructList_s * oyProfileTag_Get | ( | oyProfileTag_s * | tag | ) |
Function oyProfileTag_Get
Hint: to select a certain module use the oyProfileTag_s::required_cmm element from the tag parameter.
[in] | tag | the tag to read |
References oyOBJECT_PROFILE_TAG_S, and oyQUERY_PROFILE_TAG_TYPE_READ.
Referenced by oyProfileTag_GetText().
int oyProfileTag_GetBlock | ( | oyProfileTag_s * | tag, |
oyPointer * | tag_block, | ||
size_t * | tag_size, | ||
oyAlloc_f | allocateFunc | ||
) |
Get the raw memory block of the tag.
Function oyProfileTag_GetBlock
[in] | tag | the tag to read |
[out] | tag_block | the raw data owned by the user; on success the block if it has a size; else undefined; optional |
[out] | tag_size | the data size; on success the size returned in tag_block else undefined |
[in] | allocateFunc | the user allocator, optional |
References oyOBJECT_PROFILE_TAG_S.
OYAPI const char *OYEXPORT oyProfileTag_GetCMM | ( | oyProfileTag_s * | tag | ) |
Get the profile cmm of the tag.
Function oyProfileTag_GetCMM
[in/out | tag the tag to read |
References oyOBJECT_PROFILE_TAG_S.
OYAPI const char *OYEXPORT oyProfileTag_GetLastCMM | ( | oyProfileTag_s * | tag | ) |
Get the last processing cmm of the tag.
Function oyProfileTag_GetLastCMM
[in/out | tag the tag to read |
References oyOBJECT_PROFILE_TAG_S.
size_t oyProfileTag_GetOffset | ( | oyProfileTag_s * | tag | ) |
Get the offset of the tag in the profile.
Function oyProfileTag_GetOffset
[in] | tag | the tag to read |
References oyOBJECT_PROFILE_TAG_S.
OYAPI const char *OYEXPORT oyProfileTag_GetRequiredCMM | ( | oyProfileTag_s * | tag | ) |
Get the certainly selected CMM.
Function oyProfileTag_GetRequiredCMM
[in/out | tag the tag to read |
References oyOBJECT_PROFILE_TAG_S.
OYAPI size_t OYEXPORT oyProfileTag_GetSize | ( | oyProfileTag_s * | tag | ) |
Get the data size.
Function oyProfileTag_GetSize
[in] | tag | the tag to read |
References oyOBJECT_PROFILE_TAG_S.
OYAPI size_t OYEXPORT oyProfileTag_GetSizeCheck | ( | oyProfileTag_s * | tag | ) |
Get the data check size.
Function oyProfileTag_GetSizeCheck
[in] | tag | the tag to read |
References oyOBJECT_PROFILE_TAG_S.
oySTATUS_e oyProfileTag_GetStatus | ( | oyProfileTag_s * | tag | ) |
Get the status.
Function oyProfileTag_GetStatus
[in] | tag | the tag to read |
char ** oyProfileTag_GetText | ( | oyProfileTag_s * | tag, |
int32_t * | n, | ||
const char * | language, | ||
const char * | country, | ||
int32_t * | tag_size, | ||
oyAlloc_f | allocateFunc | ||
) |
Function oyProfileTag_GetText
For the effect of the parameters look at the appropriate module.
Hint: to select a certain module use the oyProfileTag_s::required_cmm element from the tag parameter.
For localised strings, e.g. icSigMultiLocalizedUnicodeType:
[in] | tag | the tag to read |
[out] | n | the number of returned strings |
[in] | language | 2 byte language code, or "" for current |
[in] | country | 2 byte country code |
[out] | tag_size | the processed tag size |
[in] | allocateFunc | the user allocator for the returned list |
References oyBlob_s::oyBlob_GetPointer(), oyBlob_s::oyBlob_GetSize(), oyCountry(), oyLanguage(), oyOBJECT_BLOB_S, oyOBJECT_NAME_S, oyOBJECT_PROFILE_TAG_S, oyProfileTag_Get(), oyStructList_s::oyStructList_Count(), oyStructList_s::oyStructList_GetRefType(), and oyStructList_s::oyStructList_Release().
OYAPI icTagTypeSignature OYEXPORT oyProfileTag_GetType | ( | oyProfileTag_s * | tag | ) |
Get the type signature.
Function oyProfileTag_GetType
[in/out | tag the tag to read |
References oyOBJECT_PROFILE_TAG_S.
OYAPI icTagSignature OYEXPORT oyProfileTag_GetUse | ( | oyProfileTag_s * | tag | ) |
Get the usage signature.
Function oyProfileTag_GetUse
[in/out | tag the tag to read |
References oyOBJECT_PROFILE_TAG_S.
OYAPI oyProfileTag_s *OYEXPORT oyProfileTag_New | ( | oyObject_s | object | ) |
allocate a new ProfileTag object
Function oyProfileTag_New
References oyOBJECT_OBJECT_S.
Referenced by oyProfileTag_CreateFromData().
OYAPI int OYEXPORT oyProfileTag_Release | ( | oyProfileTag_s ** | profiletag | ) |
release and possibly deallocate a oyProfileTag_s object
Function oyProfileTag_Release
[in,out] | profiletag | ProfileTag struct object |
References oyOBJECT_PROFILE_TAG_S.
OYAPI int OYEXPORT oyProfileTag_Set | ( | oyProfileTag_s * | tag, |
icTagSignature | sig, | ||
icTagTypeSignature | type, | ||
oySTATUS_e | status, | ||
size_t | tag_size, | ||
oyPointer | tag_block | ||
) |
The function is a simple setter for the object elements.
Function oyProfileTag_Set
[in,out] | tag | the to be manipulated ICC profile object |
[in] | sig | usage signature |
[in] | type | content type |
[in] | status | to be set |
[in] | tag_size | memory size of tag_block |
[in] | tag_block | the block to be moved into the object; The pointer is owned by the object. Its memory should be allocated as with the same allocators as the object. |
References oy_, and oyOBJECT_PROFILE_TAG_S.
OYAPI int OYEXPORT oyProfileTag_SetCMM | ( | oyProfileTag_s * | tag, |
const char * | profile_cmm | ||
) |
Set the profile CMM in the tag.
Function oyProfileTag_SetCMM
[in/out | tag the tag to read | |
[in] | profile_cmm | new cmm, 4 bytes |
References oyOBJECT_PROFILE_TAG_S.
OYAPI int OYEXPORT oyProfileTag_SetLastCMM | ( | oyProfileTag_s * | tag, |
const char * | cmm | ||
) |
Set the last processing CMM.
Function oyProfileTag_SetLastCMM
[in/out | tag the tag to read | |
[in] | cmm | CMM, 4 bytes |
References oyOBJECT_PROFILE_TAG_S.
int oyProfileTag_SetOffset | ( | oyProfileTag_s * | tag, |
size_t | offset | ||
) |
Set the offset of the tag in the profile.
Function oyProfileTag_SetOffset
[in/out | tag the tag to read | |
[in] | offset | new offset |
References oyOBJECT_PROFILE_TAG_S.
OYAPI int OYEXPORT oyProfileTag_SetRequiredCMM | ( | oyProfileTag_s * | tag, |
const char * | cmm | ||
) |
Require a certain CMM.
Function oyProfileTag_SetRequiredCMM
[in/out | tag the tag to read | |
[in] | cmm | CMM, 4 bytes |
References oyOBJECT_PROFILE_TAG_S.
OYAPI void OYEXPORT oyProfileTag_SetSizeCheck | ( | oyProfileTag_s * | tag, |
size_t | size_check | ||
) |
Set the data check size.
Function oyProfileTag_SetSizeCheck
[in/out] | tag the tag to read | |
[in] | check | size |
References oyOBJECT_PROFILE_TAG_S.
int oyProfileTag_SetStatus | ( | oyProfileTag_s * | tag, |
oySTATUS_e | status | ||
) |
Set the status.
Function oyProfileTag_SetStatus
[in/out | tag the tag to read | |
[in] | status | new status |
References oyOBJECT_PROFILE_TAG_S.
oyStruct_Copy_f oyProfileTag_s::copy |
Copy function.
oyObject_s oyProfileTag_s::oy_ |
Oyranos internal object.
Features name and hash. Do not change during object life time.
Referenced by oyProfileTag_Set().
oyStruct_Release_f oyProfileTag_s::release |
Release function.
const oyOBJECT_e oyProfileTag_s::type_ |
Type of object.
The struct type tells Oyranos how to interprete hidden fields.
Referenced by oyProfile_s::oyProfile_TagMoveIn().