Not sure if it’s the best way, here’s a sniplet of what I was using once to get
the display name (C++11):
// assuming you have the profile open – hprofile is the handle to the profile
cmsUInt32Number bufferSize = cmsGetProfileInfo(hprofile, cmsInfoDescription,
cmsNoLanguage, cmsNoCountry, nullptr, 0);
size_t numWideChars = (bufferSize + 1) / 2;
std::unique_ptr<wchar_t[]> description(new wchar_t[numWideChars]);
cmsUInt32Number result = cmsGetProfileInfo(hprofile, cmsInfoDescription,
cmsNoLanguage, cmsNoCountry, description.get(), bufferSize);
Note that you might want to check if the profile name is available a certain
language….
You also could directly store it to a pre-sized std::wstring rather than the
unique_ptr<wchar_t[]>; I don’t remember why Idid it that way.
Marco
Von: Aaron Boxer [mailto:boxe...@gmail.com]
Gesendet: Montag, 27. Februar 2017 09:58
An: lcms-user@lists.sourceforge.net
Betreff: [Lcms-user] Extract name from ICC profile
Hello Again,
What is the best way of using lcms to extract an ICC profile name?
Thanks so much,
Aaron
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Lcms-user mailing list
Lcms-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lcms-user