#include "ltwrappr.h"
L_INT LICCProfile::Fill(pData, uDataSize);
L_INT LICCProfile::Fill(pszFileName);
Fills the class object's ICCPROFILEEXT member structure fields with the appropriate ICC data either from a loaded ICC Profile or a directly from a specific file.
Pointer to a data buffer that contains the ICC profile as one piece.
Value that indicates the size of the data buffer that contains the ICC profile.
Character strings that containis the name of the ICC file from which to get the ICC data.
Value | Meaning |
---|---|
SUCCESS | The function was successful. |
< 1 | An error occurred. Refer to Return Codes. |
When loading the ICC profile from a file using the LICCProfile::Load function, the ICC profile is stored into the pData pointer in the class object's ICCPROFILEEXT member structure. Calling LICCProfile::Fill(pData, uDataSize) extracts the information from that ICC profile pointer, and fills the class object's ICCPROFILEEXT member structure with the appropriate data for each field.
To fill a class object's ICCPROFILEEXT member structure directly from an ICC profile file, call LICCProfile::Fill(L_TCHAR * pszFileName).
To save an ICC Profile data to an ICC Profile file call LICCProfile::GenerateFile.
Required DLLs and Libraries
This example initializes an ICC Profile, and fills its fields with ICC data directly read from an ICC file.
For an example for L_INT LICCProfile::Fill(pData, uDataSize), refer to LICCProfile::Initialize.
L_INT LICCProfile_FillExample(L_TCHAR* szFileName)
{
L_INT nRet = FAILURE;
LICCProfile IccProfile;
// Initialize the ICC profile
nRet = IccProfile.Initialize ();
if (nRet != SUCCESS)
return nRet;
// Fill it with ICC data directly from an ICC file
nRet = IccProfile.Fill(szFileName);
// Free the ICC Profile
if (nRet == SUCCESS)
IccProfile.Free ();
return nRet;
}