MCPcopy Create free account
hub / github.com/AcademySoftwareFoundation/OpenColorIO / getColorSpaces

Method getColorSpaces

src/OpenColorIO/Config.cpp:2296–2313  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2294///////////////////////////////////////////////////////////////////////////
2295
2296ColorSpaceSetRcPtr Config::getColorSpaces(const char * category) const
2297{
2298 ColorSpaceSetRcPtr res = ColorSpaceSet::Create();
2299
2300 // Loop on the list of active color spaces.
2301
2302 for(int idx=0; idx<getNumColorSpaces(); ++idx)
2303 {
2304 const char * csName = getColorSpaceNameByIndex(idx);
2305 ConstColorSpaceRcPtr cs = getImpl()->m_allColorSpaces->getColorSpace(csName);
2306 if(!category || !*category || cs->hasCategory(category))
2307 {
2308 res->addColorSpace(cs);
2309 }
2310 }
2311
2312 return res;
2313}
2314
2315namespace
2316{

Callers 15

search_colorspacesFunction · 0.80
test_rename_color_spaceFunction · 0.80
get_color_spacesMethod · 0.80
_get_itemsMethod · 0.80
_set_valueMethod · 0.80
_get_itemsMethod · 0.80
_get_valueMethod · 0.80
_init_ocioMethod · 0.80

Calls 4

getImplFunction · 0.50
getColorSpaceMethod · 0.45
hasCategoryMethod · 0.45
addColorSpaceMethod · 0.45

Tested by 9

test_rename_color_spaceFunction · 0.64
test_rolesMethod · 0.64
test_interfaceMethod · 0.64
test_copyMethod · 0.64
test_color_spacesMethod · 0.64
test_configMethod · 0.64
OCIO_ADD_TESTFunction · 0.64
OCIO_ADD_TESTFunction · 0.64